Jump from walls / edges

NED

Well-known member
Basically, I'm trying to understand how to do triangle jump (Chun Li wall jump move) But with an automatic move done like triangle jump kick...

I would like it to be possible on screen edge, walls and vertical surface of obstacles and platforms.

I've seen in the BK chinese mod I won't name here...

Is there a way to use this feature?
Thanks
 
Ultimate revival:
I come back to this thread because there is no reason to recreate a new one.

Ok I'm still using Bloodbane's wall jump script version.
It detect edges and walls an do different jump velocities depending on the type of jump you do :
neutral, forward jump, run jump. I'm glad with this version.
The fact it send you to jump anim too is good, so you can cancel it with all jumping attacks availiable.

Code:
void main()
{
    int iPlIndex = getlocalvar("player"); //Get calling player
    void vSelf = getplayerproperty(iPlIndex , "entity"); //Get calling entity
    void vAniID = getentityproperty(vSelf,"animationID"); //Get current animation ID
    void vAniPos = getentityproperty(vSelf, "animpos"); //Get current animation frame
    int iDir = getentityproperty(vSelf, "direction");  //Get current facing direction
    int x = getentityproperty(vSelf, "x");
    int y = getentityproperty(vSelf, "a");
    int z = getentityproperty(vSelf, "z");
    int XPos = openborvariant("xpos"); //Get screen edge's position
    int Screen = openborvariant("hResolution"); // Get screen width
   
    void iUp = playerkeys(iPlIndex, 1, "moveup"); // New key status of "Up"
    void iDown = playerkeys(iPlIndex, 1, "movedown"); // New key status of "Down"
    void iLeft = playerkeys(iPlIndex, 1, "moveleft"); // New key status of "Left"
    void iRight = playerkeys(iPlIndex, 1, "moveright"); // New key status of "Right"
    void iJump = playerkeys(iPlIndex, 1, "jump"); //New key status of "Jump"
    void iSpecial = playerkeys(iPlIndex, 1, "Special"); //New key status of "Special"
    void iAttack = playerkeys(iPlIndex, 1, "attack"); //New key status of "Attack"
    void iAttack2 = playerkeys(iPlIndex, 1, "attack2"); // New key of "Attack 2"
    void iAttack3 = playerkeys(iPlIndex, 1, "attack3"); // New key of "Attack 3"

    if(vAniID == openborconstant("ANI_JUMP")){
      if(iJump){
        if(iDir == 1 && y <= checkwall(x+15,z)){
          changeentityproperty(vSelf, "direction", 0);
          tossentity(vSelf, 3.4, -1.5, 0); // Wall Bounce
        } else if(iDir == 0 && y <= checkwall(x-15,z)){
          changeentityproperty(vSelf, "direction", 1);
          tossentity(vSelf, 3.4, 1.5, 0); // Wall Bounce
        } else if(iDir == 0 && x <= XPos+10){
          changeentityproperty(vSelf, "direction", 1);
          tossentity(vSelf, 3.4, 1.5, 0); // Edge Bounce
        } else if(iDir == 1 && x >= XPos+Screen-10){
          changeentityproperty(vSelf, "direction", 0);
          tossentity(vSelf, 3.4, -1.5, 0); // Edge Bounce
        }
      }
    }

    if(vAniID == openborconstant("ANI_FORWARDJUMP")){
      if(iJump){
        if(iDir == 1 && y <= checkwall(x+15,z)){
          changeentityproperty(vSelf, "direction", 0);
          tossentity(vSelf, 3.4, -1.9, 0); // Wall Bounce
        } else if(iDir == 0 && y <= checkwall(x-15,z)){
          changeentityproperty(vSelf, "direction", 1);
          tossentity(vSelf, 3.4, 1.9, 0); // Wall Bounce
        } else if(iDir == 0 && x <= XPos+10){
          changeentityproperty(vSelf, "direction", 1);
          tossentity(vSelf, 3.4, 1.9, 0); // Edge Bounce
        } else if(iDir == 1 && x >= XPos+Screen-10){
          changeentityproperty(vSelf, "direction", 0);
          tossentity(vSelf, 3.4, -1.9, 0); // Edge Bounce
        }
      }
    }

    if(vAniID == openborconstant("ANI_RUNJUMP")){
      if(iJump){
        if(iDir == 1 && y <= checkwall(x+15,z)){
          changeentityproperty(vSelf, "direction", 0);
          tossentity(vSelf, 3.2, -2.5, 0); // Wall Bounce
        } else if(iDir == 0 && y <= checkwall(x-15,z)){
          changeentityproperty(vSelf, "direction", 1);
          tossentity(vSelf, 3.2, 2.5, 0); // Wall Bounce
        } else if(iDir == 0 && x <= XPos+10){
          changeentityproperty(vSelf, "direction", 1);
          tossentity(vSelf, 3.2, 2.5, 0); // Edge Bounce
        } else if(iDir == 1 && x >= XPos+Screen-10){
          changeentityproperty(vSelf, "direction", 0);
          tossentity(vSelf, 3.2, -2.5, 0); // Edge Bounce
        }
      }
    }
}

