Gamestudio Links
Zorro Links
Newest Posts
ZorroGPT
by TipmyPip. 02/21/26 19:15
Camera always moves upwards?
by clonman. 02/21/26 09:29
Zorro version 3.0 prerelease!
by TipmyPip. 02/20/26 13:22
Sam Foster Sound | Experienced Game Composer for Hire
by titanicpiano14. 02/19/26 13:22
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
0 registered members (), 7,008 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
alx, ApprenticeInMuc, PatrickH90, USER0328, Sfrdragon
19199 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
level loading crashes #375192
06/24/11 07:49
06/24/11 07:49
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline OP
Expert
Germanunkol  Offline OP
Expert

Joined: Jun 2006
Posts: 2,640
Earth
Code:
logNewMessage(level, debugLog, OFF);
	
	posPredictDummy = NULL;
	ship = NULL;
	sys_marker("l00");
	level_load(level); //loads the level which is loaded on the server

	sys_marker("l01");
	camEnt = NULL;

	sys_marker("l02");
	logNewMessage("l01", debugLog, OFF);



I get a script crash in l00. Any Idea? the level string is exactly the same as the rounds before: "playground.wmb"

Last edited by Germanunkol; 06/24/11 07:49.

~"I never let school interfere with my education"~
-Mark Twain
Re: level loading crashes [Re: Germanunkol] #375194
06/24/11 07:58
06/24/11 07:58
Joined: Jan 2004
Posts: 3,023
The Netherlands
Helghast Offline
Expert
Helghast  Offline
Expert

Joined: Jan 2004
Posts: 3,023
The Netherlands
is level an actual string not a char? did you str_create it? does it contain invalid characters (unicode or something)?


Formerly known as dennis_fantasy
Portfolio - http://www.designorhea.com/
Project - http://randomchance.cherrygames.org/
Re: level loading crashes [Re: Helghast] #375195
06/24/11 08:10
06/24/11 08:10
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline OP
Expert
Germanunkol  Offline OP
Expert

Joined: Jun 2006
Posts: 2,640
Earth
Maybe I should've added: 90% of the time, this works perfectly fine.


~"I never let school interfere with my education"~
-Mark Twain
Re: level loading crashes [Re: Germanunkol] #375196
06/24/11 08:57
06/24/11 08:57
Joined: Apr 2007
Posts: 3,751
Canada
WretchedSid Offline
Expert
WretchedSid  Offline
Expert

Joined: Apr 2007
Posts: 3,751
Canada
Do you use a temporary STRING object created via _str()?


Shitlord by trade and passion. Graphics programmer at Laminar Research.
I write blog posts at feresignum.com
Re: level loading crashes [Re: WretchedSid] #375199
06/24/11 09:03
06/24/11 09:03
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline OP
Expert
Germanunkol  Offline OP
Expert

Joined: Jun 2006
Posts: 2,640
Earth
Does it matter? The logging function 4 lines above the level load logs correctly...


~"I never let school interfere with my education"~
-Mark Twain
Re: level loading crashes [Re: Germanunkol] #375208
06/24/11 11:10
06/24/11 11:10
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Have you got some global functions that access entity pointers?
Have you tried to load the level a few times without any players, turrets, and the like?


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: level loading crashes [Re: Superku] #375260
06/24/11 16:16
06/24/11 16:16
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline OP
Expert
Germanunkol  Offline OP
Expert

Joined: Jun 2006
Posts: 2,640
Earth
Yeah, I've tried it.
IF there is global functions that access the pointer, then they certainly cannot run between the logNewMessage and the level_load...?
There's no wait(1) inbetween, and logNewMessage doesn't actually modify the string it gets... unless the file_str_write command modifies a pointer...


~"I never let school interfere with my education"~
-Mark Twain
Re: level loading crashes [Re: Germanunkol] #375267
06/24/11 17:27
06/24/11 17:27
Joined: Aug 2000
Posts: 1,141
Baunatal, Germany
Tobias Offline

Moderator
Tobias  Offline

Moderator

Joined: Aug 2000
Posts: 1,141
Baunatal, Germany
When you dont use a level load event and you get the crash in l00, its probably your level that crashes and not your script. Otherwise you would get the crash in 102 or at other places in your script.

Re: level loading crashes [Re: Germanunkol] #375268
06/24/11 17:27
06/24/11 17:27
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Code:
then they certainly cannot run between the logNewMessage and the level_load...?


I don't talk about the string, I talk about other global functions that access f.i. entity pointers, which become invalid during level_load. Additionally, be aware that pointers only become invalid, but are not set to NULL automatically.


EDIT: The level_load process usually takes several frames, otherwise you could not display a loading bar with on_level as an example. I don't know if global "wait-functions" are executed during these frames, though.

Last edited by Superku; 06/24/11 17:29.

"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: level loading crashes [Re: Superku] #375270
06/24/11 17:50
06/24/11 17:50
Joined: Aug 2000
Posts: 1,141
Baunatal, Germany
Tobias Offline

Moderator
Tobias  Offline

Moderator

Joined: Aug 2000
Posts: 1,141
Baunatal, Germany
I'm pretty sure level_load happens within a single frame. Otherwise you would not need an on_level event for displaying a loading bar. But entity actions are started during level_load, so there could also be a possible crash.

Page 1 of 2 1 2

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1