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

Game Crashes when attempting to select "Script - None" #5142

Closed
DorpsGek opened this issue Apr 8, 2012 · 4 comments
Closed

Game Crashes when attempting to select "Script - None" #5142

DorpsGek opened this issue Apr 8, 2012 · 4 comments
Labels
component: AI/Game script (squirrel) This issue is related to Squirrel (Scripting language) flyspray This issue is imported from FlySpray (https://bugs.openttd.org/)

Comments

@DorpsGek
Copy link
Member

DorpsGek commented Apr 8, 2012

CrazySquirrel opened the ticket and wrote:

Played a game with a Script, now I want to play a game without the script, but whenever i changed it to game script none, the game instantly crashes to desktop (per attached).

Tried using RC3 & RC4 - using windows 7.

Attachments

Reported version: 1.2.0-RC4
Operating system: Windows


This issue was imported from FlySpray: https://bugs.openttd.org/task/5142
@DorpsGek
Copy link
Member Author

DorpsGek commented Apr 8, 2012

CrazySquirrel wrote:

this is a later attempt crash.png shows the point it actually crashes.

Attachments


This comment was imported from FlySpray: https://bugs.openttd.org/task/5142#comment11069

@DorpsGek
Copy link
Member Author

DorpsGek commented Apr 8, 2012

Rubidium wrote:

Information from crash.dmp:

FAULTING_IP:
openttd!ScriptInfo::GetSettingDefaultValue+4 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\script\script_info.cpp @ 284]
00000001`3f465018 4c8b4120 mov r8,qword ptr [rcx+20h]

EXCEPTION_RECORD: ffffffffffffffff -- (.exr 0xffffffffffffffff)
.exr 0xffffffffffffffff
ExceptionAddress: 000000013f465018 (openttd!ScriptInfo::GetSettingDefaultValue+0x0000000000000004)
ExceptionCode: c0000005 (Access violation)
ExceptionFlags: 00000000
NumberParameters: 2
Parameter[0]: 0000000000000000
Parameter[1]: 0000000000000020
Attempt to read from address 0000000000000020

PROCESS_NAME: openttd.exe

ADDITIONAL_DEBUG_TEXT:
Use '!findthebuild' command to search for the target build information.
If the build information is available, run '!findthebuild -s ; .reload' to set symbol path and load symbols.

MODULE_NAME: openttd

FAULTING_MODULE: 0000000076ee0000 ntdll

DEBUG_FLR_IMAGE_TIMESTAMP: 4f777fa2

ERROR_CODE: (NTSTATUS) 0xc0000005 - The instruction at "0x%08lx" referenced memory at "0x%08lx". The memory could not be "%s".

EXCEPTION_CODE: (NTSTATUS) 0xc0000005 - The instruction at "0x%08lx" referenced memory at "0x%08lx". The memory could not be "%s".

EXCEPTION_PARAMETER1: 0000000000000000

EXCEPTION_PARAMETER2: 0000000000000020

READ_ADDRESS: 0000000000000020

FOLLOWUP_IP:
openttd!ScriptInfo::GetSettingDefaultValue+4 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\script\script_info.cpp @ 284]
00000001`3f465018 4c8b4120 mov r8,qword ptr [rcx+20h]

MOD_LIST:

FAULTING_THREAD: 000000000000127c

BUGCHECK_STR: APPLICATION_FAULT_NULL_CLASS_PTR_DEREFERENCE_INVALID_POINTER_READ_WRONG_SYMBOLS

PRIMARY_PROBLEM_CLASS: NULL_CLASS_PTR_DEREFERENCE

DEFAULT_BUCKET_ID: NULL_CLASS_PTR_DEREFERENCE

LAST_CONTROL_TRANSFER: from 000000013f463961 to 000000013f465018