Anyway, I would like to have something happeneing as a transition between initial jump and wall jump.
-Some crouch type pose, with a stepping sound effect. (please, ignore the kicking pose)
i64qcvY.png

How can I add it between jump and wall jump anims?

Thanks a lot.

EDIT----------------------------------------------
After checking the script.
I tried to edit it to allow an anim change with it.
I did some change but it makes openbor chash. (still a noob with code syntax even if I understand a bit of its logic)

The simple way would be (for each type of jump : neutral, forward, run versions)
Jump to wall or edge
script detect wall
change anim to "crouching type" pose with sound effect.
In this anim just use a change anim script to reach true jump animation
 
To add special animation before wall jump, you need to change the script into this:

...
    if(vAniID == openborconstant("ANI_JUMP")){
      if(iJump && iDir == 1 && y <= checkwall(x+15,z)){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW10")); // Wall Bounce
      } else if(iJump && iDir == 0 && y <= checkwall(x-15,z)){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW10")); // Wall Bounce
      }
    }

You need to copy and paste this function for that to work:
Code:
void floater( int Time )
{// Floats in Time centiseconds
    void self = getlocalvar("self");
    int eTime = openborvariant("elapsed_time");

    changeentityproperty(self, "tosstime", eTime + Time*2);
}

Paste it in the script outside main()

Anyways, the changed script will disable control temporarily, set entity afloat for 40 centiseconds and change the animation to wall cling animation

anim follow10 # Wall bounce
@script
    if(frame==1){
      void self = getlocalvar("self");
      changeentityproperty(self, "noaicontrol",0);
    }
@end_script
delay 40
jumpframe 1 3.5 1 0
offset 68 131
# bbox 55 74 28 33
frame data/chars/billy/wall.png
delay 30
bbox 61 76 18 38
frame data/chars/billy/jump1.png
frame data/chars/billy/jump2.png

That animation has script which will reenable control again
 
Thanks a lot BB!
Also the code seems even more polished.
Can you include Edge jump too just like in the initial script?

I already have floater function.
I would like to use follow50 for the wall cling anim

If I understand well:
The script now detects walls just the same way
It plays wall cling anim (velocity is 0)
Control is disabled
In Follow anim it restore player control on specified frame, right?

It would be perfect to me if the cling anim send player to player true jump anim of openbor. (just when cling anim is finished)
Also, this way, will it take control automatically when entering in jump anim.
Or it still have to be activated (on last animation frame or something)?

Thanks again.
 
I edited the script to allow edge detect too.
Sorry for double posting, but is the script syntax correct?

Code:
    if(vAniID == openborconstant("ANI_JUMP")){

      if(iJump && iDir == 1 && y <= checkwall(x+15,z)){if press jump ET direction is (same or opposite??) ET être plus bas que le wall et à moins de 15 pixel en X
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Wall Bounce

      } else if(iJump && iDir == 0 && y <= checkwall(x-15,z)){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Wall Bounce
      }

        else if(iJump && iDir == 0 && x <= XPos+10){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce
      }

        else if(iJump && iDir == 0 && x >= XPos+Screen-10){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce
      }


    }
 
