No more engines - wtf
Moderator: OpenTTD Developers
No more engines - wtf
Hi,
I added the dbset 0.5 newgrf to my game and removed it, because i wanted to have the sh '30' and sh '40' back
(they were not available when using the dbset).
Now there are no engines available anymore.
I tried 'resetengines', created a new game (no problems here), but nothing worked.
When i click on a train, selecting the 'show details of train' (i don't know the correct english string for it - the button with the memo / directly under the arrow), than 'Information', OpenTTD shows a 'ungültige lokomotive' / 'invalid locomotive'.
Is there a way to reset the trains?
regards phedon
I added the dbset 0.5 newgrf to my game and removed it, because i wanted to have the sh '30' and sh '40' back
(they were not available when using the dbset).
Now there are no engines available anymore.
I tried 'resetengines', created a new game (no problems here), but nothing worked.
When i click on a train, selecting the 'show details of train' (i don't know the correct english string for it - the button with the memo / directly under the arrow), than 'Information', OpenTTD shows a 'ungültige lokomotive' / 'invalid locomotive'.
Is there a way to reset the trains?
regards phedon
:tipp | hint:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
Re: No more engines - wtf
go back to the autosave before you added the grf set.
adding and removing grf sets mid-game is not supported and can cause all kinds of effects like this.
adding and removing grf sets mid-game is not supported and can cause all kinds of effects like this.
- planetmaker
- OpenTTD Developer
- Posts: 9432
- Joined: 07 Nov 2007 22:44
- Location: Sol d
Re: No more engines - wtf
Make sure you read the red error messages next time. If they're not understandable please propose a better translation.
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
Re: No more engines - wtf
Thx mate, this workaround works.
Any solution for the problem with the lost engines?
Any solution for the problem with the lost engines?
:tipp | hint:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
Re: No more engines - wtf
Which red error message? "Invalid locomotive/engine/train"? So whats the better translation for "ungültige Lokomotive"?planetmaker wrote:Make sure you read the red error messages next time. If they're not understandable please propose a better translation.
http://www.dict.cc/?s=lokomotive
:tipp | hint:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
Re: No more engines - wtf
The one you got after adding DBSet in the NewGRF window and clicking Apply.
- planetmaker
- OpenTTD Developer
- Posts: 9432
- Joined: 07 Nov 2007 22:44
- Location: Sol d
Re: No more engines - wtf
I now made it more verbose and extended it tophedon wrote:planetmaker wrote:Make sure you read the red error messages next time. If they're not understandable please propose a better translation.Warning when changing NewGRF on a running game (German) wrote:{YELLOW}Änderungen während eines laufenden Spiels können zum Absturz von OpenTTD führen.{}Trotzdem fortfahren?
Änderungen während eines laufenden Spiels können zum Absturz von OpenTTD oder sonstigem, unerwünschten Verhalten führen. Trotzdem fortfahren?
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
Re: No more engines - wtf
Hmmm...
That's not a bad idea, as it can do more than just crash. Crashing is actually not the biggest possible problem when changing newgrf in a running game.
That's not a bad idea, as it can do more than just crash. Crashing is actually not the biggest possible problem when changing newgrf in a running game.
Re: No more engines - wtf
Okay, i got it.
But I never had the the problem i described in my first post before - only with the DBSet.
I think, the DBSet overwrites the VehicleIDs of the original trains, right? That's why the original engines (sh30,sh40 etc.) disappeared.
So when I remove the DBSet, there are no valid vehicles anymore. This makes sense.
Maybe it could be coded in OpenTTD like that (pseudocode / I'm programming in Object-Pascal, so don't expect to much ):
With this the "missing_engine_anomaly" would never happen.
By the way: because I do develope NewGrfs, I'm using the add/remove newgrf buttons excessively
regards
phedon
But I never had the the problem i described in my first post before - only with the DBSet.
I think, the DBSet overwrites the VehicleIDs of the original trains, right? That's why the original engines (sh30,sh40 etc.) disappeared.
So when I remove the DBSet, there are no valid vehicles anymore. This makes sense.
Maybe it could be coded in OpenTTD like that (pseudocode / I'm programming in Object-Pascal, so don't expect to much ):
Code: Select all
proc btnRemoveNewGrf();
if not assigned(VehicleID)
{
restoreOriginalVehicle(VehicleID)
}
endp
By the way: because I do develope NewGrfs, I'm using the add/remove newgrf buttons excessively
regards
phedon
:tipp | hint:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
Re: No more engines - wtf
I've found for experimenting with a newgrf, unless you're testing behaviour when it's loaded or unloaded in a running game, the best way to test is with a new game. Set it to a 64x64 map, and don't load anything you don't need to test it, and you'll have what you need in no time.
- planetmaker
- OpenTTD Developer
- Posts: 9432
- Joined: 07 Nov 2007 22:44
- Location: Sol d
Re: No more engines - wtf
Then you should be especially aware of the pitfalls. Gremnon's advice is not bad. And when it comes to developing one newgrf, it's easy to just overwrite the development version and have OpenTTD load the compatible, newer version of the newgrf. No need for removal either.phedon wrote:because I do develope NewGrfs, I'm using the add/remove newgrf buttons excessively
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
Re: No more engines - wtf
I usually do it the way Gremnon wrote (I'm also modding the GRFMaker to be more compatible with OpenTTD), but when I find a good NewGrf, I usually don't begin a new game, just to have the NewGrf available.
What about my pseudocode? Wouldn't this prevent the problem this topic is about?
Respectively, what is the worst case, when I add a NewGrf at runtime? Crashing the game?
Why does adding a NewGrf to a running game cause so much trouble?
phedon
What about my pseudocode? Wouldn't this prevent the problem this topic is about?
Respectively, what is the worst case, when I add a NewGrf at runtime? Crashing the game?
Why does adding a NewGrf to a running game cause so much trouble?
phedon
:tipp | hint:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
- planetmaker
- OpenTTD Developer
- Posts: 9432
- Joined: 07 Nov 2007 22:44
- Location: Sol d
Re: No more engines - wtf
NewGRFs are part of the map. They define the vehicle, industry, houseIDs etc and give the respective numbers on the map array their meaning. If you now come and change the meaning of those numbers, things can break: you suddenly end up with a train on a station tile which has no tracks (meaning of station tile changed), with an engine without power (definition of vehicleID changed) or with industries which have no rule for the layout they find themselves on the map (re-definition of an industry). To different degrees this may impact the game. In the best case, definitions are compatible or only new ones are added, it may happen that just definitions become strange, but in the worst case invalid definitions are found and a crash results when certain pre-conditions are checked.phedon wrote:Why does adding a NewGrf to a running game cause so much trouble?
NewGRF are WAY more than graphics, they are nearly tiny programmes. Adding new ones works more often than not, but removing is unsafe except on the odd occasion. Also your browser wants a re-start (that is a new game in our terms) after you update its active plug-ins.
On the other hand, if you think that you have an easy solution to your problem with OpenTTD newgrf changes: come up with a patch. It's not as trivial as your pseudo code tries to suggest.
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
Re: No more engines - wtf
Alrighty!
Thx for your explanation.
Thx for your explanation.
:tipp | hint:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
:Alles, was ich schreibe, bezieht sich ausschließlich auf OpenTTD:
:Everything I write solely refers to OpenTTD:
Who is online
Users browsing this forum: No registered users and 4 guests