Page 1 of 1

Using DONTHURTSHOOTER correctly

Posted: Sat Jun 10, 2006 3:01
by Bashe
I'm having a hard time using DONTHURTSHOOTER correctly. You see, I have a friendly monster that shoots out projectiles, and the gun he uses can be used by the player. The projectiles are simply inherited from existing ones, like so:

Code: Select all

John[projectile] : [existing projectile]
{
Speed 25
Damage 50
}
When I had the player shoot the same projectiles, I did this:

Code: Select all

PJGN B 0 A_FireCustomMissile ("John[whatever]")
I did one for the rocket, but I don't want the splash damage of it to hurt the player, so I put DONTHURTSHOOTER on the actor replacing the rocket, but it didn't work, so I tried putting it on the weapon, and it still didn't work. How am I supposed to make it so the splash damage doesn't affect the player?

Also, I don't the player fired ones to use ammo, how would I define that? I usually just type in the projectile name, would I have to type in all the other stuff to get to usenoammo?

Posted: Sat Jun 10, 2006 4:23
by Marty Kirra
I can't help with the first question, but for the projectile not using ammo...All you should need to do is not define an ammo type or not define the number of ammo used when firing weapon. Then again, I need to get in touch with decorate so I maybe wrong :P

Posted: Sat Jun 10, 2006 5:47
by Bashe
Well, I put weapon.ammouse to 1, but for every projectile fired (which is 4 at one time) it uses a shot for each one. I only want it to use ONE shot.

Posted: Sat Jun 10, 2006 16:52
by wildweasel
You need to change the arguments for A_FireCustomMissile.

Code: Select all

FROD B 0 A_FireCustomMissile("SmallFuelRodBall2",-2,0,10,-6)
FROD B 2 BRIGHT A_FireCustomMissile("SmallFuelRodBall",0,1,10,0)
In particular, it's the third (the first being the projectile's name, and the second being the spread offset, I think). Set that to 1 and that projectile will use ammo. Set the other projectiles so theirs are set to 0, and they won't use ammo.

Posted: Sat Jun 10, 2006 17:20
by Bashe
What are the default offsets? It seems I have to define every single argument in order to use one of them. I just want it to to come directly out of the center of the player.

Posted: Sat Jun 10, 2006 23:22
by wildweasel
The default offsets are 0,0. That's a straight angle, no height change, and no x-offset.

Posted: Sun Jun 11, 2006 3:54
by Bashe
All right, the ammo problem has been remedied, but how do I nullify the splash damage towards the player?

Posted: Sun Jun 11, 2006 6:50
by wildweasel
I can't remember if you're supposed to put DONTHURTSHOOTER on the weapon itself, the projectile, or both.

Posted: Sun Jun 11, 2006 11:37
by TheDarkArchon
It's on the projectile.

Posted: Sun Jun 11, 2006 14:48
by Bashe
I put it on the projectile, but it still hurts me, so I put it on the gun and it STILL hurts me...

Posted: Sun Jun 11, 2006 15:20
by TheDarkArchon
Another important thing: DONTHURTSHOOTER only affects splash damage and I think it only effects A_Explodes defined in the projectiles states (I.E I don't think it affects inherited states)

Oh yeah, Using properties to define splash damage is not offically supported anymore: It'll work but it's recommended you pass parameters into A_Explode.

Posted: Sun Jun 11, 2006 16:33
by Bashe
Well, guess I just have to play with god mode on when using that gun.