Esempio n. 1
0
        protected double _getEnergy;                     //For energy repair


        ///////////////////////////////////////////////////
        // Member Functions
        ///////////////////////////////////////////////////
        /// <summary>
        /// Generic constructor
        /// </summary>
        public Computer(VehInfo.Computer type, Arena arena)
            : base(type, arena)
        {
            _type = type;

            //Load the appropriate turret settings
            AssetManager am = Helpers._server._assets;

            //What is the gun we're going to be shooting?
            int wepID = type.InventoryItems[0];

            //_arena.sendArenaMessage("wepid: " + wepID);

            if (wepID != 0)
            {                   //Find our primary weapon
                _primaryGun = am.getItemByID(wepID);
                _primaryGun.getAmmoType(out _ammoType, out _ammoCount, out _ammoCapacity);
                _ammoRemaining = _ammoCapacity;

                //What sort of
                if (_primaryGun is ItemInfo.MultiUse)
                {
                    ItemInfo.MultiUse mug = (ItemInfo.MultiUse)_primaryGun;
                    _reloadTime = mug.reloadDelayNormal * 10;
                    _fireDelay  = mug.fireDelay * 10;

                    //Assume the first item is the tracking projectile
                    _primaryProjectile = ((ItemInfo.Projectile)am.getItemByID(mug.childItems[0].id));
                }
                else if (_primaryGun is ItemInfo.Projectile)
                {
                    _primaryProjectile = (ItemInfo.Projectile)_primaryGun;
                    _reloadTime        = _primaryProjectile.reloadDelayNormal * 10;
                    _fireDelay         = _primaryProjectile.fireDelay * 10;
                }
                else
                {
                    //Treat it as no weapon
                    _primaryGun = null;
                }
            }
            else
            {
                _primaryGun = null;
            }

            configureComp();
        }
Esempio n. 2
0
    {           // Member variables
        ///////////////////////////////////////////////////


        ///////////////////////////////////////////////////
        // Member Functions
        ///////////////////////////////////////////////////
        /// <summary>
        /// Generic constructor
        /// </summary>
        public HealingBotTurret(VehInfo.Computer type, Arena arena)
            : base(type, arena)
        {
        }
Esempio n. 3
0
 ///////////////////////////////////////////////////
 // Member Functions
 ///////////////////////////////////////////////////
 /// <summary>
 /// Generic constructor
 /// </summary>
 public LaserTurret(VehInfo.Computer type, Arena arena)
     : base(type, arena)
 {
 }
Esempio n. 4
0
 public Script_MOBA _moba;                           //The MOBA script
 ///////////////////////////////////////////////////
 // Member Functions
 ///////////////////////////////////////////////////
 /// <summary>
 /// Generic constructor
 /// </summary>
 public Tower(VehInfo.Computer type, Arena arena)
     : base(type, arena)
 {
 }
Esempio n. 5
0
 ///////////////////////////////////////////////////
 // Member Functions
 ///////////////////////////////////////////////////
 /// <summary>
 /// Generic constructor
 /// </summary>
 public SnareTrap(VehInfo.Computer type, Arena arena)
     : base(type, arena)
 {
 }
Esempio n. 6
0
        public const bool chargeOccludedPlayers = false; //do we charge occluded players?

        ///////////////////////////////////////////////////
        // Member Functions
        ///////////////////////////////////////////////////
        /// <summary>
        /// Generic constructor
        /// </summary>
        public EnergizerBotTurret(VehInfo.Computer type, Arena arena)
            : base(type, arena)
        {
        }