예제 #1
0
 public SpawnEnvironmentEffectEvent(VTankBot _game, int id, int typeId, VTankObject.Point location, int ownerId)
     : base(_game)
 {
     this.id       = id;
     this.typeId   = typeId;
     this.location = location;
     this.ownerId  = ownerId;
     envEffect     = WeaponLoader.GetEnvironmentProperty(typeId);
 }
예제 #2
0
        public override void DoAction()
        {
            envEffect = WeaponLoader.GetEnvironmentProperty(typeId);

            creationPosition = this.GetPosition();

            if (Game.Players.ContainsKey(ownerId))
            {
                envEffect.Owner = Game.Players[ownerId];
            }

            Game.EnvironmentEffects.AddEffect(envEffect, id, creationPosition);
        }