Jump to content
Sign in to follow this  
wongkeanwah

How on earth do i....

Recommended Posts

Hello,

It has been a long break from OFP and im back, so i wanna ask something.

How do you use a script to add a weapon to someone(eg Civilian) and change sides?(eg Civilian to West).

Help is appreciated! thanks! xmas_o.gif

Share this post


Link to post
Share on other sites
Guest

changeSides

If you do a simple search of change sides, youlll find more similiar posts.

The weapon thing I havent yet delved into in scripting, but a few searches may bring up your answers

Share this post


Link to post
Share on other sites
Guest

Basically the posts in that thread show 2 ways, one thru the editor of setting units to groups of other sides and other of changing actual unit configs in script, just easier to show ya the link here than re-typing it. Sorry if the link is not super clear, a few misleading posts in there, but basically you either make a unit and group him to another unit of opposite side that does NOT have a lower rank set, or go thru the mission file and change properties (shown in link) to make particular unit whatever side.

Hope I have been a help

gl

Share this post


Link to post
Share on other sites

Hey, of course you have been a help. biggrin_o.gif

Now, the weapons.. i know how to add a weapon, but the mags dont show up.

Share this post


Link to post
Share on other sites

You need to add mags before the weapon.

unit addmagazine "m16"; unit addweapon "m16"

in that order.

The easiest way to have a west soldier east for example, is to group the west soldier to a east soldier with higher rank and put deletevehicle this in the east soldiers init field. That way the west soldier is now east and by himself when the game starts. Same principle for civilians ect. Play around. smile_o.gif

Share this post


Link to post
Share on other sites
I thought the unit was meant to be this?

Yes, but This only works in the INIT line of the unit, if you use it in a script then you should name the unit and use his unitname instead of This wink_o.gif

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×