I have a SP, JK actor with a weapon that I want to act as a scattergun(shotgunish).
I have tweaked this basic code countless times but no success [the fire message]: (the following is its actor cog.)
But it still shoots the only one weapon tpl I have designated it in the master.tpl
Any ideas? I tried looking at such cogs from SS3 but those are too complex with weapon modes, etc.
------------------
nil nip nada zip zero naught lip zil
I have tweaked this basic code countless times but no success [the fire message]: (the following is its actor cog.)
Code:
# Jedi Knight Cog Script # # ENEMY2.COG # # ACTOR Script - Enemy with scattergun # # Is modified from actor_s3.cog # # [F_Body] # # This Cog is Not supported by LucasArts Entertainment Co. symbols message damaged message skill message fire thing guy local template projectile=+ebolt local ai flee_ai=noweapon.ai local int bin local int senderref=-1 local int dummy local int damage local end # ======================================================================================== code fire: guy = GetSourceRef(); if(GetThingHealth(guy) <= 0) { Return; } dummy = FireProjectile(guy, projectile, -1, -1, '0.0098 0.057 0.01', '0 0 0', 1.0, 0x60, autoAimZFOV, autoAimXFOV); dummy = FireProjectile(guy, projectile, -1, -1, '0.0098 0.057 0.01', '0 0 0', 1.0, 0x60, autoAimZFOV, autoAimXFOV); dummy = FireProjectile(guy, projectile, -1, -1, '0.0098 0.057 0.01', '0 0 0', 1.0, 0x60, autoAimZFOV, autoAimXFOV); dummy = FireProjectile(guy, projectile, -1, -1, '0.0098 0.057 0.01', '0 0 0', 1.0, 0x60, autoAimZFOV, autoAimXFOV); dummy = FireProjectile(guy, projectile, -1, -1, '0.0098 0.057 0.01', '0 0 0', 1.0, 0x60, autoAimZFOV, autoAimXFOV); return; # ........................................................................................ damaged: damage = GetParam(0); ReturnEx(damage); return; # ........................................................................................ skill: bin = GetParam(0); if (bin == 24) // Force Pull { senderref = GetSenderRef(); AISetClass(senderref, flee_ai); AIFlee(senderref, GetLocalPlayerThing()); Return; } else if (bin == 31) // Force Grip { ReturnEx(10); // return base damage that is taken by this actor. Return; } else if (bin == 34) // Deadly Sight { ReturnEx(5); // return base damage that is taken by this actor. Return; } ReturnEx(-1); return; # ........................................................................................ end
But it still shoots the only one weapon tpl I have designated it in the master.tpl
Any ideas? I tried looking at such cogs from SS3 but those are too complex with weapon modes, etc.
------------------
nil nip nada zip zero naught lip zil
This is retarded, and I mean drooling at the mouth