Home   Help Search Login Register  

Author Topic: CfgMoves Config.Cpp trables  (Read 1763 times)

0 Members and 1 Guest are viewing this topic.

nero12

  • Guest
CfgMoves Config.Cpp trables
« on: 28 Mar 2003, 18:39:09 »
Hi all,
I need help with config.cpp. I need to change the way the gun is reloaded and the way unit holds the weapon and walks with it.
Beforehand thanks.

qwertyuio

  • Guest
Re:CfgMoves Config.Cpp trables
« Reply #1 on: 02 Apr 2003, 23:20:07 »
More details if you may...

I think I know the problem, do you want it to be like an AT launcher when walking and reloading?

If this is so you can use inheritance from the LAW launcher, or you can use the animation from the LAW. I'm not sure what that is by the way, but it can be done.

nero12

  • Guest
Re:CfgMoves Config.Cpp trables
« Reply #2 on: 03 Apr 2003, 03:37:54 »
More details if you may...

I think I know the problem, do you want it to be like an AT launcher when walking and reloading?

If this is so you can use inheritance from the LAW launcher, or you can use the animation from the LAW. I'm not sure what that is by the way, but it can be done.

Thanks that has decided to answer to me. ;D

Yes just it also is necessary to me, walking and reloading.
I should register a new kind of recharge for RPG,
Example: reloadAction = ManActReloadMortar; reloadAction = ManActReloadAT;

nero12

  • Guest
Re:CfgMoves Config.Cpp trables
« Reply #3 on: 05 Apr 2003, 17:25:18 »
qwertyuio Help me please
nero12@mail.ru
icq 173250341

qwertyuio

  • Guest
Re:CfgMoves Config.Cpp trables
« Reply #4 on: 07 Apr 2003, 19:38:28 »
copy the law p3d file from ofp/dta/data.pbo to your addon (the one youre making) directory, and just use the command reloadAction = ManActReloadLAW; in the cpp. I am not sure how to do thewalking, but you could do when defining weapons class default{};
                                                                                     class LAW:default{

                                                                                     
                                                                             your defines for the weapon here eg optics=true
                                                                                                                  }

nero12

  • Guest
Re:CfgMoves Config.Cpp trables
« Reply #5 on: 08 Apr 2003, 12:20:11 »
I have made new animation for reloading RPG7 as to me to register that my animation instead of standard was used
reloadAction = my reload
« Last Edit: 08 Apr 2003, 12:21:50 by nero12 »

Leone

  • Guest
Re:CfgMoves Config.Cpp trables
« Reply #6 on: 25 Apr 2003, 16:46:06 »
I am trying to make a canteen that can be used to give you a drink of water. I have a model, and the scripting side of things (such as getting thirsty, refilling a canteen etc etc) can be done via scripts etc. The problem I am having is getting it to be animated using the binocular animations (which, when working, should look right). Here's the config for the object:

#define WeaponNoSlot         0
#define WeaponSlotPrimary      1
#define WeaponSlotSecondary      16
#define WeaponSlotItem         256
#define WeaponSlotBinocular      4096
#define WeaponHardMounted      65536

class CfgPatches
{
   class ds_canteen
   {
      units[] = {canteen};
      weapons[] = {canteen};
      requiredVersion = 1.40;
   };
};

//CfgVehicles for Testing purposes only

class CfgVehicles
{
   class All{};
   class AllVehicles:All{};
   class Land:AllVehicles{};
   class Man:Land{};
   class Soldier:Man{};
   class SoldierWB:Soldier{};
   class SoldierWSniper:SoldierWB{};
   class ds_canteen:SoldierWSniper
   {
      displayName="US WaterDude";
      weapons[]={us_canteen};
      nightVision=0;
      camouflage=0.600000;
         moves="CfgCanteenMoves";//looks for the config underneath
   };
};

class CfgWeapons
{
   class Default {};
   class Binocular: Default {};
   class canteen: Binocular
   {   
      scopeMagazine=2;
      valueWeapon=5;
      weaponType=WeaponSlotBinocular;
      picture="";
      sound[]={"",0,1};
      useAction=0;
      useActionTitle="";
      optics=0;
      forceOptics=0;
      scope=2;
      canDrop=1;
   };
   class ir_canteen: canteen
   {
      model="\ds_canteen\canteen.p3d";
      displayName="Iraqi Canteen";
   };
   class us_canteen: canteen
   {
      model="\ds_canteen\us_canteen.p3d";
      displayName="US Canteen";
   };
};

class CfgNonAIVehicles
{
   class ProxyWeapon {};
   class ProxyCanteen: ProxyWeapon {};
};

And then there is the CanteenMoves.pbo, which only has the following config file in it:

#define WeaponNoSlot         0
#define WeaponSlotPrimary      1
#define WeaponSlotSecondary      16
#define WeaponSlotItem         256
#define WeaponSlotBinocular      4096
#define WeaponHardMounted      65536

