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 / Per-Pixel Image Overlay Collision

Author
Message
SushiBox
16
Years of Service
User Offline
Joined: 20th Sep 2008
Location: Ohio
Posted: 23rd Oct 2008 02:49 Edited at: 25th Oct 2008 20:22
EDIT: I am scraping this idea. Sorry.

www.Helios-Online.net
Mahoney
16
Years of Service
User Offline
Joined: 14th Apr 2008
Location: The Interwebs
Posted: 23rd Oct 2008 06:36 Edited at: 23rd Oct 2008 06:37
Well, I've looked over it quite a bit, and all I have for now is this: you're using the character sprite before it's loaded. You never load image 100 and never create sprite 100.

Tomorrow, I'll come back and help you out with this some more.

Windows Vista Home Premium Intel Pentium Dual-Core 1.6 Ghz 1GB DDR2 RAM GeForce 8600GT Twin Turbo
SushiBox
16
Years of Service
User Offline
Joined: 20th Sep 2008
Location: Ohio
Posted: 23rd Oct 2008 23:05 Edited at: 25th Oct 2008 20:23
Edit: source removed

I thought this here Loads and Creates sprite 100, it is also called after LoadImages(). Thanks for the help though, this has been killing me haha.

www.Helios-Online.net
Mahoney
16
Years of Service
User Offline
Joined: 14th Apr 2008
Location: The Interwebs
Posted: 24th Oct 2008 05:05
Yes, but you're setting its priority before loading it. Also, you're calling SpriteCollision() and using it before it's created.

Windows Vista Home Premium Intel Pentium Dual-Core 1.6 Ghz 1GB DDR2 RAM GeForce 8600GT Twin Turbo
SushiBox
16
Years of Service
User Offline
Joined: 20th Sep 2008
Location: Ohio
Posted: 24th Oct 2008 15:43
Ok, I changed the order around and when I do this the whole client freezes. I made the dbSprite call for the player in its own function so it can stay a part of the loop, but all the other images are now called in LoadImages(). They go in this order.

1. Load the images: dbLoadImage()
2. Set the sprite: dbSprite()
3. Create the animated sprite for the player
4. Set Priority

All of these are set in the main. PlayerSprite() is called in the loop and looks like this.

Quote: "
void PlayerSprite()
{
dbSprite( 100, playerx, playery, 100 ); // Player
}
"


The collision is called AFTER LoadImages() in the main. I get a do not send error, no debug errors at all.

www.Helios-Online.net
Mahoney
16
Years of Service
User Offline
Joined: 14th Apr 2008
Location: The Interwebs
Posted: 24th Oct 2008 20:37
Please update the OP with your changes, and upload a ZIP of the source files (including images) so I can try it myself.

Windows Vista Home Premium Intel Pentium Dual-Core 1.6 Ghz 1GB DDR2 RAM GeForce 8600GT Twin Turbo
SushiBox
16
Years of Service
User Offline
Joined: 20th Sep 2008
Location: Ohio
Posted: 25th Oct 2008 15:39 Edited at: 25th Oct 2008 20:23
Original Post is updated and here is a RAR with the images. Just make the proper folders for them. Also don't mind the splash screen stuff.

EDIT: Attachment removed.

www.Helios-Online.net

Login to post a reply

Server time is: 2024-11-25 05:36:39
Your offset time is: 2024-11-25 05:36:39