Jump to content
Sign in to follow this  
AnnDy.

[INCOMPLET] amx_Who

Recommended Posts

Cand scrii comanda amx_who chiar daca sunt admini online nu se vede nimeni ... 

 

#include <amxmodx>
#include <amxmisc>
#define MAX_GROUPS 10
new g_groupNames[MAX_GROUPS][] = {
"[TR]FOUNDER",
"[TR]Owner",
"[TR]Co-Owner",
"[TR]Maresal",
"[TR]General",
"[TR]Colonel",
"[TR]Maior",
"[TR]Sergent",
"[TR]Slot",
"[TR]V.I.P"
}
new g_groupFlags[MAX_GROUPS][] = {
"abcdefghijklmnopqrstu",
"abcdefghijklmnopqrst",
"bcdefghijklmnopqrst",
"bcdefhijlmnopqrst",
"bcdefhijlmnopqrs",
"bcdefijlmnopqrs",
"bcdefijmnoprs",
"bcdefijmnrs",
"bi",
"abi"
}
new g_groupFlagsValue[MAX_GROUPS]
public plugin_init() {
register_plugin("Amx Who", "1.0", "rangfort.ro")
register_concmd("amx_who", "cmdWho", 0)
for(new i = 0; i < MAX_GROUPS; i++) {
g_groupFlagsValue = read_flags(g_groupFlags)
}
}
public cmdWho(id) {
new players[32], inum, player, name[32], i, a
get_players(players, inum)
console_print(id, "- Comunitatea RangFort TR -")
for(i = 0; i < MAX_GROUPS; i++) {
console_print(id, "-----[%d]%s-----", i+1, g_groupNames)
for(a = 0; a < inum; ++a) {
player = players[a]
get_user_name(player, name, 31)
if(get_user_flags(player) == g_groupFlagsValue) {
console_print(id, "%s", name)
}
}
}
console_print(id, "- Comunitatea RangFort TR -")
return PLUGIN_HANDLED
}
 

Share this post


Link to post
Share on other sites

deci vrei un plugin de amx_who ? daca vrei un plugin de amx_who lasa-mi un mesaj cu gradele si flagurile si iti dau eu ce ai nevoie.

  • Like 1

Share this post


Link to post
Share on other sites
#include <amxmodx>
#include <amxmisc>
#define MAX_GROUPS 10
new g_groupNames[MAX_GROUPS][] = {
"Founder",
"Owner",
"Co-Owner",
"Maresal",
"General",
"Colonel",
"Maior",
"Sergent",
"Slot",
"V.I.P"
}
new g_groupFlags[MAX_GROUPS][] = {
"abcdefghijklmnopqrstu",
"abcdefghijklmnopqrst",
"bcdefghijklmnopqrst",
"bcdefhijlmnopqrst",
"bcdefhijlmnopqrs",
"bcdefijlmnopqrs",
"bcdefijmnoprs",
"bcdefijmnrs",
"bi",
"abi"
}
new g_groupFlagsValue[MAX_GROUPS];
public plugin_init() {
register_plugin("Lista admini (amx_who) by Perception", "1.0", "rangfort")
register_concmd("amx_who", "cmdWho", 0);
register_concmd("admin_who", "cmdWho", 0);
for(new i = 0; i < MAX_GROUPS; i++) {
g_groupFlagsValue[i] = read_flags(g_groupFlags[i])
}
}
public cmdWho(id) {
// Verificam daca userul este online, daca nu... ne oprim din executie
if(!is_user_connected(id)) { return PLUGIN_HANDLED; }
new players[32], inum, player, name[32], i, a;
get_players(players, inum);
console_print(id, "============== TR.RANGFORT.RO ==============");
for(i = 0; i < MAX_GROUPS; i++) {
console_print(id, "----- [%d] %s -----", i+1, g_groupNames[i])
for(a = 0; a < inum; ++a) {
player = players[a]
get_user_name(player, name, 31);
if(get_user_flags(player) == g_groupFlagsValue[i]) {
console_print(id, ">>> %s", name);
}
}
}
console_print(id, "============== WWW.RANGFORT.RO ==============")
return PLUGIN_HANDLED
}

Comenzi pentru a vedea adminii in consola:

  • amx_who
  • admin_who

marvel_team, frate flagurile si numele gradelor le-a afisat el in amx_who-ul lui ... doar ca lui nu-i apar adminii, atata tot. Cu acest amx_who ar trebuii sa mearga, daca nu , lasi reply aici si spui daca merge sau nu pluginul.

  • Like 1

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×