Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Sparkys crashes my game. ??

Author
Message
prasoc
15
Years of Service
User Offline
Joined: 8th Oct 2008
Location:
Posted: 27th Jul 2009 01:06
When someone joins my server, it sends out a packet to everyone else to add a client. At the moment, it makes a box but when I use SC_SetupObject, if I set the object up before the game loads, it crashes (I can see what happens in debug mode: the error is " Access violation writing location 0x00000000."), but when I am ingame and setup the object, it makes my character fall through the ground (?!??!?!?!) and doesn't crash. I think Sparkys has a bug in it.

Here is the line VC++ crashes on:



and the line above it is:



I have absolutely no idea why it does this, any tips?


Your signature has been erased by a mod
Mista Wilson
16
Years of Service
User Offline
Joined: 27th Aug 2008
Location: Brisbane, Australia
Posted: 27th Jul 2009 01:32 Edited at: 27th Jul 2009 01:35
Is your object scaled ? You need to call SC_AllowObjectScaling() if it is after you setup the object, if your object's postion changes at all, you need to call SC_UpdateObject()..

Perhaps try setting the object up as a complex object and see if you get the same problem...

Also, how are you detecting the collisions, what system of sparky's are you using, raycasting, sliding etc..

Lastly, I also had that same problem with sparky's with my character falling through the terrain.... it turned out the problem was where I was creating the character, it was too close to the ground, and started moving through it, before it was setup properly....

I fixed my problem by making my character model spawn a ceratin distance above the ground and to "fall" down to it.

EDIT : The exact cause of my problem was the "collision sphere", I was using sliding collision and raycasting, a mixed system from the sliding demo that comes with sparky's. Anyway, it turned out that when I created my character close to the ground, it's collision sphere was going through the ground at the point where it was detecting collision, so it didnt think it was on anything and fell... like I said above, just spawning the character in a little higher fixed it, although if you dont want your player to see your character falling to the ground you may need to hide it or exclude it or something

If it ain't broke.... DONT FIX IT !!!
prasoc
15
Years of Service
User Offline
Joined: 8th Oct 2008
Location:
Posted: 27th Jul 2009 02:49 Edited at: 27th Jul 2009 03:05
Ive tried all combinations of AllowScaling and updating at different points to no avail. The character going through the ground (i forgot to make it clear) is YOUR character when collision is applied to another character, not that character goes through ground, its yours (NO IDEA it baffles me)

EDIT: omg it took me this long to work this out! The ID of the object was too high! It was over 1 million (to leave some breathing space) and I set it down to 5k and it works fine!


Your signature has been erased by a mod

Login to post a reply

Server time is: 2024-10-01 08:39:47
Your offset time is: 2024-10-01 08:39:47