Well, you can try the script yourself to see if it's working or not :)

In Follow anim it restore player control on specified frame, right?

Yep

It would be perfect to me if the cling anim send player to player true jump anim of openbor. (just when cling anim is finished)

IIRC the jumping state is still active IOW after you finished clinging on wall and jumps, you can access all jump attacks
That's also the reason I disabled control during wall cling animation i.e to prevent player from cancelling that animation

will it take control automatically when entering in jump anim.
Or it still have to be activated (on last animation frame or something)?

It still has to be activated again like with this script
 
Thanks.
So I just tried the script.
Openbor don't loads. Immediate crash.

Logfile:
Code:
Script compile error: can't find function 'floater'

Script compile error in 'entitykeyscript': floater line 29, column 8

The actual script I used :
Code:
void main()
{
    int iPlIndex = getlocalvar("player"); //Get calling player
    void vSelf = getplayerproperty(iPlIndex , "entity"); //Get calling entity
    void vAniID = getentityproperty(vSelf,"animationID"); //Get current animation ID
    void vAniPos = getentityproperty(vSelf, "animpos"); //Get current animation frame
    int iDir = getentityproperty(vSelf, "direction");  //Get current facing direction
    int x = getentityproperty(vSelf, "x");
    int y = getentityproperty(vSelf, "a");
    int z = getentityproperty(vSelf, "z");
    int XPos = openborvariant("xpos"); //Get screen edge's position
    int Screen = openborvariant("hResolution"); // Get screen width
   
    void iUp = playerkeys(iPlIndex, 1, "moveup"); // New key status of "Up"
    void iDown = playerkeys(iPlIndex, 1, "movedown"); // New key status of "Down"
    void iLeft = playerkeys(iPlIndex, 1, "moveleft"); // New key status of "Left"
    void iRight = playerkeys(iPlIndex, 1, "moveright"); // New key status of "Right"
    void iJump = playerkeys(iPlIndex, 1, "jump"); //New key status of "Jump"
    void iSpecial = playerkeys(iPlIndex, 1, "Special"); //New key status of "Special"
    void iAttack = playerkeys(iPlIndex, 1, "attack"); //New key status of "Attack"
    void iAttack2 = playerkeys(iPlIndex, 1, "attack2"); // New key of "Attack 2"
    void iAttack3 = playerkeys(iPlIndex, 1, "attack3"); // New key of "Attack 3"

    if(vAniID == openborconstant("ANI_JUMP")){

      if(iJump && iDir == 1 && y <= checkwall(x+15,z)){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Wall Bounce

      } else if(iJump && iDir == 0 && y <= checkwall(x-15,z)){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Wall Bounce
      }

        else if(iJump && iDir == 0 && x <= XPos+10){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce
      }

        else if(iJump && iDir == 0 && x >= XPos+Screen-10){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce
      }
    }

}

floater is delared in player header. (in slam.c)
Code:
animationscript data/scripts/slam.c

the actual floater script
Code:
void floater( int Time )
{// Floats in Time centiseconds
    void self = getlocalvar("self");
    int eTime = openborvariant("elapsed_time");

    changeentityproperty(self, "tosstime", eTime + 2*Time);
}

How I used floater in follow50 anim (wall cling in character txt file)
Code:
anim   follow50# Wall and edge jump (cling to wall) appui au mur
@script
    if(frame==1){
      void self = getlocalvar("self");
      changeentityproperty(self, "noaicontrol",0);
    }
@end_script
	delay   40
	jumpframe 1 3.5 1 0
	offset	96 177
	bbox   0 0 0 0
	frame	data/chars/rachel/j01.gif

	delay   30
	bbox	76 65 40 78
	frame	data/chars/rachel/j02.gif
	frame	data/chars/rachel/j02.gif

I can't understand where is my error. :-[
 
You need to paste floater function below main function in same .c file like this:

main()
{
...
}

void floater( int Time )
{// Floats in Time centiseconds
    void self = getlocalvar("self");
    int eTime = openborvariant("elapsed_time");

    changeentityproperty(self, "tosstime", eTime + 2*Time);
}
 
