Beispiel #1
0
        // called by engine
        static bool RaiseCritterStealing(Critter cr, Critter thief, Item item, int count)
        {
            GlobalCritterStealingEventArgs e = null;

            if (CritterStealing != null)
            {
                e = new GlobalCritterStealingEventArgs(cr, thief, item, count);
                CritterStealing(null, e);
            }
            return(e != null ? e.Success : GlobalCritterStealingEventArgs.Default);
        }
Beispiel #2
0
 // called by engine
 static bool RaiseCritterStealing(Critter cr, Critter thief, Item item, int count)
 {
     GlobalCritterStealingEventArgs e = null;
     if (CritterStealing != null) {
         e = new GlobalCritterStealingEventArgs(cr, thief, item, count);
         CritterStealing(null, e);
     }
     return e != null ? e.Success : GlobalCritterStealingEventArgs.Default;
 }