The 2cc Bus Set
Moderator: Graphics Moderators
- planetmaker
- OpenTTD Developer
- Posts: 9432
- Joined: 07 Nov 2007 22:44
- Location: Sol d
Re: The 2cc Bus Set
Yes, very much so. The web translator is automatically updated with the new base language (=english) string file, whenever that is changed. And the repository is updated once per day with the new translations made by the translators. That changeset then is built by the DevZone and published to http://bundles.openttdcoop.org/cc-bus-set/push/LATEST - that is once the compile-on-push is activated. Will do that now.
I made some changes, updating Makefile and fixing some upper/lower case errors when including source files in order to make it build. However the names of at least one, probably many PNG files are such that they contain "strange" characters which make the build fail (äöüß and those which I cannot type like the S for Skoda). These characters are in an encoding in the filenames which does not work well and makes the build fail. There are more files to rename than I have time right now to look at. I suggest your coder looks at it and renames them and their references in the code to use only ascii chars.
https://jenkins.openttdcoop.org/job/cc- ... /2/console
I made some changes, updating Makefile and fixing some upper/lower case errors when including source files in order to make it build. However the names of at least one, probably many PNG files are such that they contain "strange" characters which make the build fail (äöüß and those which I cannot type like the S for Skoda). These characters are in an encoding in the filenames which does not work well and makes the build fail. There are more files to rename than I have time right now to look at. I suggest your coder looks at it and renames them and their references in the code to use only ascii chars.
https://jenkins.openttdcoop.org/job/cc- ... /2/console
OpenTTD: manual | online content | translations | Wanted contributions and patches
#openttdcoop: blog | wiki | public server | DevZone | NewGRF web translator
DevZone - home of the free NewGRFs: OpenSFX | OpenMSX | OpenGFX | Swedish Rails | OpenGFX+ Trains|RV|Industries|Airports|Landscape | NML
- Voyager One
- Tycoon
- Posts: 11204
- Joined: 28 Dec 2009 09:47
- Location: Rijeka, Croatia
Re: The 2cc Bus Set
@Jyratos - I've found some time and tested the set, all seems OK and correct except... one small remark and one question/remark.
Remark: I load ONLY the 2cc bus set (no other GRF) and I still get and can't get rid of the original RVs. Is that code-related and a parametere should be added?
Question/remark: I assume you've let the game calculate the TE of all vehicles. IMO it seems a bit too high. What adhesion coefficient did you use? The value of 0,3 (for trains) is too low, for RVs (tyres on asphalt) should be approximately 0,7.
EDIT:
A third issue:
IMO you should TRIPLE all purchase costs and DOUBLE all running costs and then add two separate parameters for these to be adjusted (Very low x0.25, Low x0.50, Normal x1, High x2 Very high x4)
Remark: I load ONLY the 2cc bus set (no other GRF) and I still get and can't get rid of the original RVs. Is that code-related and a parametere should be added?
Question/remark: I assume you've let the game calculate the TE of all vehicles. IMO it seems a bit too high. What adhesion coefficient did you use? The value of 0,3 (for trains) is too low, for RVs (tyres on asphalt) should be approximately 0,7.
EDIT:
A third issue:
IMO you should TRIPLE all purchase costs and DOUBLE all running costs and then add two separate parameters for these to be adjusted (Very low x0.25, Low x0.50, Normal x1, High x2 Very high x4)
-
- Tycoon
- Posts: 2781
- Joined: 22 Feb 2011 18:34
Re: The 2cc Bus Set
A set needs to explicitly disable the original vehicles, and that piece of code is not present in this NewGRF (quick check).Voyager One wrote:Remark: I load ONLY the 2cc bus set (no other GRF) and I still get and can't get rid of the original RVs. Is that code-related and a parametere should be added?
Coder of the Dutch Trackset | Development support for the Dutch Trainset | Coder of the 2cc TrainsInNML
Re: The 2cc Bus Set
Like transportman said, I forgotten to code the removal of the default vehicles.Voyager One wrote: Remark: I load ONLY the 2cc bus set (no other GRF) and I still get and can't get rid of the original RVs. Is that code-related and a parametere should be added?
Yes, I used a TE coefficient of 0,3. I will correct everything (I think) tomorrow.Voyager One wrote: Question/remark: I assume you've let the game calculate the TE of all vehicles. IMO it seems a bit too high. What adhesion coefficient did you use? The value of 0,3 (for trains) is too low, for RVs (tyres on asphalt) should be approximately 0,7.
No problem, I'll do that.Voyager One wrote: IMO you should TRIPLE all purchase costs and DOUBLE all running costs and then add two separate parameters for these to be adjusted (Very low x0.25, Low x0.50, Normal x1, High x2 Very high x4)
Thank you finding those problems
- Voyager One
- Tycoon
- Posts: 11204
- Joined: 28 Dec 2009 09:47
- Location: Rijeka, Croatia
Re: The 2cc Bus Set
Not problems at all. Fine tuning...Jyratos wrote:Thank you finding those problems
Re: The 2cc Bus Set
Hi !
I corrected the tractive effort, modified the costs, added parameters and removed illegal characters. But I have a question : does the ' or - characters are ascii or I need to remove them from the images?
I corrected the tractive effort, modified the costs, added parameters and removed illegal characters. But I have a question : does the ' or - characters are ascii or I need to remove them from the images?
Re: The 2cc Bus Set
if you want to be really sure, only use letters (A-Z,a-z), numbers (0-9) and underscore (_) in filenames.
anything else will sooner or later be encountered by an unsuspecting tool and cause problems.
anything else will sooner or later be encountered by an unsuspecting tool and cause problems.
- Voyager One
- Tycoon
- Posts: 11204
- Joined: 28 Dec 2009 09:47
- Location: Rijeka, Croatia
Re: The 2cc Bus Set
Any progress Jyratos?
Re: The 2cc Bus Set
For the moment, not a lot, sorry. I'm trying to code speed limits,but I have problems.Voyager One wrote:Any progress Jyratos?
This is more a question to transportsman : I coded the limits like this :
Code: Select all
speed: param_max_speed km/h;
Code: Select all
if ((param_max_speed == 0) | (param_max_speed >= 128))
{
item (FEAT_ROADVEHS, ACFBrillIC41)
{
property
{ speed: 128 km/h; }
}
}
But when I set a upper limit, for example to limit the vehicles like the Autosan Eurolider 12, limited to 155 km/h. I set the limit to 150 but it shows 127 km/h in max speed so I think there is a limit for the parameters to 127. Do you agree with me or I made a mistake ?
-
- Transport Coordinator
- Posts: 260
- Joined: 09 Apr 2014 11:10
Re: The 2cc Bus Set
I can see a few problems with how you've attempted to code the speed limits, first is as you've discovered the maximum value for a parameter is 127. The second is I don't think having a parameter where the player types in a number that becomes the speed limit for all vehicles is the ideal solution. From what I can tell the purpose of a speed limit parameter is if players wish to have buses respect some kind of road speed limit instead of travelling at speeds that while realistic in terms of vehicle capability are not legal in most countries. As far as I know speed limits can be set between stops in the vehicle orders, this can allow for lower speeds within towns and higher speeds on the motorways linking towns, this is probably the most sensible and realistic way. If however you still want to code a maximum speed, the way that should be done is rather than using the parameter number as the literal maxspeed, have a parameter with values such as 100km/h, 110km/h, 150km/h etc, then adjust each vehicle with a callback that interprets this setting as a speed. This will give a reasonable choice as to the maximum permitted highway speed across various countries.Jyratos wrote: I'm trying to code speed limits,but I have problems.
...
Without having the full source of the set it's hard for me to test this properly, but hopefully the following code fragments will help...
In the grf block (I've put 4 speed limits plus unlimited as default, you can add more easily)
Code: Select all
param {
max_speed {
type: int;
name: string(STR_PARAM_MAX_SPEED);
desc: string(STR_PARAM_MAX_SPEED_DESC);
min_value: 1;
max_value: 5;
def_value:5;
names: {
1: string(STR_MAX_SPEED_100);
2: string(STR_MAX_SPEED_110);
3: string(STR_MAX_SPEED_130);
4: string(STR_MAX_SPEED_150);
5: string(STR_MAX_SPEED_UNLIMITED);
}
}
}
Code: Select all
switch (FEAT_ROADVEHS, SELF, bus01_speed_limit_switch, param_max_speed) {
1: return 100;
2: return 110;
3: return 130;
4: return 150
5: CB_FAILED; // use the speed defined in vehicle property in case of unlimited speed setting
}
item(FEAT_ROADVEHS, bus01) {
property {
speed: 165km/h)
}
graphics {
speed: bus01_speed_limit_switch;
}
Re: The 2cc Bus Set
Thanks for your help. I coded the speed limits,but for an unknown reason, the limits were multiplied by 2 (90km/h was at 180 for example). It does not create a big problem, but I think it's strange.
Do you have an idea about this ?
Do you have an idea about this ?
Re: The 2cc Bus Set
Please note "Units are not (yet) available" statement on http://newgrf-specs.tt-wiki.net/wiki/NML:Vehicles page.Jyratos wrote:the limits were multiplied by 2 (90km/h was at 180 for example). It does not create a big problem, but I think it's strange.
Do you have an idea about this ?
You must multiply those values by factor 2 to achieve real kmsh speed for road vehicle ans ship (or in other words, use 2x smaller value than those which you want to set).
Similar apply to power.
PS. Nice idea with different cargo_age_speed and loading_speed for urban/IC buses.
I'm using similar approach, but instead of "magic" values, function depending on sitting/standing places ratio+air conditioning bonus
is used for cargo_aging, and function depending on door leaf number + lowered floor bonus, is used for loading speed calculation.
Formerly known as: McZapkie
Projects: Reproducible Map Generation patch, NewGRFs: Manpower industries, PolTrams, Polroad, 600mm narrow gauge, wired, ECS industry extension, V4 CEE train set, HotHut.
Another favorite games: freeciv longturn, OHOL/2HOL.
Projects: Reproducible Map Generation patch, NewGRFs: Manpower industries, PolTrams, Polroad, 600mm narrow gauge, wired, ECS industry extension, V4 CEE train set, HotHut.
Another favorite games: freeciv longturn, OHOL/2HOL.
Re: The 2cc Bus Set
waiting for the webtranslator ^^
Re: The 2cc Bus Set
Bus-Semi... We do have one, why not to have another... older one!
http://www.busaustralia.com/forum/viewt ... 10&t=22071
http://www.busaustralia.com/forum/viewt ... 10&t=22071
TT-Screenshot Of The Month - 2012 July, winner!
TT-Screenshot Of The Month - 2013 May, winner tie with Purno!
TT-Screenshot Of The Month - 2014 February, winner!
TT-Screenshot Of The Month - 2014 June, winner tie with alluke!
TT-Screenshot Of The Month - 2014 April, winner!
My screen shot thread ---> Have a look
TT-Screenshot Of The Month - 2013 May, winner tie with Purno!
TT-Screenshot Of The Month - 2014 February, winner!
TT-Screenshot Of The Month - 2014 June, winner tie with alluke!
TT-Screenshot Of The Month - 2014 April, winner!
My screen shot thread ---> Have a look
Re: The 2cc Bus Set
Finally, I had time to continue and I made a lot of corrections and fixes, but for some reason, I cannot push the revisions to the repository.
The TortoiseHg Workbench says (in litteral translation from french to english) : "No pushing revision to ssh://hg@hg.openttdcoop.org/cc-bus-set"
And the log says:
Any help ?
The TortoiseHg Workbench says (in litteral translation from french to english) : "No pushing revision to ssh://hg@hg.openttdcoop.org/cc-bus-set"
And the log says:
Code: Select all
pushing to ssh://hg@hg.openttdcoop.org/cc-bus-set
searching for changes
remote: adding changesets
remote: adding manifests
remote: adding file changes
remote: added 7 changesets with 103 changes to 96 files
remote: File "2ccBusSet.grf" may not be added to the repository.transaction abort!
remote: rollback completed
remote: abort: pretxnchangegroup.check hook failed
[la commande a retourné le code 1 Tue May 12 18:22:50 2015]
2CCbus%
Re: The 2cc Bus Set
You cannot push the resulting .grf file to the repository, by the looks of it
Being a retired OpenTTD developer does not mean I know what I am doing.
Re: The 2cc Bus Set
I removed it and made a revision to remove it from the repo, but it looks like tortoise keeps trying to push it.Alberth wrote:You cannot push the resulting .grf file to the repository, by the looks of it
Re: The 2cc Bus Set
Of course, hg preserves history.
Every revision (all history) is being pushed. You can add new ones on top (add new history), but that does not change the previous revisions (previous history).
Deleting anything in hg does not mean 'delete', it means 'delete from now forward in time'. In older revisions (older points in time) the file will still exist.
Note that this is actually the core reason why you want a repository.
Say you make a GRF version 1, with a bunch of files, and then change it all to version 2, where you don't need those files, and you delete them.
If you go back to version 1, you also want those deleted files back, otherwise you cannot build GRF version 1 again!
What you have to do is change the revision that adds the .grf file (that is, not add it). I don't know how exactly how to do that though, you may want to ask for help somewhere (#openttd channel for example).
Every revision (all history) is being pushed. You can add new ones on top (add new history), but that does not change the previous revisions (previous history).
Deleting anything in hg does not mean 'delete', it means 'delete from now forward in time'. In older revisions (older points in time) the file will still exist.
Note that this is actually the core reason why you want a repository.
Say you make a GRF version 1, with a bunch of files, and then change it all to version 2, where you don't need those files, and you delete them.
If you go back to version 1, you also want those deleted files back, otherwise you cannot build GRF version 1 again!
What you have to do is change the revision that adds the .grf file (that is, not add it). I don't know how exactly how to do that though, you may want to ask for help somewhere (#openttd channel for example).
Being a retired OpenTTD developer does not mean I know what I am doing.
Re: The 2cc Bus Set
Thanks for your reply, I searched on how to modify revisions but I only found how to remove revisions. So I removed all the revisions that caused problem and I recoded speed limits. I commited and pushed everything.
If you have suggestions for paremeters or everything else, tell me.
If you have suggestions for paremeters or everything else, tell me.
- Voyager One
- Tycoon
- Posts: 11204
- Joined: 28 Dec 2009 09:47
- Location: Rijeka, Croatia
Re: The 2cc Bus Set
Jyratos, one question please. You've added a "max vehicle speed" parameter, is it for all buses in one go or are these 3 separate parameters (first for IC, second for Suburban, third for Urban buses)?
Since we already have the 3-types division of buses, I think this should be 3 parameters but also they should have different values for possible max speed. E.g. (I'm putting stupid numbers here) IC buses could have Unlimited/150/130/110, Suburban buses could have 130/110/90/70, Urban buses could have 110/90/70/50... IMO of course...
Since we already have the 3-types division of buses, I think this should be 3 parameters but also they should have different values for possible max speed. E.g. (I'm putting stupid numbers here) IC buses could have Unlimited/150/130/110, Suburban buses could have 130/110/90/70, Urban buses could have 110/90/70/50... IMO of course...
Who is online
Users browsing this forum: No registered users and 7 guests