@Bind script help

PS_VITA

Active member
Hi guys-

for some reason and randomly whenever player one performs a floor grab move
sometimes the enemy from across the screen is replaced (teleported) by the nearest enemy that I'm trying to floor grab.

Any hints or things on the code that look off are really appreciated


Here's the ani0020_actual.h bind code in the script

Code:
void bind(int null, float x, float z, float y, int dir){
	void self = getlocalvar("self");
	void opp = getentityproperty(self, "opponent");
	if(null == 1)
	{
		bindentity(opp, self, x, z, y, dir, 0);
	}
	else if(null == 0)
	{
		bindentity(opp, NULL());
	}
}

and here's the players code:

Code:
                   # floor enemy attack





                   # floor enemy attack





anim follow15
      loop	1
	delay	9
      offset	85 170
      cancel 0 1 0 A freespecial12
      cancel 0 1 0 B freespecial16
      @cmd forceanim openborconstant("ANI_FOLLOW77")
      @cmd bind 8 0 0 1 0
      frame	data/chars/billy/ball/gr0.png
      @cmd forceanim openborconstant("ANI_FOLLOW77")
      @cmd bind 8 0 0 1 0
      frame	data/chars/billy/ball/gr0.png
 
setlocalvar("Target" + self, target); = setentityvar(self, "target", target);

void target = getlocalvar("Target" + self); =  void target = getentityvar(self, "target");

You can test and see if this helps you.
 
So I got it working  :D finally! but the bad part is , that I don't know exactly what made the previous script not work as intended.

What I did was duplicate a wapons model character that had the same animation working,  so I went line by line duplicating it and when I ran the test everything ran smoothly.

Magggas had already successfully created that model in double dragon reloaded (the game I'm learning from) so I simply duped the and applied it to a new wepons model.

If I had to guess what I had been doing wrong is that I had no clue that wepon models inherently use the same freespecials as the base model.

I noticed right away when my character froze and would not respond when I press bot kick and punch , which is inturn a freespecial from the base model.


TLDR: freespecial from base model to wepons model
Coud have been the culprit simce I omitted them on the new wepon model I created.

Thank you all for touble shooting this with me.
 
Back
Top Bottom