Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scripted Thunderstorm crashes the game. #3043

Open
6 tasks done
tylerandari13 opened this issue Aug 11, 2024 · 5 comments
Open
6 tasks done

Scripted Thunderstorm crashes the game. #3043

tylerandari13 opened this issue Aug 11, 2024 · 5 comments

Comments

@tylerandari13
Copy link
Contributor

SuperTux Version

v0.6.3-1318-gd63d4798e

System Information

Linux 5.15.0-56-generic #62-Ubuntu SMP Tue Nov 22 19:54:14 UTC 2022 x86_64 (i think)

Steps To Reproduce Crash

If you run thunder.lightning() before thunder.thunder() is finished thunder.thunder()ing the game crashes.

This is the script. There is a thunderstorm object named thunder in the sector.

thunder.thunder()
thunder.lightning()

You can put this in the sector initialization script. The game will crash upon playing the level.

Debugging Information (Stacktrace)

/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN12ErrorHandler14get_stacktraceB5cxx11Ev+0x3a) [0x55785d09b0c0]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN12ErrorHandler12handle_errorEi+0x80) [0x55785d09b430]
/lib/x86_64-linux-gnu/libc.so.6(+0x42520) [0x7fbfc2ef9520]
/lib/x86_64-linux-gnu/libc.so.6(pthread_kill+0x12c) [0x7fbfc2f4da7c]
/lib/x86_64-linux-gnu/libc.so.6(raise+0x16) [0x7fbfc2ef9476]
/lib/x86_64-linux-gnu/libc.so.6(abort+0xd3) [0x7fbfc2edf7f3]
/lib/x86_64-linux-gnu/libc.so.6(+0x2871b) [0x7fbfc2edf71b]
/lib/x86_64-linux-gnu/libc.so.6(+0x39e96) [0x7fbfc2ef0e96]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN5ColorC1Effff+0xa9) [0x55785cd8a8d9]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZNK5Color14CalculateColor8validateEv+0x5a) [0x55785cd3468e]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN12Thunderstorm24change_background_colorsEbb+0x137) [0x55785d05b0e3]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN12Thunderstorm17lightning_generalEb+0xce) [0x55785d05ac36]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN12Thunderstorm9lightningEv+0x21) [0x55785d05ae65]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZSt13__invoke_implIvRKM12ThunderstormFvvEPS0_JEET_St21__invoke_memfun_derefOT0_OT1_DpOT2_+0x6a) [0x55785d05e487]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZSt8__invokeIRKM12ThunderstormFvvEJPS0_EENSt15__invoke_resultIT_JDpT0_EE4typeEOS7_DpOS8_+0x3b) [0x55785d05e0dd]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZNKSt12_Mem_fn_baseIM12ThunderstormFvvELb1EEclIJPS0_EEEDTcl8__invokedtdefpT6_M_pmfspcl7forwardIT_Efp_EEEDpOS6_+0x32) [0x55785d05df7c]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZSt13__invoke_implIvRSt7_Mem_fnIM12ThunderstormFvvEEJPS1_EET_St14__invoke_otherOT0_DpOT1_+0x3b) [0x55785d05ddb3]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZSt10__invoke_rIvRSt7_Mem_fnIM12ThunderstormFvvEEJPS1_EENSt9enable_ifIX16is_invocable_r_vIT_T0_DpT1_EES8_E4typeEOS9_DpOSA_+0x3b) [0x55785d05da8c]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZNSt17_Function_handlerIFvP12ThunderstormESt7_Mem_fnIMS0_FvvEEE9_M_invokeERKSt9_Any_dataOS1_+0x3b) [0x55785d05d663]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZNKSt8functionIFvP12ThunderstormEEclES1_+0x4d) [0x55785d05e09b]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(+0xcfcc1b) [0x55785d05bc1b]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN3ssq6detail4funcILi0EvJP12ThunderstormEE6globalEP4SQVM+0x4f) [0x55785d05dbab]
/home/tylerandari12/STcompilation/supertux-ninjabuild/external/simplesquirrel/libsimplesquirrel.so(_ZN4SQVM10CallNativeEP15SQNativeClosurexxR11SQObjectPtriRbS4_+0x1d0) [0x7fbfc3a7e7d0]
/home/tylerandari12/STcompilation/supertux-ninjabuild/external/simplesquirrel/libsimplesquirrel.so(_ZN4SQVM7ExecuteER11SQObjectPtrxxS1_yNS_13ExecutionTypeE+0x1e40) [0x7fbfc3a81110]
/home/tylerandari12/STcompilation/supertux-ninjabuild/external/simplesquirrel/libsimplesquirrel.so(sq_wakeupvm+0xbb) [0x7fbfc3a5bc8b]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN17SquirrelScheduler6updateEf+0x13e) [0x55785d08b3bc]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN19SquirrelEnvironment6updateEf+0x3a) [0x55785d089414]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN6Sector6updateEf+0x10b) [0x55785cd2e06f]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN11GameSession6updateEfRK10Controller+0x921) [0x55785cc898f9]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN13ScreenManager16update_gamelogicEf+0xd2) [0x55785cd25e28]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN13ScreenManager9loop_iterEv+0x364) [0x55785cd26fa6]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN13ScreenManager3runEv+0x2f) [0x55785cd271ff]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN4Main11launch_gameERK20CommandLineArguments+0x122b) [0x55785cca7e9b]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_ZN4Main3runEiPPc+0x2ad) [0x55785cca8617]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(main+0x73) [0x55785cb360ec]
/lib/x86_64-linux-gnu/libc.so.6(+0x29d90) [0x7fbfc2ee0d90]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x80) [0x7fbfc2ee0e40]
/home/tylerandari12/STcompilation/supertux-ninjabuild/supertux2(_start+0x25) [0x55785cb35fb5]

Additional Information

This is especially deadly with skippable cutscenes as those cause everything to run at once.

Guidelines For Reporting Issues

  • I have read https://github.com/SuperTux/supertux/blob/master/CONTRIBUTING.md#bug-reports.
  • I have verified this isn't an issue that's already been reported.
  • I have verified this isn't a discussion, or an issue about unintended behavior or a feature request, but rather an actual crash ─ that is, the game closed unexpectedly.
  • I have verified this issue is not about wrong translations (use Transifex for those), or anything unsupported (e.g. third-party add-ons).
  • In this report, I have only included details about one (1) crash.
  • If I make a mistake while submitting this report, I agree to use the "Edit" feature to correct it, instead of closing this issue and opening a new one.
@tobbi
Copy link
Member

tobbi commented Aug 11, 2024

Can you recompile with -DCMAKE_BUILD_TYPE=Debug and then get a proper stack trace?

@MatusGuy
Copy link
Member

If you look hard enough you'll find that is a proper stacktrace

@Brockengespenst
Copy link
Contributor

You could use c++filt to make it more readable.

@tobbi
Copy link
Member

tobbi commented Aug 12, 2024

We're hitting this assertion: Assertion failed: (0 <= red && red <= 1.0f), function Color, file color.cpp, line 43.

In new_color.validate()

@tylerandari13
Copy link
Contributor Author

We're hitting this assertion: Assertion failed: (0 <= red && red <= 1.0f), function Color, file color.cpp, line 43.

In new_color.validate()

Then I believe #2993 would fix this issue. Any chance we can get this reviewed/merged? <:snowsmiley:1123534474987180062>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants