No spark on indirect damage by throw

NED

Well-known member
I have an unexplicated glitch that happens when my player one of her custom slams.
This one have the type "throw" (I'm NOT using old BOR throw anim)

Normally in other mods, when a player uses a throw, there is an indirect damage/hit to all enemies in the way.

This happens normally too with my slam, but there is no spark displayed. but it still hits.
How can I make this sparks displayed

As you can see here, the spark is displayed when the move hits an obstacle (on the left) but never when it hist another enemy (on the right)

BQTqrxL.jpg


I also happens when enemy does his slam.



This is certainly due to the fact this is not a "real" throw, but a custom one??


This is the slam itself. (I can post any other code if needed)


Code:
anim	grabbackward#body slam
	damageonlanding 0 1#l'enemi peut faire des indirect damage
      hitfx   data/sounds/indirect.wav
	hitflash      flash
	jugglecost	2#3
	attackone	0#1#0
	loop	0
	offset	96 177
	bbox	0 0 0 0

	delay	16#14###18#15
        @cmd    slamstart
        @cmd    position 39 30 0 -1 0
	frame	data/chars/rachel/bslam1.gif

	delay	10#6###8
        @cmd    position 6 -14 2 1 1
	frame	data/chars/rachel/bslam2.gif

	delay	6###8
        @cmd    position 7 -22 5 1 1#7 -22 0 1 1
	sound	data/chars/rachel/kiai3.wav#kiai5.wav
	frame	data/chars/rachel/bslam3.gif

	delay	5
        @cmd    position 8 -24 16 -1 1#position 8 -18 16 -1 1
	sound	data/sounds/jump.wav
	frame	data/chars/rachel/bslam4.gif


	delay	3
	@cmd   depost 0
        @cmd    throw 45 2 -3 2.5 0 1#45 2 -3 2.5 0 1#99 2 -2 4 0 1#99 6 -4 0 1 0
	frame	data/chars/rachel/bslam4.gif


	delay	16#18#10
#        @cmd    throw 1 4 -1.7 1.7 0 0
	frame	data/chars/rachel/bslam5.gif

	delay	8###8
	offset	96 177
	frame	data/chars/rachel/bslam6.gif

	delay	6###8
	offset	96 177
	frame	data/chars/rachel/bslam7.gif

Thanks
 
Also, 2nd problem in the same situation.
The thrown killed character never plays death voice in this situation

I double checked if FALL9 anim and DEATH9 anim of slams was OK (I mean with the death voice)
There is normally no problem in the code itself.

Code:
#-----------------THROW SLAM SYSTEM (scripted) -----------------#

anim fall9
	quakeframe	1 1 -11
	loop	0
	landframe	2 dus
	forcedirection	1
	delay	15
	offset	96 177
	bbox	60 50 63 102
	attack	60 50 63 102 25 1 0 1 15 0
	sound	data/chars/mex/mex_dam2.wav
	frame	data/chars/mex/fall9.gif
	bbox	42 93 115 61
	attack	42 93 115 61 25 1 0 1 15 0
	delay	300
	frame	data/chars/mex/fall9b.gif
	delay	40
	bbox	36 132 139 54
@cmd spawnDmg "bdrop" -55 6 3 0.1
	frame	data/chars/mex/fall4.gif

#-----------------THROW SLAM SYSTEM (scripted) -----------------#

#-----------------THROW SLAM SYSTEM (scripted) (basé sur fall9 + ou -)-----------------#

anim death9
nodieblink    3#reste
	subentity	finish
	spawnframe	0 240 270 0 1

	quakeframe	1 1 -11
	loop	0
	landframe	2 dus
	forcedirection	1
	delay	15
	offset	96 177
	bbox	60 50 63 102
	attack	60 50 63 102 25 1 0 1 15 0
	sound	data/chars/mex/mex_out.wav
	frame	data/chars/mex/fall9.gif
	bbox	42 93 115 61
	attack	42 93 115 61 25 1 0 1 15 0
	delay	300
	frame	data/chars/mex/fall9b.gif
	delay	60
	bbox	36 132 139 54
@cmd spawnDmg "bdrop" -55 6 3 0.1
	frame	data/chars/mex/fall4.gif

I don't know why the throw don't cat like other slam-type custom slams.

-no spark when hit another enemy
-no killed voice
 
you might need to check
the throw and finish script code

finish
    }

    if(Type==1)
    {
      damageentity(target, self, Damage, 1, openborconstant("ATK_NORMAL")); // 1st Finisher
    }

    if(Type==2)
    {
      damageentity(target, self, Damage, 1, openborconstant("ATK_NORMAL9")); // 2nd Finisher
    }


