OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: THobson on 10 Mar 2005, 23:27:46

Title: Fire a kozlice
Post by: THobson on 10 Mar 2005, 23:27:46
Okay so I know how to give a guy some magazines and then the gun.  I also can get him to fire the gun:

unit fire "nameofweapon"

This works for every weapon I have tried but not for the Kozlice.  Could I be missing something or is this a 'feature'?
Title: Re:Fire a kozlice
Post by: Planck on 10 Mar 2005, 23:32:17
I think it has something to do with the fact the kozlice can have 2 types of ammo, ball and shell.

I've seen this problem before, but I can't remember the solution offhand.

EDIT:   I think you need to use the 'other' fire command:

unit fire [muzzle,mode,magazine]


Planck
Title: Re:Fire a kozlice
Post by: THobson on 11 Mar 2005, 08:42:37
Thanks.  I missed that.  I am sure it will work, will check tonight between beta testing.

Thanks :)
Title: Re:Fire a kozlice
Post by: THobson on 11 Mar 2005, 19:35:53
I have looked through the commented weapons config file and can find nothing that would help me know what muzzle and what mode to use.  I tried a few obvious guesses.  Does anyone know?  All I need is a single shot of kozlice ball.
Title: Re:Fire a kozlice
Post by: Planck on 11 Mar 2005, 20:45:00
The muzzles for the kozlice are:

KozliceBallMuzzle
KozliceShellMuzzle

The magazines are:

KozliceBall
KozliceShell

Mode would probably be Single.....I can't imagine it doing Burst.    ;D


Planck
Title: Re:Fire a kozlice
Post by: THobson on 11 Mar 2005, 21:49:47
You are a star.  Thanks.  I tried kozlicemuzzle and kozliceball, but not kozliceballmuzzle.  Where did you find this?
Title: Re:Fire a kozlice
Post by: Planck on 11 Mar 2005, 21:55:33
I found it in the config for the kozlice, which can be found inside the kozl.pbo which can in turn be found in your addons folder.


Planck
Title: Re:Fire a kozlice
Post by: THobson on 12 Mar 2005, 00:17:05
What can I say.  I am embarassed again :-[
Title: Re:Fire a kozlice
Post by: Planck on 12 Mar 2005, 00:29:51
 ::)   :P


Planck
Title: Re:Fire a kozlice
Post by: StonedSoldier on 20 Mar 2005, 01:25:58
a little trick i use to grab the exact syntax for the the fire command

play as the guy with the weapon you want, in the init field give him this EH

this addeventhandler ["Fired",{hint format ["this fire [%1,%2]",_this select 2,_this select 3]}]
Title: Re:Fire a kozlice
Post by: THobson on 20 Mar 2005, 08:44:26
Now that is some neat lateral thinking.