class CfgPatches
{
   class CfgCanteenMoves
   {
      units[] = {};
      weapons[] = {};
      requiredVersion = 1.75;
   };
};

class CfgDSManActions
   {
      CanteenOn="";
      CanteenOff="";
   };

class CfgMovesMC{};
class CfgCanteenMoves:CfgMovesMC
{
   class DSNoActionsAll: CfgDSManActions
   {
      access=3;
   };
   class DSNoActions: DSNoActionsAll
   {
      ladderOnDown="LadderDownStart";
      ladderOnUp="LadderUpStart";
      turnSpeed=1;
      upDegree=-1;
      limitFast=5;
   };
   class DSCombatActions: DSNoActions
   {
      CanteenOn="Canteen";
      CanteenOff="Combat";
   };
   class DSCombatNoMoveActions: DSCombatActions
   {
      stopRelaxed="";
      walkF="";
      walkLF="";
      walkRF="";
      walkL="";
      walkR="";
      walkLB="";
      walkRB="";
      walkB="";
      slowF="";
      slowLF="";
      slowRF="";
      slowL="";
      slowR="";
      slowLB="";
      slowRB="";
      slowB="";
      fastF="";
      fastLF="";
      fastRF="";
      fastL="";
      fastR="";
      fastLB="";
      fastRB="";
      fastB="";
      turnL="";
      turnR="";
      turnLRelaxed="";
      turnRRelaxed="";
      turnSpeed=2;
   };
   class DSStandActions: DSNoActions
   {
      CanteenOn="CanteenStand";
      CanteenOff="Stand";
   }
   class DSCrouchActions: DSCombatActions
   {
      CanteenOn="CanteenCrouch";
      CanteenOff="Crouch";
   }
   class DSLyingActions: DSNoActions
   {
      CanteenOn="CanteenLying";
      CanteenOff="Lying";
   }
   class CanteenActions: DSCombatNoMoveActions
   {
      stop="Canteen";
      default="Canteen";
      CanteenOff="Combat";
      upDegree=MANPOSBINOC;
   };
   class CanteenLyingActions: DSLyingActions
   {
      stop="CanteenLying";
      default="CanteenLying";
      CanteenOff="Lying";
      walkF="";
      walkLF="";
      walkRF="";
      walkL="";
      walkR="";
      walkLB="";
      walkRB="";
      walkB="";
      slowF="";
      slowLF="";
      slowRF="";
      slowL="";
      slowR="";
      slowLB="";
      slowRB="";
      slowB="";
      fastF="";
      fastLF="";
      fastRF="";
      fastL="";
      fastR="";
      fastLB="";
      fastRB="";
      fastB="";
      turnL="";
      turnR="";
      turnLRelaxed="";
      turnRRelaxed="";
      upDegree=MANPOSBINOCLYING;
      turnSpeed=1;
   };
   class CanteenStandActions: DSStandActions
   {
      stop="CanteenStand";
      default="CanteenStand";
      CanteenOff="Stand";
      walkF="";
      walkLF="";
      walkRF="";
      walkL="";
      walkR="";
      walkLB="";
      walkRB="";
      walkB="";
      slowF="";
      slowLF="";
      slowRF="";
      slowL="";
      slowR="";
      slowLB="";
      slowRB="";
      slowB="";
      fastF="";
      fastLF="";
      fastRF="";
      fastL="";
      fastR="";
      fastLB="";
      fastRB="";
      fastB="";
      turnL="";
      turnR="";
      turnLRelaxed="";
      turnRRelaxed="";
      upDegree=MANPOSBINOCSTAND;
      turnSpeed=2;
   };
   class CanteenCrouchActions: DSCrouchActions
   {
      stop="CanteenCrouch";
      default="CanteenCrouch";
      CanteenOff="Crouch";
      walkF="";
      walkLF="";
      walkRF="";
      walkL="";
      walkR="";
      walkLB="";
      walkRB="";
      walkB="";
      slowF="";
      slowLF="";
      slowRF="";
      slowL="";
      slowR="";
      slowLB="";
      slowRB="";
      slowB="";
      fastF="";
      fastLF="";
      fastRF="";
      fastL="";
      fastR="";
      fastLB="";
      fastRB="";
      fastB="";
      turnL="";
      turnR="";
      turnLRelaxed="";
      turnRRelaxed="";
      upDegree=MANPOSBINOC;
      turnSpeed=2;
   };

