Sorry melectro, i dont want attack you! But some players have some problems and dont looking by himselfs. I dont mean you personally.
CTD Station on screen, TransportFever 2 Update
Willkommen in der Transport Fever Community
Wir begrüßen euch in der Fan-Community zu den Spielen Transport Fever und Train Fever, den Wirtschaftssimulatoren von Urban Games. Die Community steht euch kostenlos zur Verfügung damit ihr euch über das Spiel austauschen und informieren könnt. Wir pflegen hier einen freundlichen und sachlichen Umgang untereinander und unser Team steht euch in allen Fragen gerne beiseite.
Die Registrierung und Nutzung ist selbstverständlich kostenlos.
Wir wünschen euch viel Spaß und hoffen auf rege Beteiligung.
Das Team der Transport-Fever Community
-
-
But some players have some problems and dont looking by himselfs.
Then you have come to the wrong thread, this thread is only about the specified issue and not anything else.
-
Ooh! Sorry !Yesterday i was very tired....
-
Continuing from Post #18
In the stdout.txt that I have posted in #18 there is some rows that I can't understand, especially row 2204 and 2209
The row 2197 is also interesting. This is nothing that my script is printing. Could that mean that here is something wrong with the mod?
for example:
Code: Debug print
Alles anzeigen2150 Found name= Blackrod id = 22607 --Here is the print from my test script . . 2197 entity 22607 2198 struct ecs::component::ModelInstanceList 2199 struct ecs::component::BoundingVolume 2200 struct ecs::component::Name 2201 struct ecs::component::PlayerOwned 2202 struct ecs::component::Station 2203 c:\build\tpf2_steam\src\game\scripting\legacy\interface.cpp:2027: void __cdecl scripting::SetupInterface::<lambda_e4dfa961e65bd90eebb640533af6c210>::operator ()(class lua::State &) const: Assertion `false' failed. 2204 Console::Execute: [string "game.interface.bulldoze(22607)"]:1: internal error 2205 > Exception type: Fatal error 2206 > 2207 > Details: 2208 > 2209 > Error message: Assertion `false' failed. 2210 > 2211 > Minidump: I:/Steam/userdata/70790454/1066780/local/crash_dump/7e7c05f0-4ba1-450e-bf9d-9a7055bc0fa9.dmp 2212 > 2213 > In file: c:\build\tpf2_steam\src\game\scripting\legacy\interface.cpp:2027 2214 > 2215 > In function: void __cdecl scripting::SetupInterface::<lambda_e4dfa961e65bd90eebb640533af6c210>::operator ()(class lua::State &) const
I think game.interface.bulldoze() has been removed from the game entirely.
game.interface.bulldoze can remove a station I just build a few seconds ago...
When I try to bulldoze my test station (console command seen in image below) I get repeated errors like the snap from stdout.txt above. Could it be that doug is right that bulldoze no longer exists?
eis_os Please tell me what I have to do.
-
Try calling
game.interface.setBulldozeable(22607)
then call
game.interface.bulldoze(22607)
Edit:
It may be game.interface.setBulldozeable(22607,true) that you need.
-
-
Try
game.interface.setBulldozeable(22607,true)
-
Yeah, the problem is you need to bulldoze the construction and not the station or station group.
However it seems there is no direct pointer from station to construction entity.So you have to traverse all construction you get by getEntites filtering with construction. Then look in the station key
-
game.interface.setBulldozeable(22607,true)
setBulldozeable seems not to work
So you have to traverse all construction you get by getEntites filtering with construction. Then look in the station key
eis_os I can try that, but what about the bulldoze command? When that isn't working what do I have to do?
-
You can see that it works:
Start a new game
Build a station
Use UGs Debug Mode Window, click on the construction to get the entity id (the entity component list shows construction) to get the right id.
Open CommonAPI2 Console, select Script thread, then use this id.
game.interface.bulldoze(<the construction id>)
Note: if you click on the station sign, you get the id of the stationsign (doesn't have ecs construction in the list) If you try to bulldose this id, you get an exception.Again, please do a test run yourself to see that you really use the right entity id of a construction and not the attached station sign or station group.
-
Thank you!
I finally found one part that has the ecs::component::Construction in the list. It was in the test game 22571.
Bulldoze that number and the station is gone.
Now I have the tricky thing left. To get the script finding this number. I will return with a report later.
My script gets the same iD number as I manually have found in the test game!
but when using the same script in the game with trouble, I get the Assertion error again
-
-
eis_os
Hat den Titel des Themas von „TransportFever 2 Update“ zu „CTD Station on screen, TransportFever 2 Update“ geändert. -
Yeah, the problem is you need to bulldoze the construction and not the station or station group.
However it seems there is no direct pointer from station to construction entity.So you have to traverse all construction you get by getEntites filtering with construction. Then look in the station key
call this in the vanilla console he will get the construction id
Codeapi.engine.system.streetConnectorSystem.getStation2ConstructionMap()[game.interface.getEntity(station_group_id_seen_from_ui).stations[1]]
then if game.interface.bulldoze is callable, he can try to remove it
the game api give the proposal constructor to remove a construction, but they forgot to give the command builder for that..
-
call this in the vanilla consol
EDIT: I don't understand "station_group_id_seen_from_ui" inside the call.
If I try to use the id found for the actual damaged construction, I get this:
api.engine.system.streetConnectorSystem.getStation2ConstructionMap()[game.interface.getEntity(249965).stations[1]]
I have rechecked with my script the id for the station once again and it confuses me when this call writes the same number as entered inside the call.
Anyway, I have after the call above tried to bulldoze the Id (in script thread)
game.interface.bulldoze(249965)
and the same error as before was returned.
Scrolling the map into the area where the station is located is still creating a CTD.
-
I've tried it seems only ug is able to help you fix the map
Even with vanilla api it doesn't work
>> p = api.type.SimpleProposal.new()
>> p.constructionsToRemove = {66248}
>> c = api.cmd.make.buildProposal(p, nil, true)
c:\build\tpf2_steam\src\lib\ecs\engine.h:275: int __cdecl ecs::Engine::GetComponentDataIndex(const class ecs::Entity &,int) const: Assertion `it != components.end()' failed.
>