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.

DarkBASIC Professional Discussion / Collision Problem. pls help

Author
Message
Hello Everyone !
14
Years of Service
User Offline
Joined: 1st Sep 2011
Location:
Posted: 11th Sep 2011 17:35
Hi guys. i have a problem in my sprite collision. it is working but even my character is not stepping on it. my character is still floating .. can someone help about this pls. this is my code..




i have a problem in darkbasic codes. pls help me
Suicidal Sledder
21
Years of Service
User Offline
Joined: 17th Aug 2004
Location: Tikrit, Iraq
Posted: 12th Sep 2011 08:26
your description is very vague... more details would help!! It is possible though that your images have a large border around the actual sprite. I'm talking about the transparent background... If this is the case then you character would appear to float since DB checks the borders of the entire sprite whether it is transparent or not. Try trimming your source images and cropping them as closly as possible.

Hello Everyone !
14
Years of Service
User Offline
Joined: 1st Sep 2011
Location:
Posted: 13th Sep 2011 14:11
oh. sorry dude. here the link of the example what i am talking about.
http://i166.photobucket.com/albums/u110/glizgm/spritecollision.png

the floor has a right border side. it has no background. it really fits for the character. but is has a problem.

i have a problem in darkbasic codes. pls help me
darkvee
20
Years of Service
User Offline
Joined: 18th Nov 2005
Location:
Posted: 16th Sep 2011 13:21 Edited at: 16th Sep 2011 13:35
Hi Hello Everyone ! ,

You need a more simple jump system I know that. Can you send your project file with your media files? I'm to lazy right now to make a demo of jump code with platforms.

darkvee
Hello Everyone !
14
Years of Service
User Offline
Joined: 1st Sep 2011
Location:
Posted: 17th Sep 2011 06:40
ok i will send you my codes.. my codes is complete when it comes in jumping. it has gravity.

i have a problem in darkbasic codes. pls help me
Hello Everyone !
14
Years of Service
User Offline
Joined: 1st Sep 2011
Location:
Posted: 17th Sep 2011 06:41
what is your email?

i have a problem in darkbasic codes. pls help me
darkvee
20
Years of Service
User Offline
Joined: 18th Nov 2005
Location:
Posted: 18th Sep 2011 12:51
Hi Hello Everyone !,

Just attach a zip on your next post on this forum. After you write your message click browse next to attachment and find your project you zipped up and at the end click post to upload it.

darkvee
Hello Everyone !
14
Years of Service
User Offline
Joined: 1st Sep 2011
Location:
Posted: 18th Sep 2011 17:06 Edited at: 19th Sep 2011 08:13
oh. ok dude. just tell me whats the problem ok. tnx a lot. just go to the platform and you will see what is the problem.

i have a problem in darkbasic codes. pls help me
darkvee
20
Years of Service
User Offline
Joined: 18th Nov 2005
Location:
Posted: 20th Sep 2011 14:29
Hi Hello Everyone !,

I see the problem When you jump and when the player reaches his max jump and if he hits a platform it switches to falling = 0. When falling = 0 your not falling or jumping. So that's why you get that player floating problem. Just change that and it will fix that problem.

darkvee
Hello Everyone !
14
Years of Service
User Offline
Joined: 1st Sep 2011
Location:
Posted: 20th Sep 2011 18:07
Ok.

[edit]

Sir darkvee.. I change the falling=0 to falling=1. It has a problem. Everytime my character go to the platform it cannot be step on anymore. It will automatically fall. When i change the falling=0 to falling=2 or 3. It has a problem also. Evrytime my character go to the platform, the character cannot jump anymore and it is not falling. this is my only problem for my 2D side scrolling game. Your help will be much appreciated!

i have a problem in darkbasic codes. pls help me

Login to post a reply

Server time is: 2026-07-10 20:57:29
Your offset time is: 2026-07-10 20:57:29