endcentury
|
分享:
▼
x0
|
[1.6][插件] 帮个忙...请教修改小偷买M4的SMA
(我只是想改成..FAMAS)
我想改成小偷能买FAMAS警察能买GAlil 有没有人可以写给我参考ˊˋ 只写一个也好ˊˋ
public plugin_init() { register_plugin("buy famas&galil","2.3","bm47770") register_clcmd("say /fa","FA") register_clcmd("say /ga","GA") register_cvar("facost","2250") register_cvar("gacost","2250") new Float:maptime = get_cvar_float("mp_timelimit") if (maptime == 0.0) maptime = 15.0 new Float:anntime = 60.0 * 5.0 // 5 minutes if (maptime < 5.0) anntime = maptime / 3.0 set_task(anntime, "Announcement", 0, "", 0, "b") } public client_putinserver(id) { set_task(25.0, "Announcement", id) return PLUGIN_CONTINUE } public Announcement(id) { client_print(id, print_chat, "武器共通 [say /fa & say /ga]") }
} public GA(id) { new gacost = get_cvar_num("gacost") new moneyy = cs_get_user_money(id) if(!is_user_alive(id)) { client_print(id,print_chat,"死者不能买^n") } if(moneyy < gacost) { client_print(id,print_chat,"现金不足^n") } else { cs_set_user_money(id,moneyy-gacost) give_item(id, "weapon_galil") } }
(FAMAS的格式跟GALIL一样) ???????? 别笑我...我真的很认真在想办法...我自少爬了6篇文了...虽然都看不懂= =不过我真的看了6.7小时
|