FS-Driverless / Formula-Student-Driverless-Simulator

A virtual world where Autonomous Systems from different Formula Student teams can compete in time-trial challenges
https://fs-driverless.github.io/Formula-Student-Driverless-Simulator
GNU General Public License v2.0
196 stars 83 forks source link

Game crashes when launching map directly #192

Closed SijmenHuizenga closed 4 years ago

SijmenHuizenga commented 4 years ago

Way to reproduce in v1.0.0 windows package

 ./FSDS.exe /Game/TrainingMap?

output:

LogPhysics: Warning: Scale for /Game/TrainingMap.TrainingMap:PersistentLevel.StartFinishLine.Start/Finish Line has a component set to zero, which will result in a bad body instance. Scale:X=0.000 Y=6.000 Z=1.000
LogSpawn: Warning: SpawnActor failed because the given transform (nan,nan,-nan(ind)|0.000000,0.000000,0.000000|1.000000,1.000000,1.000000) is invalid
LogWindows: Error: === Critical error: ===
LogWindows: Error:
LogWindows: Error: Fatal error!
LogWindows: Error:
LogWindows: Error: Unhandled Exception: EXCEPTION_ACCESS_VIOLATION writing address 0x00000290
LogWindows: Error:
LogWindows: Error: [Callstack] 0x00007ff70a909f43 Blocks-Win64-DebugGame.exe!ASimModeBase::initializeCameraDirector() [C:\Users\sijme\Formula-Student-Driverless-Simulator\UE4Project\Plugins\AirSim\Source\SimMode\SimModeBase.cpp:334]
LogWindows: Error: [Callstack] 0x00007ff70a935de8 Blocks-Win64-DebugGame.exe!ASimModeBase::setupVehiclesAndCamera() [C:\Users\sijme\Formula-Student-Driverless-Simulator\UE4Project\Plugins\AirSim\Source\SimMode\SimModeBase.cpp:408]
LogWindows: Error: [Callstack] 0x00007ff70a891fa0 Blocks-Win64-DebugGame.exe!ASimModeBase::BeginPlay() [C:\Users\sijme\Formula-Student-Driverless-Simulator\UE4Project\Plugins\AirSim\Source\SimMode\SimModeBase.cpp:73]
LogWindows: Error: [Callstack] 0x00007ff70a8920c3 Blocks-Win64-DebugGame.exe!ASimModeCar::BeginPlay() [C:\Users\sijme\Formula-Student-Driverless-Simulator\UE4Project\Plugins\AirSim\Source\Vehicles\Car\SimModeCar.cpp:17]
SijmenHuizenga commented 4 years ago

This might have something to do with different startup order in the pacakged version https://forums.unrealengine.com/unreal-engine/feedback-for-epic/1368992-rationale-behind-different-startup-order-of-the-blueprint-framework-between-editor-and-packaged

SijmenHuizenga commented 4 years ago

This change fixed it: https://github.com/FS-Online/Formula-Student-Driverless-Simulator/pull/183/commits/28d02daae649b369ac5482e542306521a0043445#diff-00ee55353936d24c2a227d75fca47aefR57-L62