示例#1
0
 private static bool ConditionMet(string condition)
 {
     if (string.IsNullOrEmpty(condition))
     {
         return(false);
     }
     if (condition != null)
     {
         if (condition == "ownsArmory")
         {
             return(ArmoryUtils.PlayerHasArmory());
         }
         if (condition == "hasAvailableEquipment")
         {
             return(CrateUtils.PlayerHasEquipmentAvailable());
         }
     }
     if (condition.StartsWith("hq"))
     {
         string value = condition.Substring("hq".Length);
         int    level = Convert.ToInt32(value);
         return(CrateUtils.PlayerHasAtLeastHqLevel(level));
     }
     return(false);
 }
示例#2
0
 public unsafe static long $Invoke5(long instance, long *args)
 {
     return(GCHandledObjects.ObjectToGCHandle(CrateUtils.PlayerHasAtLeastHqLevel(*(int *)args)));
 }