Ok I tried this way :
Code:
void main()
{
    int iPlIndex = getlocalvar("player"); //Get calling player
    void vSelf = getplayerproperty(iPlIndex , "entity"); //Get calling entity
    void vAniID = getentityproperty(vSelf,"animationID"); //Get current animation ID
    void vAniPos = getentityproperty(vSelf, "animpos"); //Get current animation frame
    int iDir = getentityproperty(vSelf, "direction");  //Get current facing direction
    int x = getentityproperty(vSelf, "x");
    int y = getentityproperty(vSelf, "a");
    int z = getentityproperty(vSelf, "z");
    int XPos = openborvariant("xpos"); //Get screen edge's position
    int Screen = openborvariant("hResolution"); // Get screen width
   
    void iUp = playerkeys(iPlIndex, 1, "moveup"); // New key status of "Up"
    void iDown = playerkeys(iPlIndex, 1, "movedown"); // New key status of "Down"
    void iLeft = playerkeys(iPlIndex, 1, "moveleft"); // New key status of "Left"
    void iRight = playerkeys(iPlIndex, 1, "moveright"); // New key status of "Right"
    void iJump = playerkeys(iPlIndex, 1, "jump"); //New key status of "Jump"
    void iSpecial = playerkeys(iPlIndex, 1, "Special"); //New key status of "Special"
    void iAttack = playerkeys(iPlIndex, 1, "attack"); //New key status of "Attack"
    void iAttack2 = playerkeys(iPlIndex, 1, "attack2"); // New key of "Attack 2"
    void iAttack3 = playerkeys(iPlIndex, 1, "attack3"); // New key of "Attack 3"

    if(vAniID == openborconstant("ANI_JUMP")){

      if(iJump && iDir == 1 && y <= checkwall(x+15,z)){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Wall Bounce

      } else if(iJump && iDir == 0 && y <= checkwall(x-15,z)){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Wall Bounce
      }

        else if(iJump && iDir == 0 && x <= XPos+10){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce
      }

        else if(iJump && iDir == 0 && x >= XPos+Screen-10){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce
      }
    }

}

}

void floater( int Time )
{// Floats in Time centiseconds
    void self = getlocalvar("self");
    int eTime = openborvariant("elapsed_time");

    changeentityproperty(self, "tosstime", eTime + 2*Time);
}

Logfile:
Code:
Script error: data/scripts/edgejumr.c, line 60: Invalid external declaration '}' (in production 1)

}
^

And I tried this way :
Code:
void main()
{
    int iPlIndex = getlocalvar("player"); //Get calling player
    void vSelf = getplayerproperty(iPlIndex , "entity"); //Get calling entity
    void vAniID = getentityproperty(vSelf,"animationID"); //Get current animation ID
    void vAniPos = getentityproperty(vSelf, "animpos"); //Get current animation frame
    int iDir = getentityproperty(vSelf, "direction");  //Get current facing direction
    int x = getentityproperty(vSelf, "x");
    int y = getentityproperty(vSelf, "a");
    int z = getentityproperty(vSelf, "z");
    int XPos = openborvariant("xpos"); //Get screen edge's position
    int Screen = openborvariant("hResolution"); // Get screen width
   
    void iUp = playerkeys(iPlIndex, 1, "moveup"); // New key status of "Up"
    void iDown = playerkeys(iPlIndex, 1, "movedown"); // New key status of "Down"
    void iLeft = playerkeys(iPlIndex, 1, "moveleft"); // New key status of "Left"
    void iRight = playerkeys(iPlIndex, 1, "moveright"); // New key status of "Right"
    void iJump = playerkeys(iPlIndex, 1, "jump"); //New key status of "Jump"
    void iSpecial = playerkeys(iPlIndex, 1, "Special"); //New key status of "Special"
    void iAttack = playerkeys(iPlIndex, 1, "attack"); //New key status of "Attack"
    void iAttack2 = playerkeys(iPlIndex, 1, "attack2"); // New key of "Attack 2"
    void iAttack3 = playerkeys(iPlIndex, 1, "attack3"); // New key of "Attack 3"

    if(vAniID == openborconstant("ANI_JUMP")){

      if(iJump && iDir == 1 && y <= checkwall(x+15,z)){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Wall Bounce

      } else if(iJump && iDir == 0 && y <= checkwall(x-15,z)){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Wall Bounce
      }

        else if(iJump && iDir == 0 && x <= XPos+10){
        changeentityproperty(vSelf, "direction", 1);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce
      }

        else if(iJump && iDir == 0 && x >= XPos+Screen-10){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce
      }
    }



}

