The Daily Click ::. Forums ::. Klik Coding Help ::. "fixed style" jumping.
 

Post Reply  Post Oekaki 
 

Posted By Message

columbo borgi :C



Registered
  07/12/2003
Points
  296

VIP Member
17th April, 2008 at 13:09:25 -

yo there fellas, here i go again.

im working on a project, which wont be completed i bet. but, i need a "jumpstyle" (no, not the music, neither the dance) which has got fixed points. i my toughts i'd make jump like this:

if a=1 then b = b+1
if b>50 set a=2
if a=2 then b = b-1
always player position is x, and y+b

bit its kind of poor.

i need "fixed style" coz i want it jump thingy use in a multiplayer game. im sure you know what i mean.

any suggestions? :/

 
:C

Hempuli

Crazy?

Registered
  09/01/2005
Points
  7968

Game of the Week WinnerGOTM JULY - 2009 - 2ND PLACE!GOTM AUGUST- 2009 - 2ND PLACE!GOTM OCTOBER 2009 - WINNERI am an April FoolGame of the Week Winner - MARCH 2010!-
19th April, 2008 at 15:53:02 -

If flag 0 is off (it's on only if the object is on the ground)
-add x to value B

If value B => y
-add 1 to value A

Always
-set Y position to Y(object) + alterable value A (object)

That's what I use.

 
No sig for you.

Knudde (Shab)

Administrator
Crazy?

Registered
  31/01/2003
Points
  5125

Has Donated, Thank You!Clickzine StaffKlikCast StarVIP MemberGhostbuster!Dos Rules!I donated an open source project
19th April, 2008 at 16:33:52 -


Originally Posted by Hempuli
If flag 0 is off (it's on only if the object is on the ground)
-add x to value B

If value B => y
-add 1 to value A

Always
-set Y position to Y(object) + alterable value A (object)

That's what I use.



Uhh, what? Looking at this I can't understand how it works. It seems like you're using the X position to determine if the player should jump. So what happens when when the player is at X=1 and their Y position is 32? Unless the X and Y you're talking about aren't the player positions.

 
Craps, I'm an old man!

viva/volt

Awesome Sauce

Registered
  26/08/2006
Points
  1694

Game of the Week WinnerSilverNova MemberKlikCast StarVIP Member
19th April, 2008 at 19:44:44 -

I think he means x as some number you plug in and test with... I don't know what the original poster actually wants though - otherwise I'd try and help.

 
Image
http://bfollington.tumblr.com
   

Post Reply



 



Advertisement

Worth A Click