瀏覽代碼

词条有一部分了

cyzhao 1 年之前
父節點
當前提交
4058487ea6
共有 1 個文件被更改,包括 7 次插入4 次删除
  1. 7 4
      Gameserver/App/process/StoreProc.php

+ 7 - 4
Gameserver/App/process/StoreProc.php

@@ -787,11 +787,14 @@ class StoreProc {
             }
             }
         }
         }
         
         
-//        my_Assert(count($arr) > 0, "宝石没有对应词条信息");
-//        $n = mt_rand(0, count($arr)-1);
-//            return $n;
+        if(count($arr) <= 0){
+            return 40;
+        }
+        my_Assert(count($arr) > 0, "宝石没有对应词条信息");
+        $n = mt_rand(0, count($arr)-1);
+        return $arr[$n];
 
 
-        return 40;
+        //return 40;
     }
     }
 
 
     /**
     /**