throw
    if(Type==1)
    {
      damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL")); // 1st throw type
    }

    if(Type==2)
    {
      damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL9")); // 2nd throw type
    }

    if(Type==3)
    {
      damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL2")); // 3rd throw type
    }

try to replace this lines in throw and make them equal to the finish...
the zero in "target, self, 0, 1, " could be preventing the fall9 /death9 anim

the best way to use the throw / finish would be 1- fall1 2- fall2 3-fall3 etc...
i might change the script code sometime later on... so it will work this way... but right now its complicated my game is in a world of mess
 
Strange,
I had already this kind of settings with "finish" and "throw" same numbers...

THis is the actual script
Finish:
Code:
void finish(int Damage, int Type, int x, int y, int z, int Face)
{ // Damage as slam or throw finisher
   void self = getlocalvar("self");
   void target = getlocalvar("Target" + self);
   int SDir = getentityproperty(target,"direction");
   int MDir;

   if(Face==0){ // Same facing?
       MDir = SDir;
   }

   if(Face==1){ // Opposite facing?

     if(SDir==0){ // Facing left?
       MDir = 1;
     } else { MDir = 0;}
   }

   if(target==NULL())
   {
     target = getentityproperty(self, "grabbing");
     setlocalvar("Target" + self, target);
   }
   if(target!=NULL())
   {
     int dir = getentityproperty(target,"direction"); //Get opponent's facing direction
     if(dir==0){ // Facing left?
       x = -x;
     }

     if(Type==1)
     {
       damageentity(target, self, Damage, 1, openborconstant("ATK_NORMAL")); // 1st Finisher
     }

     if(Type==2)
     {
       damageentity(target, self, Damage, 1, openborconstant("ATK_NORMAL9")); // 2nd Finisher
     }

     if(Type==3)
     {
       damageentity(target, self, Damage, 1, openborconstant("ATK_NORMAL2")); // 3rd Finisher
     }

     if(Type==4)
     {
       damageentity(target, self, Damage, 1, openborconstant("ATK_NORMAL")); // 4th Finisher
      changeentityproperty(target, "animation", openborconstant("ANI_FALL15"));
     }

     tossentity(target, y, x, z); // Toss opponent ;)
     changeentityproperty(target, "direction", MDir);
   }
}

Throw:
Code:
void throw(int Damage, int Type, int x, int y, int z, int Face)
{ // Damage as throw finisher
   void self = getlocalvar("self");
   void target = getlocalvar("Target" + self);
   int SDir = getentityproperty(target,"direction");
   int MDir;

   if(Face==0){ // Same facing?
       MDir = SDir;
   }

   if(Face==1){ // Opposite facing?

     if(SDir==0){ // Facing left?
       MDir = 1;
     } else { MDir = 0;}
   }

   if(target==NULL())
   {
     target = getentityproperty(self, "grabbing");
     setlocalvar("Target" + self, target);
   }
   if(target!=NULL())
   {
     int dir = getentityproperty(target,"direction"); //Get opponent's facing direction
     if(dir==0){ // Facing left?
       x = -x;
     }

     if(Type==1)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL")); // 1st throw type
     }

     if(Type==2)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL9")); // 2nd throw type
     }

     if(Type==3)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL2")); // 3rd throw type
     }

     if(Type==4)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL")); // 4th Finisher
      changeentityproperty(target, "animation", openborconstant("ANI_FALL15"));
     }

     changeentityproperty(target, "attacking", 1);
     changeentityproperty(target, "damage_on_landing", Damage);
     changeentityproperty(target, "projectile", 1);
     changeentityproperty(target, "direction", MDir);
     tossentity(target, y, x, z); // Toss opponent ;)
   }
}

But by changing the finish type in the throw anim (in my character)
It made a little change.

@cmd    throw 45 2 -3 2.5 0 1
Changed to
@cmd    throw 45 1 -3 2.5 0 1

Make the move success to display sparks on indirect hit!
But still no killed voice. :-\
Also the anim type "1" make the enemy looks weird with this particular throw.
 