   class DSDefault
   {
      access=3;
      actions="DSStandActions";
      file="";
      looped=1;
      speed=0.500000;
      disableWeapons=0;
      enableOptics=1;
      disableWeaponsLong=0;
      showWeaponAim=1;
      enableMissile=0;
      enableBinocular=0;
      showItemInHand=0;
      showItemInRightHand=0;
      showHandGun=0;
      onLandBeg=0;
      onLandEnd=0;
      onLadder=0;
      duty=-0.500000;
      visibleSize=1;
      aimPrecision=1;
      recoilSuffix="";
      relSpeedMin=1.000000;
      relSpeedMax=1.000000;
      soundEnabled=1;
      soundOverride="";
      soundEdge1=0.500000;
      soundEdge2=1;
      terminal=0;
      limitGunMovement=1;
      variantsPlayer[]={};
      variantsAI[]={""};
      equivalentTo="";
      connectAs="";
      variantAfter[]={5,10,20};
      connectFrom[]={};
      connectTo[]={};
      interpolateWith[]={};
      interpolateTo[]={};
      interpolateFrom[]={};
      aiming="aimingDefault";
      legs="legsDefault";
      head="headDefault";
      interpolationSpeed=6;
      interpolationRestart=0;
      preload=0;
   };

   class States
   {
      class CombatToCanteen: DSDefault
      {
         actions="DSCombatActions";
         file="sdalek.rtm";//Original Binocular Animation
         speed=-1.000000;
         looped=0;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
      };
      class Canteen: DSDefault
      {
         actions="CanteenActions";
         file="sdalekstat.rtm";//Original Binocular Animation
         speed=10000000000.000000;
         looped=1;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         enableBinocular=1;
         head="headNo";
      };
      class CanteenToCombat: DSDefault
      {
         actions="CanteenActions";
         file="sdalek2.rtm";//Original Binocular Animation
         speed=-1.000000;
         looped=0;
         disableWeapons=1;
         showItemInHand=1;
         soundEnabled=0;
      };
      class LyingToCanteenLying: DSDefault
      {
         actions="DSLyingActions";
         file="plazenidalek.rtm";//Original Binocular Animation
         speed=-2.000000;
         looped=0;
         disableWeapons=0;
         soundEnabled=0;
         showItemInHand=1;
         onLandBeg=1;
         onLandEnd=1;
      };
      class CanteenLying: DSDefault
      {
         actions="CanteenLyingActions";
         file="plazenidalekstat.rtm";//Original Binocular Animation
         speed=10000000000.000000;
         looped=1;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         enableBinocular=1;
         onLandBeg=1;
         onLandEnd=1;
         duty=-1;
      };
      class CanteenLyingToLying: DSDefault
      {
         actions="DSLyingActions";
         file="plazenidalek2.rtm";//Original Binocular Animation
         speed=-2.000000;
         looped=0;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         onLandBeg=1;
         onLandEnd=1;
      };
      class StandToCanteenStand: DSDefault
      {
         actions="DSStandActions";
         file="bezdalek.rtm";//Original Binocular Animation
         speed=-1.000000;
         looped=0;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         connectFrom[]={"Stand",2};
      };
      class CanteenStand: DSDefault
      {
         actions="CanteenStandActions";
         file="bezdalekstat.rtm";//Original Binocular Animation
         speed=10000000000.000000;
         looped=1;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         enableBinocular=1;
         connectFrom[]={"StandToCanteenStand",1};
         connectTo[]={"CanteenStandToStand",1};
      };
      class CanteenStandToStand: DSDefault
      {
         actions="DSStandActions";
         file="bezdalek2.rtm";//Original Binocular Animation
         speed=-1.000000;
         looped=0;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         connectTo[]={"Stand",2};
      };
      class CrouchToCanteenCrouch: DSDefault
      {
         actions="DSCrouchActions";
         file="klekdalekstart.rtm";//Original Binocular Animation
         speed=-1.000000;
         looped=0;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         connectFrom[]={"Crouch",2};
      };
      class CanteenCrouch: DSDefault
      {
         actions="CanteenCrouchActions";
         file="klekdalekstat.rtm";//Original Binocular Animation
         speed=10000000000.000000;
         looped=1;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         enableBinocular=1;
         connectFrom[]={"CrouchToCanteenCrouch",1};
         connectTo[]={"CanteenCrouchToCrouch",1};
      };
      class CanteenCrouchToCrouch: DSDefault
      {
         actions="DSCrouchActions";
         file="klekdalekend.rtm";//Original Binocular Animation
         speed=-1.000000;
         looped=0;
         disableWeapons=0;
         showItemInHand=1;
         soundEnabled=0;
         connectTo[]={"Crouch",2};
      };
   class DSInterpolations
   {};
   transitionsInterpolated[]={};
   transitionsSimple[]={"Combat","CombatToCanteen",2,"CombatToCanteen","Canteen",2,"Canteen","CanteenToCombat",2,"CanteenToCombat","LyingToCanteenLying",2,"LyingToCanteenLying","CanteenLying",2,"CanteenLying","CanteenLyingToLying",2,"CanteenLyingToLying","Lying",2};
   transitionsDisabled[]={};
};


Any help GREATLY appreciated. If I remove all the animation stuff, and just have a soldier with the Canteen, it works fine (well, you can drop it, pick it up, have it as your weapon). As soon as I try using the animations (which are BIS animations) it crashes to desktop as soon as I try to preview it in the MissionEditor.

Thanks for any help.  :)