Browse Source

修复道具产出数量出错的问题

SunnyLinSD 6 years ago
parent
commit
78a3680445
1 changed files with 1 additions and 5 deletions
  1. 1 5
      assets/scripts/levelHome/LevelHomePropItem.js

+ 1 - 5
assets/scripts/levelHome/LevelHomePropItem.js

@@ -1,7 +1,6 @@
 
 
 const HomeApi = require("../net/HomeApi");
 const HomeApi = require("../net/HomeApi");
 const DWTool = require("../utils/DWTool");
 const DWTool = require("../utils/DWTool");
-const itemList = require('../data/item');
 const GameModule = require("../utils/GameModule");
 const GameModule = require("../utils/GameModule");
 
 
 cc.Class({
 cc.Class({
@@ -17,10 +16,7 @@ cc.Class({
     init(buildingId, propData, pickupCallback) {
     init(buildingId, propData, pickupCallback) {
         this.buildingId = buildingId;
         this.buildingId = buildingId;
 
 
-        // 根据道具id获取道具数据
-        this.propData = Object.assign(propData, itemList.find(n => {
-            return n.id == propData.id
-        }))
+        this.propData = propData;
 
 
         console.log(this.propData);
         console.log(this.propData);