Пример #1
0
        public static void onMove(BloonEvents.MoveEvent e)
        {
            IBloonEntity bloon = e.getBloon();

            //Logger.Log("Progress: "+bloon.getProgress());
            float[] pos = bloon.getPosition();
            //Logger.Log("Position (X,Y,Z)".Replace("X", pos[0].ToString()).Replace("Y", pos[1].ToString()).Replace("Z", pos[2].ToString()));
            if (bloon.getProgress() > 500)
            {
                e.SetCancelled(true);
            }
        }
Пример #2
0
 public DamagedEvent(IBloonEntity bloon, float totalAmount, string[] types, IProjectileEntity projectile,
                     bool distributeToChildren, bool overrideDistributeBlocker, bool createEffect, ITowerEntity tower,
                     bool canDestroyProjectile, string[] ignoreImmunityForBloonTypes, bool ignoreNonTargetable,
                     bool blockSpawnChildren) : base()
 {
     this.bloon                       = bloon;
     this.damageTaken                 = totalAmount;
     this.damageTypes                 = types;
     this.projectile                  = projectile;
     this.distrubuteToChildren        = distributeToChildren;
     this.overrideDistributeBlocker   = overrideDistributeBlocker;
     this.createEffect                = createEffect;
     this.tower                       = tower;
     this.canDestroyProjectile        = canDestroyProjectile;
     this.ignoreImmunityForBloonTypes = ignoreImmunityForBloonTypes;
     this.ignoreNonTargetables        = ignoreNonTargetable;
     this.blockSpawnChildren          = blockSpawnChildren;
 }
Пример #3
0
        public static void onMove(BloonEvents.MoveEvent e) // Create the function
        {
            IBloonEntity bloon = e.GetBloon();             // Get the bloon

            if (bloon is GreenCamoBloon)                   // Check if the bloon is Green and Camo
            {
                float prog = bloon.GetProgress();          // Get the bloon's progress
                if (prog > 500.0f)                         // If the progress is over 500
                {
                    e.SetCancelled(true);                  // Cancel the event (The bloon will not move)
                }
            }
            else
            {
                if (bloon.GetProgress() > 1000.0f) // If the progress is over 1000
                {
                    e.SetCancelled(true);          // Cancel the event
                }
            }
        }
Пример #4
0
 public LeakedEvent(IBloonEntity bloon) : base()
 {
     this.bloon = bloon;
 }
Пример #5
0
 public MoveEvent(IBloonEntity bloon) : base()
 {
     this.bloon = bloon;
 }
Пример #6
0
        public static void onRotate(BloonEvents.RotateEvent e)
        {
            IBloonEntity bloon = e.getBloon();

            Logger.Log(bloon.getRotation().ToString());
        }
Пример #7
0
 public DeletedEvent(IBloonEntity bloon) : base()
 {
     this.bloon = bloon;
 }
Пример #8
0
 public CreatedEvent(IBloonEntity bloon) : base()
 {
     this.bloon = bloon;
 }
Пример #9
0
 public RotateEvent(IBloonEntity bloon, float rotation) : base()
 {
     this.bloon    = bloon;
     this.rotation = rotation;
 }