Also the anim type "1" make the enemy looks weird with this particular throw.

it could be because this lines use the same attack but play diferent fall anims

damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL"));

    damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL")); // 4th Finisher
      changeentityproperty(target, "animation", openborconstant("ANI_FALL15"));

maybe changing the 2 one to  ("ATK_NORMAL15")); to play fall15 if you havent tried yet...

ive try to changed the slam script but could find a way there doesnt seem to be a way to add a number to "ATK_NORMAL".... like x = "ATK_NORMAL" + nr
it also doesnt seem right to use openborconstant(Ani)) you would have to write the anim name in the @cmd like
@cmd    throw 45 "ANI_FALL15" -3 2.5 0 1
 
Still not working,
I think the only way to fix it would be to change heavily the slam script.
This way, it allow slams to be considered like actual grab moves.

particulary old BOR throw.
 
I tried to find explanation about this bug.
The bug is still in WHPSJ by Magggas, the bug is not in Crime Buster by Bloodbane.
Both mods are using slam script

This is a move of Ryoko WHSJ (the bug is just like in my mod)
Code:
anim  grabbackward
      loop	0
	delay	10
      offset	70 170
      attackone 0
      flipframe 1
      hitfx   data/sounds/indirect.wav
      @cmd    slamstart 
      @cmd    position 5 15 -10 -1 0
      frame	data/chars/ryoko/th1.gif
      sound	data/chars/ryoko/at1.wav
      delay	15
      @cmd    position 0 -33 0 -1 1
      frame	data/chars/ryoko/th2.gif
      delay	7
      @cmd    position 1 -8 27 -1 1
      frame	data/chars/ryoko/th3.gif
      @cmd    hurt 25
      @cmd    position 17 50 17 -1 1
      frame	data/chars/ryoko/th4.gif
      @cmd    depost 0
      @cmd    throw 5 1 4 2 0 0
      delay	8
      frame	data/chars/ryoko/th4.gif
      frame	data/chars/ryoko/th4.gif
      frame	data/chars/ryoko/th5.gif

This is a move of Kula CB (the bug is not here, it success on displaying sparks on indirect hit)
Code:
anim grabbackward
	delay	1
	offset	76 148
        @cmd    anti
	frame	data/chars/kula/lthrow01.gif
	delay	15
        @cmd    slamstart
        @cmd    position 7 30 0 -1 -1
	frame	data/chars/kula/lthrow01.gif
	delay	10
	sound	data/chars/kula/kulahey.wav
        frame	data/chars/kula/lthrow02.gif
	delay	5
	offset	76 133
        @cmd    position 5 36 143 -1 -1
        frame	data/chars/kula/lthrow03.gif
        @cmd    antiwall -16 16 -1
        @cmd    position 3 11 165 -1 -1
	frame	data/chars/kula/lthrow04.gif
        @cmd    antiwall -20 20 -1
        @cmd    position 2 -36 67 -1 -1
        frame	data/chars/kula/lthrow05.gif
	delay	3
        @cmd    depost 0
        @cmd    throw 24 3 4 0 0 0
        frame	data/chars/kula/lthrow06.gif
        frame	data/chars/kula/lthrow07.gif
	delay	6
        frame	data/chars/kula/lthrow08.gif
        offset	46 133
        frame	data/chars/kula/lthrow09.gif
        frame	data/chars/kula/lthrow10.gif
        frame	data/chars/kula/lthrow11.gif


I can't understand where is the difference.
Any idea?


-----------------
Edit

This is definitly a problem with Throw cmd.

By changing my line
        @cmd    throw 45 2 -3 2.5 0 1
to
        @cmd    throw 45 3 -3 2.5 0 1

it seems to work perfectly, BUT the falling animation is really not matching the action...
Is there a way to finally have this anim type "2" working and displaying sparks?
 
1 mystery solved!  8)
You were right about all, thanks a lot Magggas!!

I still have something weirdly not working with the same type of slam (throw).
This problem is not in your mod slams either in Bloodbane's CB mod.

It's about death anim

I can see you don't use it in your mod, but for me, it's a way to have custom death voice and visual effects.

BB's script seems to ignore death version of your falling animation in slams.

I used a custom effect (draw method) to be sure the anim is ignored
And yes, it is.

there are my fall and death by slams anims.

