예제 #1
0
 private void OnEntityEnterColShapeHandler(ColShape shape, NetHandle entity)
 {
     if (!entity.IsNull && API.getPlayerFromHandle(entity) != null)
     {
         Client player = API.getPlayerFromHandle(entity);
         if (shape.Equals(farmJobLocShape) && (API.getEntityData(player, "doingFarmjob") == null || !API.getEntityData(player, "doingFarmjob")))
         {
             deleteFarmjobLocationMarker(player);
             return;
         }
         if (deliveryColshapes.Contains(shape))
         {
             if (API.getEntityData(player, "isDelivering") != null && API.getEntityData(player, "isDelivering"))
             {
                 if (API.getEntityData(player, "deliveryId") != null && API.getEntityData(player, "deliveryId") == deliveryColshapes.IndexOf(shape))
                 {
                     deliverGoods(player);
                 }
                 return;
             }
         }
         if (shape.Equals(farmEndLocShape))
         {
             if (API.getEntityData(player, "isReturning") != null && API.getEntityData(player, "isReturning"))
             {
                 endFarmjob(player);
             }
         }
     }
 }
예제 #2
0
 private void OnEntityEnterColShapeHandler(ColShape shape, NetHandle entity)
 {
     if (!entity.IsNull && API.getPlayerFromHandle(entity) != null)
     {
         Client player = API.getPlayerFromHandle(entity);
         if (shape.Equals(SellFishColShape))
         {
             deleteSidejobLocationMarker(player);
         }
     }
 }