HoJai
|
分享:
▼
x0
|
[1.6][插件] 我的点数插件问题!!
我写了一个点数插件.. 我设定了一个在线送点数的系统..但只有Admin他才会送..普通玩家没有 高手能帮帮我吗?
public client_putinserver(id)
{
LoadData(id)
set_task(0.5, "show_user_info", id, _, _, "b")
set_task(180.0, "give_point", id)
set_task(300.0, "give_point2", id)
set_task(600.0, "give_point3", id)
set_task(1200.0, "give_point4", id)
set_task(1800.0, "give_point5", id)
set_task(2400.0, "give_point6", id)
set_task(3000.0, "give_point7", id)
set_task(3600.0, "give_point8", id)
}
public give_point(id)
{ if(!access(id, ADMIN_BAN)) return 1; new name[32] get_user_name(id, name, 31) if(access(id, ADMIN_CFG)) { g_point[id] += 3 client_print(0,print_chat,"[管理员]%s在线3分钟 | +3点数", name) } else { g_point[id] += 2 client_print(0, print_chat, "[普通玩家]%s在线3分钟 | +2点数", name) } return 1;
}
public give_point2(id)
{ if(!access(id, ADMIN_BAN)) return 1; new name[32] get_user_name(id, name, 31) if(access(id, ADMIN_CFG)) { g_point[id] += 5 client_print(0,print_chat,"[管理员]%s在线5分钟 | +5点数", name) } else { g_point[id] += 3 client_print(0, print_chat, "[普通玩家]%s在线5分钟 | +3点数", name) } return 1;
}
public give_point3(id)
{ if(!access(id, ADMIN_BAN)) return 1; new name[32] get_user_name(id, name, 31) if(access(id, ADMIN_CFG)) { g_point[id] += 8 client_print(0,print_chat,"[管理员]%s在线10分钟 | +8点数", name) } else { g_point[id] += 6 client_print(0, print_chat, "[普通玩家]%s在线10分钟 | +6点数", name) } return 1;
}
public give_point4(id)
{ if(!access(id, ADMIN_BAN)) return 1; new name[32] get_user_name(id, name, 31) if(access(id, ADMIN_CFG)) { g_point[id] += 15 client_print(0,print_chat,"[管理员]%s在线20分钟 | +15点数", name) } else { g_point[id] += 12 client_print(0, print_chat, "[普通玩家]%s在线20分钟 | +12点数", name) } return 1;
}
public give_point5(id)
{ if(!access(id, ADMIN_BAN)) return 1; new name[32] get_user_name(id, name, 31) if(access(id, ADMIN_CFG)) { g_point[id] += 20 client_print(0,print_chat,"[管理员]%s在线30分钟 | +20点数", name) } else { g_point[id] += 16 client_print(0, print_chat, "[普通玩家]%s在线30分钟 | +16点数", name) } return 1;
}
public give_point6(id)
{ if(!access(id, ADMIN_BAN)) return 1; new name[32] get_user_name(id, name, 31) if(access(id, ADMIN_CFG)) { g_point[id] += 26 client_print(0,print_chat,"[管理员]%s在线40分钟 | +26点数", name) } else { g_point[id] += 21 client_print(0, print_chat, "[普通玩家]%s在线40分钟 | +21点数", name) } return 1;
}
public give_point7(id)
{ if(!access(id, ADMIN_BAN)) return 1; new name[32] get_user_name(id, name, 31) if(access(id, ADMIN_CFG)) { g_point[id] += 32 client_print(0,print_chat,"[管理员]%s在线50分钟 | +32点数", name) } else { g_point[id] += 26 client_print(0, print_chat, "[普通玩家]%s在线50分钟 | +26点数", name) } return 1;
}
public give_point8(id)
{ if(!access(id, ADMIN_BAN)) return 1; new name[32] get_user_name(id, name, 31) if(access(id, ADMIN_CFG)) { g_point[id] += 40 client_print(0,print_chat,"[管理员]%s在线60分钟 | +40点数", name) } else { g_point[id] += 34 client_print(0, print_chat, "[普通玩家]%s在线60分钟 | +34点数", name) } return 1;
}
为什么会不行?????
[ 此文章被HoJai在2011-12-17 10:13重新编辑 ]
|