Code:
#-----------------THROW SLAM SYSTEM (scripted)
anim fall9
	quakeframe	1 1 -11
	loop	0
	landframe	2 dus
	forcedirection	1
	delay	15
	offset	96 177
drawmethod 256 256 0 0 0 1#plus clair debug#------------------HERE
	bbox	60 50 63 102
	attack	60 50 63 102 25 1 0 0 15 0
	sound	data/chars/mex/mex_dam2.wav
	frame	data/chars/mex/fall9.gif
	bbox	42 93 115 61
	attack	42 93 115 61 25 1 0 0 15 0
	delay	300
	frame	data/chars/mex/fall9b.gif
	delay	40
	bbox	36 132 139 54
@cmd spawnDmg "bdrop" -55 6 3 0.1#0.99#--name x y z niv de life--
	frame	data/chars/mex/fall4.gif

#-----------------THROW SLAM SYSTEM (scripted)
anim death9
nodieblink    3#reste
	subentity	finish
	spawnframe	0 240 270 0 1

	quakeframe	1 1 -11
	loop	0
	landframe	2 dus
	forcedirection	1
	delay	15
	offset	96 177
	bbox	60 50 63 102
	attack	60 50 63 102 25 1 0 1 15 0
	sound	data/chars/mex/mex_out.wav
	frame	data/chars/mex/fall9.gif
	bbox	42 93 115 61
	attack	42 93 115 61 25 1 0 1 15 0
	delay	300
	frame	data/chars/mex/fall9b.gif
	delay	60#160#40
	bbox	36 132 139 54
@cmd spawnDmg "bdrop" -55 6 3 0.1#0.99#--name x y z niv de life--
	frame	data/chars/mex/fall4.gif


Certainly something linked to this part of script (it's a custom version with more fall anims available)
Code:
void throw(int Damage, int Type, int x, int y, int z, int Face)
{ // Damage as throw finisher
   void self = getlocalvar("self");
   void target = getlocalvar("Target" + self);
   int SDir = getentityproperty(target,"direction");
   int MDir;

   if(Face==0){ // Same facing?
       MDir = SDir;
   }

   if(Face==1){ // Opposite facing?

     if(SDir==0){ // Facing left?
       MDir = 1;
     } else { MDir = 0;}
   }

   if(target==NULL())
   {
     target = getentityproperty(self, "grabbing");
     setlocalvar("Target" + self, target);
   }
   if(target!=NULL())
   {
     int dir = getentityproperty(target,"direction"); //Get opponent's facing direction
     if(dir==0){ // Facing left?
       x = -x;
     }

     if(Type==1)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL")); // 1st throw type
     }

     if(Type==2)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL9")); // 2nd throw type
     }

     if(Type==3)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL2")); // 3rd throw type
     }

     if(Type==4)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL")); // 4th Finisher
      changeentityproperty(target, "animation", openborconstant("ANI_FALL15"));
     }

     changeentityproperty(target, "attacking", 1);
     changeentityproperty(target, "damage_on_landing", Damage);
     changeentityproperty(target, "projectile", 1);
     changeentityproperty(target, "direction", MDir);
     tossentity(target, y, x, z); // Toss opponent ;)
   }
}
 
magggas said:
Thanks dude, yeah i´m working on something but for now there is not announcement because i´m not sure how far this project will going, because real life stuff makes me busy.
So, i´m really hope too that it will going soon far enough, to be able to announce and show something at least.  :D

but I am sure it will be a great game :)
 
magggas said:
Ok i´m back.
So, i have tested this in my new mod and it works fine.
My enemy is using these settings falldie 2, nodieblink 1.

Then my player is using this type on hes throw function:
if(Type==1)
    {
      damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL5")); // 1st throw type

Then when i´m setting this "anim death5" to the enemy with the sound i want, it works fine.

Are you sure you are doing all this above on this way?

OK,
I checked it, I'm using type 2 fall anim for this move
Code:
     if(Type==2)
     {
       damageentity(target, self, 0, 1, openborconstant("ATK_NORMAL9")); // 2nd throw type

        @cmd    throw 45 2 -3 2.5 0 1

I tried to use your falldie settings (falldie 2), but the result is a little weird to me.
I prefer the death effect to happen righ when the life is drained, not when enemy finally hit the ground.

It might be the problem...  :-\
 
Back
Top Bottom