void floater( int Time )
{// Floats in Time centiseconds
    void self = getlocalvar("self");
    int eTime = openborvariant("elapsed_time");

    changeentityproperty(self, "tosstime", eTime + 2*Time);
}



}

Logfile says :
Code:
Script error: data/scripts/edgejumr.c, line 72: Invalid external declaration '}' (in production 1)

}
^
 
You have to remove the "}" outside main() function

}

}// remove this!

void floater( int Time )
{// Floats in Time centiseconds
    void self = getlocalvar("self");
    int eTime = openborvariant("elapsed_time");

    changeentityproperty(self, "tosstime", eTime + 2*Time);
}
 
Thanks BB,
The move is now working (somewhat)...
But I can do it only in left edge, when I try it on right edge the move don't appears. ???

Also, ater wall jump, I cannot control player until the land on ground.
What's wrong about it?
EDIT :
Actually it wont come back to real jump state after wall stepping.
Code:
anim   follow50# Wall and edge jump (cling to wall) appui au mur
@script
    if(frame==1){
      void self = getlocalvar("self");
      changeentityproperty(self, "noaicontrol",0);
    }
@end_script
	delay   20#40
	jumpframe 1 3.5 1 0
	offset	96 177
	bbox   0 0 0 0
	frame	data/chars/rachel/j01.gif

	delay   30
	bbox	76 65 40 78
	frame	data/chars/rachel/j02.gif
	frame	data/chars/rachel/j02.gif
 
Hi,
I'm stucked in wall jump code structure.
Perhaps you can help me fixing this.
The idea is to have a cling on the wall then come back to regular jump anim (not a custom one)

http://www.chronocrash.com/forum/index.php?topic=1528.msg37215#msg37215

Thanks a lot


i cant read all the script here...  :o  ;D

ive made a new one if you put 2 walls one on the left another one on right
i think he makes that split jump from the shinnobi game...
i tested the script and it worked on a wall he jumps back if you press jump again
it works like guy in final fight
anim forwardjump
@script
void self = getlocalvar("self");
int SDir = getentityproperty(self, "direction");

if you want him to make perform other animation just change this line
performattack(self,openborconstant("ANI_FORWARDJUMP"));
this line is the jump velocity in altitude
tossentity(self, 2, jp, 0);


Code:
anim	forwardjump
@script
	void self = getlocalvar("self");
	int SDir = getentityproperty(self, "direction");
	void plyr = getentityproperty(self, "playerindex");
	int Dist = 10;  //----distance from wall
	int jp = -2;	//----jump x velocity

	       if(SDir==0)
	       {
	       Dist = -Dist;
	       jp = -jp;
	       }

	if(frame > 3 )
	{
	int x = getentityproperty(self, "x");
	int z = getentityproperty(self, "z");
	float H;
	H = checkwall(x+Dist,z);

		if( H > 0 && SDir == 0 && playerkeys(plyr, 0, "jump"))
		{
		performattack(self,openborconstant("ANI_FORWARDJUMP"));
		changeentityproperty(self, "direction", 1);
		tossentity(self, 2, jp, 0);
		}
		if( H > 0 && SDir == 1 && playerkeys(plyr, 0, "jump"))
		{
		performattack(self,openborconstant("ANI_FORWARDJUMP"));
		changeentityproperty(self, "direction", 0);
		tossentity(self, 2, jp, 0);
		}
	}
