Exemplo n.º 1
0
        public void ShapeBaseSetDamageDT(coShapeBase shapebase, float damageAmount, string damageType)
            {
            // This function is used to apply damage over time.  The damage is applied
            // at a fixed rate (50 ms).  Damage could be applied over time using the
            // built in ShapBase C++ repair functions (using a neg. repair), but this
            // has the advantage of going through the normal script channels.

            if (shapebase.getDamageState() != "Dead")
                {
                ShapeBaseDamage(shapebase, 0, new Point3F("0 0 0"), damageAmount, damageType);
                shapebase["damageSchedule"] = shapebase.schedule("50", "setDamageDt", damageAmount.AsString(), damageType).AsString();
                }
            else
                {
                shapebase["damageSchedule"] = "";
                }
            }
Exemplo n.º 2
0
 public void DeployableTurretWeaponImageOnFire(coShapeBaseImageData thisobj, coShapeBase obj, int slot)
     {
     obj.schedule("0", "throw", thisobj["item"]);
     }