引用 | 編輯
kit19946
2011-03-19 19:58 |
樓主
▼ |
||
![]() { if(get_user_team(attacker) == 1) { g_jbpacks[attacker] += get_pcvar_num(g_killjp) if(get_pdata_int(victim, 75) == HIT_HEAD) { g_jbpacks[attacker] += get_pcvar_num(g_killhsjp) 以上源碼是當賊殺了人可得到 g_killhsjp 如果我想當賊這場勝利,下場可以得到g_killhsjp 應該怎樣改?? ![]()
|
引用 | 編輯
史來姆
2011-03-19 20:33 |
1樓
▲ ▼ |
plugin_init() :
register_message(get_user_msgid("TextMsg"), "message_textmsg") public message_textmsg() { static textmsg[22] get_msg_arg_string(2, textmsg, charsmax(textmsg)) if (equal(textmsg, "#Terrorists_Win")) { for (new id=1;id<=get_maxplayers();id++) { if (!is_user_connected(id)) continue if (get_user_team(id) != 1) continue g_jbpacks[id] += get_pcvar_num(g_killhsjp) } } } 這是我想出來的方法 ![]() |