STACK_TEXT:
00000000`0020e820 00000001`3f463961 : 00000000`02355840 00000000`02355840 00000000`08c41450 00000000`08bb0230 : openttd!ScriptInfo::GetSettingDefaultValue+0x4 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\script\script_info.cpp @ 284]
00000000`0020e850 00000001`3f4a72ed : 00000000`08bb0230 00000000`08bb0230 00000000`02355840 00000000`02353dd0 : openttd!ScriptConfig::GetSetting+0x3d [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\script\script_config.cpp @ 91]
00000000`0020e880 00000001`3f49d3e8 : 00000000`091f4020 00000000`0020ee20 00000000`09585fc8 00000000`0946f960 : openttd!SQConvert::HelperT<int (__cdecl*)(char const * __ptr64),0>::SQCall+0xd9 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\script\squirrel_helper.hpp @ 225]
00000000`0020e8f0 00000001`3f488368 : 00000000`022cc080 00000001`3f483dcf 00000000`0227e090 00000001`3f488b54 : openttd!SQConvert::DefSQStaticCallback<ScriptController,int (__cdecl*)(char const * __ptr64)>+0x3c [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\script\squirrel_helper.hpp @ 827]
00000000`0020e930 00000001`3f485e24 : 00000000`091f4020 00000000`091f4140 00000000`00000001 00000000`0000001f : openttd!SQVM::CallNative+0x2d4 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\3rdparty\squirrel\squirrel\sqvm.cpp @ 1178]
00000000`0020ea10 00000001`3f4680e0 : 00000000`091f4020 00000000`00000000 00000000`00000000 00002f88`fffffc70 : openttd!SQVM::Execute+0xa58 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\3rdparty\squirrel\squirrel\sqvm.cpp @ 787]
00000000`0020ebc0 00000001`3f465f66 : 00000000`00000000 00000000`00000000 00000000`08c112f0 00000001`3fba43d0 : openttd!Squirrel::Resume+0x94 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\script\squirrel.cpp @ 202]
00000000`0020ec20 00000001`3f4a7ed4 : 00000000`02355180 00000000`00000000 00000000`00000001 00000001`3fba43d0 : openttd!ScriptInstance::GameLoop+0x272 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\script\script_instance.cpp @ 211]
00000000`0020ecc0 00000001`3f2fa9d8 : 00000000`00000001 00000001`3fba43d0 00000001`3fba43d0 00000000`04951f19 : openttd!Game::GameLoop+0x74 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\game\game_core.cpp @ 45]
00000000`0020ed20 00000001`3f2fad4b : 00000000`064e5700 00000000`064e5700 00000000`064e5744 00000000`00000000 : openttd!StateGameLoop+0x1c0 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\openttd.cpp @ 1305]
00000000`0020eea0 00000001`3f5510a1 : 00000000`064e5744 00000000`0020f100 00000000`064e5734 00000000`00000000 : openttd!GameLoop+0x133 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\openttd.cpp @ 1398]
00000000`0020efb0 00000001`3f2f8dd2 : 00000000`01d2a530 00000000`0020f140 00000000`01f6d730 00000000`01f6d730 : openttd!VideoDriver_Win32::MainLoop+0x389 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\video\win32_v.cpp @ 1018]
00000000`0020f040 00000001`3f55358e : 00000000`00000000 00000000`0020f2a0 00000000`00000001 0000017a`00000000 : openttd!ttd_main+0xe26 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\openttd.cpp @ 833]
00000000`0020f280 00000001`3f64e68c : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : openttd!WinMain+0x132 [c:\bamboo-agent-home\xml-data\build-dir\ottd-rls-w64bit\src\os\windows\win32.cpp @ 452]
00000000`0020fa90 00000000`76a6652d : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : openttd!__tmainCRTStartup+0x154 [f:\dd\vctools\crt_bld\self_64_amd64\crt\src\crt0.c @ 275]
00000000`0020fb40 00000000`00000000 : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : kernel32+0x1652d

STACK_COMMAND: ~0s; .ecxr ; kb

SYMBOL_STACK_INDEX: 0

SYMBOL_NAME: openttd!ScriptInfo::GetSettingDefaultValue+4

FOLLOWUP_NAME: MachineOwner

IMAGE_NAME: openttd.exe

BUCKET_ID: WRONG_SYMBOLS

FAILURE_BUCKET_ID: NULL_CLASS_PTR_DEREFERENCE_c0000005_openttd.exe!ScriptInfo::GetSettingDefaultValue

WATSON_STAGEONE_URL: http://watson.microsoft.com/StageOne/openttd_exe/1_2_0_24084/4f777fa2/openttd_exe/1_2_0_24084/4f777fa2/c0000005/001b5018.htm?Retriage=1

Followup: MachineOwner
---------


This comment was imported from FlySpray: https://bugs.openttd.org/task/5142#comment11071

@DorpsGek
Copy link
Member Author

DorpsGek commented Apr 9, 2012

frosch wrote:

Not reproducible in trunk. Easily reproducible in 1.2 branch.

The titlegame of the 1.2 branch causes the selected game script to run in the main screen, which then causes a crash when it is disabled.

So, somehow this is related to how the 1.2 titlegame is loaded, no GS should become active in the main screen.


This comment was imported from FlySpray: https://bugs.openttd.org/task/5142#comment11073

@DorpsGek
Copy link
Member Author

DorpsGek commented Apr 9, 2012

frosch closed the ticket.

Reason for closing: Fixed

in r24108


This comment was imported from FlySpray: https://bugs.openttd.org/task/5142

@DorpsGek DorpsGek closed this as completed Apr 9, 2012
@DorpsGek DorpsGek added flyspray This issue is imported from FlySpray (https://bugs.openttd.org/) Goal/Game script labels Apr 7, 2018
@frosch123 frosch123 added the component: AI/Game script (squirrel) This issue is related to Squirrel (Scripting language) label Apr 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: AI/Game script (squirrel) This issue is related to Squirrel (Scripting language) flyspray This issue is imported from FlySpray (https://bugs.openttd.org/)
Projects
None yet
Development

No branches or pull requests

2 participants