Access Violation
by Ian Omroth Hardingham · in Torque Game Builder · 02/26/2005 (3:32 pm) · 8 replies
Okay, so this is probably me being stupid but I can't see what I've done so I'll post it.
I've put the following in T2D/client/client.cs, at the bottom:
And T2D crashes with an access violation, with a stack trace which looks like this:

Anyone? That image is there (yes, I've made a new imags directory).
Ian
I've put the following in T2D/client/client.cs, at the bottom:
datablock fxImageMapDatablock2d(boneMan)
{
mode = "full";
textureName = "~/images/playerMissile";
};And T2D crashes with an access violation, with a stack trace which looks like this:

Anyone? That image is there (yes, I've made a new imags directory).
Ian
About the author
Designer and lead programmer on Frozen Synapse, Frozen Endzone, and Determinance. Co-owner of Mode 7 Games.
#2
No, that isn't the problem. I've tried the images directory in the default location.
Ian
02/26/2005 (4:29 pm)
Hey Harold, thanks for the reply.No, that isn't the problem. I've tried the images directory in the default location.
Ian
#3
02/26/2005 (4:39 pm)
Think you could post the image?
#4
Could you send me the image please ASAP?
This is a low-level TGE thing as you can see but I'd like to know why it's happening.
Look forward to your reply Ian.
Thanks,
- Melv.
02/27/2005 (3:09 am)
Woah!Could you send me the image please ASAP?
This is a low-level TGE thing as you can see but I'd like to know why it's happening.
Look forward to your reply Ian.
Thanks,
- Melv.
#5
www.omroth.com/playermissile.png
However, this is just the default player missile picture from the space shooter. I guess it's possible I've corrupted it somehow...
Maybe I've accidentally changed some of the source or a script file or something, but I don't think so.
Ian
02/27/2005 (4:46 am)
Hey guys.www.omroth.com/playermissile.png
However, this is just the default player missile picture from the space shooter. I guess it's possible I've corrupted it somehow...
Maybe I've accidentally changed some of the source or a script file or something, but I don't think so.
Ian
#6
Before I look into this further, one of the things you need to be careful of is that you cannot do any graphics operations at all before the canvas is initialised. The graphics layer depends on the canvas being initialised.
If you are executing an imageMap definition before the [b]InitCanvas("T2D");[b] call, you'll get the exact same error.
The examples show datablocks being exec'd after this call and if I change when this is done, I get the same problem.
- Melv.
02/27/2005 (5:36 am)
Ian,Before I look into this further, one of the things you need to be careful of is that you cannot do any graphics operations at all before the canvas is initialised. The graphics layer depends on the canvas being initialised.
If you are executing an imageMap definition before the [b]InitCanvas("T2D");[b] call, you'll get the exact same error.
The examples show datablocks being exec'd after this call and if I change when this is done, I get the same problem.
- Melv.
#7
That has fixed the problem, thank you very much for your time. I'll declare my datablocks elsewhere.
Viva T2D!
Ian
02/27/2005 (7:12 am)
Hey Melv.That has fixed the problem, thank you very much for your time. I'll declare my datablocks elsewhere.
Viva T2D!
Ian
#8
As you know, we'll be putting together more doco and this will probably be in some kind of FAQ or something.
Many thanks,
- Melv.
02/27/2005 (7:14 am)
@Ian: Cool, no problems, thanks for reporting it.As you know, we'll be putting together more doco and this will probably be in some kind of FAQ or something.
Many thanks,
- Melv.
Torque Owner Harold "LabRat" Brown
datablock fxImageMapDatablock2d(boneMan) { mode = "full"; textureName = "~/client/images/playerMissile"; };~ means from the root path of the current MOD