Results 1 to 3 of 3

Thread: setUnitpos "UP" for Civilians

  1. #1
    I initalize a default unarmed civilian with these lines:
    <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">
    _Civilian addweapon _Weapon
    {_Civilian addmagazine _x} foreach _Magazines
    group _Civilian setbehaviour &#34;aware&#34;
    _Civilian selectweapon _Weapon
    _Civilian setunitpos &#34;UP&#34;
    [/QUOTE]

    I thought, he would always stand now, with his weapon ready to fire.
    (Soldiers and Policemen that already have weapons do it)

    But a civilian just walks around with his rifle/pistol on back and doesn&#39;t even use it if he or his group is attacked.
    Just like "careless+holdfire".
    Without setUnitpos "UP" the civilian has his weapon ready and fights, but he also lies down when under attacked.

    Is there a way around it?




  2. #2
    Try removing the setbehaviour "Aware" bit
    James Andrew Wilkinson 1977 - 2005 R.I.P.


    http://www.freewebs.com/ofpbob/index.htm

  3. #3

    Thumbs up

    "aware" is not neccessary, thats right, but removing it didn&#39;t change anything.

    Solution:
    <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">
    _Civilian addweapon _Weapon
    {_Civilian addmagazine _x} foreach _Magazines
    _Civilian selectweapon _Weapon
    ~10
    _Civilian setunitpos &#34;UP&#34;
    [/QUOTE]

    Before you setunitpos "UP", add the weapon and wait around 10 seconds.
    The civilian starts with added weapon on back, after a short while he gets the weapon ready.
    Now it is possible to setunitpos "UP" without turning the civilian in somekind of "hold fire" mode.

    Units that are created (createunit) without weapons seem to be in careless/safe mode until they are completely initiated. Setunitpos "UP" in the moment of initialisation lets them remain in careless/safe.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •