皮洨歪大大補給箱插件的一些問題..

Home Home
引用 | 編輯 love2257210
2010-09-02 21:36
樓主
推文 x0
http://bbs.mychat.to/reads.php?tid=856122&keyword=%E8%A3%9C%E7%B5%A6我用他的這個
為什麼我有時候去撿補給箱時會有撿到東西的聲音
卻沒顯示任何提示,如果沒撿到的話
它有時會說
我很倒楣,補給箱裡沒有任何東西
我有刪了一些槍,要從哪裡刪除比較完整
因為我都直接把不要的
把它編號下面的都刪除。
這樣可以嗎?
例如:
case 2:
  {
   drop_weapons(id, 1)
   fm_give_item(id, "weapon_sg552")
   fm_give_item(id, "ammo_556nato")
   fm_give_item(id, "ammo_556nato")
   fm_give_item(id, "ammo_556nato")
   fm_give_item(id, "ammo_556nato")
   
   client_print(0, print_center, "%s 撿到了CV47-60R", name)
我就會刪完後會變成剩下這樣..
case 2:
這樣對嗎?
(就是編號下面全部的都被刪除了)
如果有誤請告知謝謝 !

獻花 x0
引用 | 編輯 皮洨歪
2010-09-02 22:10
1樓
  
您好
若槍枝太多 您要刪除的話
恩.... 舉例來說
----------------------------------------------------
  case 1:  
  {
   drop_weapons(id, 1)  
   fm_give_item(id, "weapon_mp5navy")  
   fm_give_item(id, "ammo_9mm")  
   fm_give_item(id, "ammo_9mm")
   fm_give_item(id, "ammo_9mm")
   fm_give_item(id, "ammo_9mm")
   
   client_print(0, print_center, "%s 撿到一把MP5 衝鋒槍", name)  
  }
  case 2:
  {
   drop_weapons(id, 1)
   fm_give_item(id, "weapon_sg552")
   fm_give_item(id, "ammo_556nato")
   fm_give_item(id, "ammo_556nato")
   fm_give_item(id, "ammo_556nato")
   fm_give_item(id, "ammo_556nato")
   
   client_print(0, print_center, "%s 撿到一把SIG552 近狙型步槍", name)
  }

  case 3:
  {
   drop_weapons(id, 1)
   fm_give_item(id, "weapon_mac10")
   fm_give_item(id, "ammo_45acp")
   fm_give_item(id, "ammo_45acp")
   fm_give_item(id, "ammo_45acp")
   fm_give_item(id, "ammo_45acp")
   
   client_print(0, print_center, "%s 撿到一把MAC10 小型衝鋒槍", name)
  }
----------------------------------------------------

把紅色粗體字部份 刪除
而 編號 3 的部份 就改成 編號 2

----------------------------------------------------
  case 1:  
  {
   drop_weapons(id, 1)  
   fm_give_item(id, "weapon_mp5navy") 
   fm_give_item(id, "ammo_9mm")  
   fm_give_item(id, "ammo_9mm")
   fm_give_item(id, "ammo_9mm")
   fm_give_item(id, "ammo_9mm")
   
   client_print(0, print_center, "%s 撿到一把MP5 衝鋒槍", name)  
  }
  case 3:  # 3 > 2
  {
   drop_weapons(id, 1)
   fm_give_item(id, "weapon_mac10")
   fm_give_item(id, "ammo_45acp")
   fm_give_item(id, "ammo_45acp")
   fm_give_item(id, "ammo_45acp")
   fm_give_item(id, "ammo_45acp")
   
   client_print(0, print_center, "%s 撿到一把MAC10 小型衝鋒槍", name)
  }
----------------------------------------------------

後面也是 要排序 1.2.3.4..............X




new num = random_num(1, 20)


部分

如果您的
case #  剩下 17 項


改成

new num = random_num(1, 17)


這樣就行了^^

獻花 x1
引用 | 編輯 love2257210
2010-09-03 17:14
2樓
  
下面是引用 皮洨歪 於 2010-09-02 22:10 發表的 : 到引言文
您好
若槍枝太多 您要刪除的話
恩.... 舉例來說
----------------------------------------------------
  case 1:  
.......

能順便問一下
要怎麼改補給箱槍的備用子彈
好像有教學... 但看不懂...而且用了好像也沒用..
會的話能教我一下嗎?

獻花 x0
引用 | 編輯 史來姆
2010-09-03 17:22
3樓
  
在fm_give_item(id, "weapon_xxx") 下面加上
fm_set_user_bpammo(id, CSW_XXX, YYY)
XXX為槍枝名稱,例如AWP,AK47,ELITE等等
YYY為後備子彈數目,例如200

如果我想SG552有200後備彈,便寫成這樣
fm_give_item(id, "weapon_sg552")
fm_set_user_bpammo(id, CSW_SG552, 200)

獻花 x1
引用 | 編輯 love2257210
2010-09-03 17:45
4樓
  
下面是引用 史來姆 於 2010-09-03 17:22 發表的 : 到引言文
在fm_give_item(id, "weapon_xxx") 下面加上
fm_set_user_bpammo(id, CSW_XXX, YYY)
XXX為槍枝名稱,例如AWP,AK47,ELITE等等
YYY為後備子彈數目,例如200

如果我想SG552有200後備彈,便寫成這樣
fm_give_item(id, "weapon_sg552")
fm_set_user_bpammo(id, CSW_SG552, 200)

好像沒用耶...因為加進去後就變成沒辦法轉擋了

獻花 x0
引用 | 編輯 史來姆
2010-09-03 17:46
5樓
  
有沒有#include<cstrike>?

獻花 x0
引用 | 編輯 love2257210
2010-09-03 17:59
6樓
  
下面是引用 史來姆 於 2010-09-03 17:22 發表的 : 到引言文
在fm_give_item(id, "weapon_xxx") 下面加上
fm_set_user_bpammo(id, CSW_XXX, YYY)
XXX為槍枝名稱,例如AWP,AK47,ELITE等等
YYY為後備子彈數目,例如200

如果我想SG552有200後備彈,便寫成這樣
fm_give_item(id, "weapon_sg552")
fm_set_user_bpammo(id, CSW_SG552, 200)


是我錯怪你了...剛剛用的時候好像是我自己不小心加到什麼符號吧
成功了!謝謝你!每次您都熱心的幫別人解答!花花給你表情

獻花 x0