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.

2D All the way! / Come on, tell me the truth!

Author
Message
trouper
20
Years of Service
User Offline
Joined: 15th Jul 2005
Location: Texas
Posted: 16th Jul 2005 14:05
It sucks, right...

http://darkbasic.thegamecreators.com/?m=codebase_view&i=66dd9e554e00b0b0751cdea138b5e7cc

trillianmikey
Grog Grueslayer
Valued Member
21
Years of Service
User Offline
Joined: 30th May 2005
Playing: Green Hell
Posted: 18th Jul 2005 04:32
It would be better to lower the number of sprites on the screen at once. I was getting 2 frames per second... which is VERY BAD. Use only about 10 to 15 bad guy sprites. At a glance it looks like you have about 55 bad guy sprites... that's what causes the slowdown. You can create a routine that replaces any sprites that get hit... so the sprite count is always the same.

The sync rate needs to be set at zero too. Zero will sync the display as fast as the computer running it can update the screen.

Speed it up with the above suggestions and you've got a really good game. I love da-man graphics.
trouper
20
Years of Service
User Offline
Joined: 15th Jul 2005
Location: Texas
Posted: 19th Jul 2005 06:31
Cool thanks for the responds. I knew the game was slow and I needed some feedback. I'm kind of new and im not sure how to pull off a routine? Any help would be awesome.

trillianmikey
trouper
20
Years of Service
User Offline
Joined: 15th Jul 2005
Location: Texas
Posted: 19th Jul 2005 06:35
Oh, thanks....
Yeah the game is uber' slow, kind of sucks that's why I needed some feedback. I'm still really new to programming and game stuff. I could use some help pulling off some 'routine' if anyone could help out, would be awesome.

trillianmikey
Grog Grueslayer
Valued Member
21
Years of Service
User Offline
Joined: 30th May 2005
Playing: Green Hell
Posted: 19th Jul 2005 16:20 Edited at: 19th Jul 2005 16:20
I won't re-code the whole game for you but i'll point you in the right direction.

First your do loop is way too big. You need to use functions to split up all the code to small functions. If you need help with functions heres a link to a message talking about them.

http://forum.thegamecreators.com/?m=forum_view&t=57265&b=10

Second you can achieve the same results by putting the x coordinates of each bad guy sprite in a dim statement. Instead of having: j jj jjj jjjj jjjjj jjjjjj You can take it all down to:



When things are dimed like that you can easily switch with a simple for next loop:



So it's easy to move all sprites with one for next loop rather than 15 lines of basically the same code.

Try some things out and if you get stuck post the code you've got so far and i'll try to help you more.
Megaton Cat
22
Years of Service
User Offline
Joined: 24th Aug 2003
Location: Toronto, Canada
Posted: 20th Jul 2005 02:18
Who are you talking to?


Need a team? No noob bullshit, visit http://www.teamrequest.com
Robot
22
Years of Service
User Offline
Joined: 27th May 2004
Location:
Posted: 20th Jul 2005 04:03
It's different people, same avatar.

The happenings of tommorow are behind us now
Grog Grueslayer
Valued Member
21
Years of Service
User Offline
Joined: 30th May 2005
Playing: Green Hell
Posted: 20th Jul 2005 07:35 Edited at: 20th Jul 2005 09:26
It's kinda freaking me out too.

Edit: I found a new one on the internet and changed it a bit so this repeat avatar thing won't happen again (at least to me).

Login to post a reply

Server time is: 2026-06-12 13:02:56
Your offset time is: 2026-06-12 13:02:56