@end_script
	loop	0
	delay	5
	offset	145 204
	bbox	123 100 39 97
	frame	data/chars/1ryo/jup01.gif
	bbox	125 112 44 44
	frame	data/chars/1ryo/jup02.gif
	frame	data/chars/1ryo/jup10.gif
	frame	data/chars/1ryo/jup11.gif #3
	frame	data/chars/1ryo/jup12.gif
	frame	data/chars/1ryo/jup13.gif
	frame	data/chars/1ryo/jup14.gif
	frame	data/chars/1ryo/jup15.gif
	bbox	123 100 39 70
	delay	9
	frame	data/chars/1ryo/jup07.gif
 
Thanks Jonsilva for giving an alternative.
I will give it a try and see if it will make it for my project.
And yes the ide is to have final fight wall jump.
Jumping - cling to wall - jumping in the other side

BTW : I asked help to other friends too in PM, since I'm very stucked in something very basic, but I cannot figure why it's not working.

Anyway I'll try your version. ^^
 
I tried you version Jonsilva, but for some reason, it can't work.
Also, I'm using an older build of openbor and sometimes it didn't accept script in player file. and this jump have to work with walls and edge.

Basically Bloodbane's version is really what I need, but for some reason I cannot make player going back to REAL "constant" jump state. (+Taking control)
Instead it plays these 2 frames


anim  follow50# Wall and edge jump (cling to wall) appui au mur
@script
    if(frame==1){
      void self = getlocalvar("self");
      changeentityproperty(self, "noaicontrol",0);
    }
@end_script
delay  16#40####duree du step (voir script)
jumpframe 1 3.5 1 0
offset 96 177
bbox  0 0 0 0
frame data/chars/rachel/j01.gif

delay  5#30
bbox 76 65 40 78
frame data/chars/rachel/j02.gif
frame data/chars/rachel/j02.gif


Edit : I'll try again to fix it today, since I have a little time.
Otherwise I'll delete the full function. It's not a ninja game after all...
 
I still need to check what's wrong with the state change but I just noticed this small error:
        else if(iJump && iDir == 0 && x >= XPos+Screen-10){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce

It should be:

        else if(iJump && iDir == 1 && x >= XPos+Screen-10){
        changeentityproperty(vSelf, "direction", 0);
        changeentityproperty(vSelf, "velocity", 0, 0, 0);
        floater(40);
        changeentityproperty(vSelf, "noaicontrol",1);
        changeentityproperty(vSelf, "animation", openborconstant("ANI_FOLLOW50")); // Edge Bounce

On other subject, the reason why I use changeentityproperty instead of performattack, is because the former retains jumping state while the latter removes that state

I'm going to try this wall cling animation myself

[couple minutes later]

I've tried it and the wall cling animation works well
 
Thanks a lot.
Silly me I didn't watched well the script.


Now, I'm trying to obtain the actual "ANI_JUMP" from this cling anim.

This one is your script in the cling anim.
@script
    if(frame==1){
      void self = getlocalvar("self");
      changeentityproperty(self, "noaicontrol",0);
    }
@end_script

I tried to edit it to allow a cancel to "ANI_JUMP" anim
@script
    if(frame==1){
      void self = getlocalvar("self");
        changeentityproperty(self, "animation", openborconstant("ANI_JUMP"));
      changeentityproperty(self, "noaicontrol",0);
    }
@end_script

It's almost OK, but player is falling directly. (no velocity)
How can I add the right velocity to recreate jump?

I tried adding this:
          tossentity(vSelf, 3.4, -1.5, 0); // Wall Bounce

But Openbor crashes.
Seems like vself have not been declared before or something??

Or perhaps I'm completly wrong ???
 
Piccolo said:
Yes, so just use self instead of vSelf. That's how this variable is named in your script.

True, totally true!
the cancel and velocity is ok now.
Character actually go in jump_anim :)
Thanks

But for some reason when I do a jump attack during this jump velocity stops and fall down.
previous "tossentity" value seems to be ignored as soon as player quits jump_anim
 
I don't know what to say ned, I've tried the code here and it works fine. I can even perform spinning kick in mid air after wall jump (I tested it on Double Dragon Mini mod)
 
Back
Top Bottom