Existing user? Sign in
Sign up
Games
Servers
Useful
User
Pass
2FA
[rezolvat][Cerere] Gold Members
Freakz Forum Index
->
Trash Bin
->
CS 2006-2019 (Archived)
->
Plugins - Help / Support
Author
Message
1382
QuIzZ
[Banned user]
Status: Offline
(since 03-02-2015 21:28)
Joined: 03 Jan 2015
Posts: 101
,
Topics: 20
Location:
Romania
Reputation:
24.2
Votes
: 9
Posted: 03-02-2015, 12:24:07
| Translate post to:
... (
Click for more languages
)
Am pluginul asta de Gold Members ,problema este ca pentru a baga pe cineva Gold Member trebuie sa ii trec in users.ini cu flagul t,daca un admin ia Gold Member eu trebuie sa modific si pluginul /admins si sa pun flagul t la gradul pe care il are adminul ca sa apara ca admin,ceea ce nu e bine deloc.
Pe langa asta am si pluginul zm_vip care creeaza in configs fisierul vips.ini in care sunt trecuti vipii .Eu as vrea ca pun Membrii Gold in vips.ini cu flagul F .
Spoiler:
Code:
#include <amxmodx>
#include <engine>
#define PLUGIN "Show Admins Online"
#define VERSION "1.1"
#define AUTHOR "IceCreamCandy"
new bool:g_bAdminNick
new bool:is_admin_connected[33]
new g_msg[512]
new g_admin_enable
new g_online_color
new g_msg_xypos
new g_SyncAdmin
new g_iAdminCount
new g_iMaxPlayers
new g_ClassName[] = "admin_msg"
public plugin_init()
{
register_plugin( PLUGIN, VERSION, AUTHOR )
register_think(g_ClassName,"ForwardThink")
g_admin_enable = register_cvar("sa_plugin_on","1")
g_online_color = register_cvar("sa_online_color","0 130 0")
g_msg_xypos = register_cvar("sa_msg_xypos","0.02 0.2")
g_SyncAdmin = CreateHudSyncObj()
g_iMaxPlayers = get_maxplayers()
new iEnt = create_entity("info_target")
entity_set_string(iEnt, EV_SZ_classname, g_ClassName)
entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 2.0)
}
public client_putinserver(id)
{
if(get_user_flags(id) & ADMIN_LEVEL_H)
{
is_admin_connected[id] = true
g_iAdminCount++
set_admin_msg()
}
if(g_iAdminCount == 0)
set_admin_msg()
}
public client_disconnect(id)
{
if(is_admin_connected[id])
{
is_admin_connected[id] = false
g_iAdminCount--
set_admin_msg()
}
}
public client_infochanged(id)
{
if(is_admin_connected[id])
{
static NewName[32], OldName[32]
get_user_info(id, "name", NewName, 31)
get_user_name(id, OldName, 31)
if(!equal(OldName, NewName))
{
g_bAdminNick = true
}
}
}
public set_admin_msg()
{
static g_iAdminName[32], pos, i
pos = 0
pos += formatex(g_msg[pos], 511-pos, "Gold Members: %d", g_iAdminCount)
for(i = 1 ; i <= g_iMaxPlayers ; i++)
{
if(is_admin_connected[i])
{
get_user_name(i, g_iAdminName, 31)
pos += formatex(g_msg[pos], 511-pos, "^n%s", g_iAdminName)
}
}
}
public admins_online()
{
if(get_pcvar_num(g_admin_enable))
{
static r, g, b, Float:x,Float:y
HudMsgPos(x,y)
if (g_iAdminCount > 0)
{
HudMsgColor(g_online_color, r, g, b)
set_hudmessage(r, g, b, x, y, _, _, 4.0, _, _, 4)
ShowSyncHudMsg(0, g_SyncAdmin, "%s", g_msg)
}
}
return PLUGIN_HANDLED
}
public ForwardThink(iEnt)
{
admins_online()
if(g_bAdminNick)
{
set_admin_msg()
g_bAdminNick = false
}
entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 2.0)
}
public HudMsgColor(cvar, &r, &g, &b)
{
static color[16], piece[5]
get_pcvar_string(cvar, color, 15)
strbreak( color, piece, 4, color, 15)
r = str_to_num(piece)
strbreak( color, piece, 4, color, 15)
g = str_to_num(piece)
b = str_to_num(color)
}
public HudMsgPos(&Float:x, &Float:y)
{
static coords[16], piece[10]
get_pcvar_string(g_msg_xypos, coords, 15)
strbreak(coords, piece, 9, coords, 15)
x = str_to_float(piece)
y = str_to_float(coords)
}
0
0
Back to top
destroi112
[DEV]
Status: Offline
(since 12-03-2020 22:13)
Joined: 24 May 2014
Posts: 4042
,
Topics: 119
Location:
---------
Reputation:
515.9
Votes
: 118
Posted: 03-02-2015, 12:44:23
| Translate post to:
... (
Click for more languages
)
Ti l-am pus pe F ,intrebare vrei sa se salveze toti vip-i intr-un fisier ??Nu am inteles...
Spoiler:
#include <amxmodx>
#include <engine>
#define PLUGIN "Show Admins Online"
#define VERSION "1.1"
#define AUTHOR "IceCreamCandy"
#define VIP_ACCESS ADMIN_MAP
new bool:g_bAdminNick
new bool:is_admin_connected[33]
new g_msg[512]
new g_admin_enable
new g_online_color
new g_msg_xypos
new g_SyncAdmin
new g_iAdminCount
new g_iMaxPlayers
new g_ClassName[] = "admin_msg"
public plugin_init()
{
register_plugin( PLUGIN, VERSION, AUTHOR )
register_think(g_ClassName,"ForwardThink")
g_admin_enable = register_cvar("sa_plugin_on","1")
g_online_color = register_cvar("sa_online_color","0 130 0")
g_msg_xypos = register_cvar("sa_msg_xypos","0.02 0.2")
g_SyncAdmin = CreateHudSyncObj()
g_iMaxPlayers = get_maxplayers()
new iEnt = create_entity("info_target")
entity_set_string(iEnt, EV_SZ_classname, g_ClassName)
entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 2.0)
}
public client_putinserver(id)
{
if(is_user_vip(id))
{
is_admin_connected[id] = true
g_iAdminCount++
set_admin_msg()
}
if(g_iAdminCount == 0)
set_admin_msg()
}
bool:is_user_vip(id)
{
if(id < 0 || id > 32)
return false
if( !(get_user_flags(id) & VIP_ACCESS ) )
return false
return true
}
public client_disconnect(id)
{
if(is_admin_connected[id])
{
is_admin_connected[id] = false
g_iAdminCount--
set_admin_msg()
}
}
public client_infochanged(id)
{
if(is_admin_connected[id])
{
static NewName[32], OldName[32]
get_user_info(id, "name", NewName, 31)
get_user_name(id, OldName, 31)
if(!equal(OldName, NewName))
{
g_bAdminNick = true
}
}
}
public set_admin_msg()
{
static g_iAdminName[32], pos, i
pos = 0
pos += formatex(g_msg[pos], 511-pos, "Gold Members: %d", g_iAdminCount)
for(i = 1 ; i <= g_iMaxPlayers ; i++)
{
if(is_admin_connected[i])
{
get_user_name(i, g_iAdminName, 31)
pos += formatex(g_msg[pos], 511-pos, "^n%s", g_iAdminName)
}
}
}
public admins_online()
{
if(get_pcvar_num(g_admin_enable))
{
static r, g, b, Float:x,Float:y
HudMsgPos(x,y)
if (g_iAdminCount > 0)
{
HudMsgColor(g_online_color, r, g, b)
set_hudmessage(r, g, b, x, y, _, _, 4.0, _, _, 4)
ShowSyncHudMsg(0, g_SyncAdmin, "%s", g_msg)
}
}
return PLUGIN_HANDLED
}
public ForwardThink(iEnt)
{
admins_online()
if(g_bAdminNick)
{
set_admin_msg()
g_bAdminNick = false
}
entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 2.0)
}
public HudMsgColor(cvar, &r, &g, &b)
{
static color[16], piece[5]
get_pcvar_string(cvar, color, 15)
strbreak( color, piece, 4, color, 15)
r = str_to_num(piece)
strbreak( color, piece, 4, color, 15)
g = str_to_num(piece)
b = str_to_num(color)
}
public HudMsgPos(&Float:x, &Float:y)
{
static coords[16], piece[10]
get_pcvar_string(g_msg_xypos, coords, 15)
strbreak(coords, piece, 9, coords, 15)
x = str_to_float(piece)
y = str_to_float(coords)
}
Retired from Amxmodx
0
0
Back to top
QuIzZ
[Banned user]
Status: Offline
(since 03-02-2015 21:28)
Joined: 03 Jan 2015
Posts: 101
,
Topics: 20
Location:
Romania
Reputation:
24.2
Votes
: 9
Posted: 03-02-2015, 12:56:00
| Translate post to:
... (
Click for more languages
)
Gold memeberul doar arata pe ecran membrii gold.
Vipul le da membrilor gold glonte infinite,armura etc.
in vips.ini eu vreau sa trec si flagul de la pluginul gold members,adica flagul F.
Flagul de la goldmembers inainte trebuia sa-l trec in users.ini.
Da,vreau ca vipii sa-i trec in vips.ini.
0
0
Back to top
destroi112
[DEV]
Status: Offline
(since 12-03-2020 22:13)
Joined: 24 May 2014
Posts: 4042
,
Topics: 119
Location:
---------
Reputation:
515.9
Votes
: 118
Posted: 03-02-2015, 13:03:48
| Translate post to:
... (
Click for more languages
)
QuIzZ wrote:
Gold memeberul doar arata pe ecran membrii gold.
Vipul le da membrilor gold glonte infinite,armura etc.
in vips.ini eu vreau sa trec si flagul de la pluginul gold members,adica flagul F.
Flagul de la goldmembers inainte trebuia sa-l trec in users.ini.
Da,vreau ca vipii sa-i trec in vips.ini.
Adica tu vrei sa iti citeasca din vips.ini numele playerilor ca si cum l-ar citi din user.ini? sau vrei sa ii salveze acolo automat..?
Retired from Amxmodx
0
0
Back to top
GoguSM
[.: ZMGO.FREAKZ.RO :.]
Status: Offline
(since 16-03-2022 00:38)
Joined: 24 Aug 2013
Posts: 1516
,
Topics: 71
Location:
Brasov
Reputation:
1144
Votes
: 95
Posted: 03-02-2015, 13:09:24
| Translate post to:
... (
Click for more languages
)
Destroi, el vrea sa citeasca dupa flagul din goldmember.
Uite asa
Spoiler:
#include <amxmodx>
#include <engine>
#include <zmvip>
#define PLUGIN "Show Admins Online"
#define VERSION "1.1"
#define AUTHOR "vato loco [GE-S] & Alka & Cristi. C"
new bool:g_bAdminNick
new bool:is_admin_connected[33]
new g_msg[512]
new g_admin_enable
new g_online_color
new g_offline_color
new g_msg_xypos
new g_SyncAdmin
new g_iAdminCount
new g_iMaxPlayers
new g_ClassName[] = "admin_msg"
public plugin_init()
{
register_plugin( PLUGIN, VERSION, AUTHOR )
register_think(g_ClassName,"ForwardThink")
g_admin_enable = register_cvar("sa_plugin_on","1")
g_online_color = register_cvar("sa_online_color","0 130 0")
g_offline_color = register_cvar("sa_offline_color","255 0 0")
g_msg_xypos = register_cvar("sa_msg_xypos","0.02 0.2")
g_SyncAdmin = CreateHudSyncObj()
g_iMaxPlayers = get_maxplayers()
new iEnt = create_entity("info_target")
entity_set_string(iEnt, EV_SZ_classname, g_ClassName)
entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 2.0)
}
public client_putinserver(id)
{
if(zv_get_user_flags(id) & ZV_UNLIMITED)
{
is_admin_connected[id] = true
g_iAdminCount++
set_admin_msg()
}
if(g_iAdminCount == 0)
set_admin_msg()
}
public client_disconnect(id)
{
if(is_admin_connected[id])
{
is_admin_connected[id] = false
g_iAdminCount--
set_admin_msg()
}
}
public client_infochanged(id)
{
if(is_admin_connected[id])
{
static NewName[32], OldName[32]
get_user_info(id, "name", NewName, 31)
get_user_name(id, OldName, 31)
if(!equal(OldName, NewName))
{
g_bAdminNick = true
}
}
}
public set_admin_msg()
{
static g_iAdminName[32], pos, i
pos = 0
pos += formatex(g_msg[pos], 511-pos, "Gold Members: %d", g_iAdminCount)
for(i = 1 ; i <= g_iMaxPlayers ; i++)
{
if(is_admin_connected[i])
{
get_user_name(i, g_iAdminName, 31)
pos += formatex(g_msg[pos], 511-pos, "^n%s", g_iAdminName)
}
}
}
public admins_online()
{
if(get_pcvar_num(g_admin_enable))
{
static r, g, b, Float:x,Float:y
HudMsgPos(x,y)
if (g_iAdminCount > 0)
{
HudMsgColor(g_online_color, r, g, b)
set_hudmessage(r, g, b, x, y, _, _, 4.0, _, _, 4)
ShowSyncHudMsg(0, g_SyncAdmin, "%s", g_msg)
}
else
{
HudMsgColor(g_offline_color, r, g, b)
set_hudmessage(r, g, b, x, y, _, _, 4.0, _, _, 4)
ShowSyncHudMsg(0, g_SyncAdmin, "%s", g_msg)
}
}
return PLUGIN_HANDLED
}
public ForwardThink(iEnt)
{
admins_online()
if(g_bAdminNick)
{
set_admin_msg()
g_bAdminNick = false
}
entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 2.0)
}
public HudMsgColor(cvar, &r, &g, &b)
{
static color[16], piece[5]
get_pcvar_string(cvar, color, 15)
strbreak( color, piece, 4, color, 15)
r = str_to_num(piece)
strbreak( color, piece, 4, color, 15)
g = str_to_num(piece)
b = str_to_num(color)
}
public HudMsgPos(&Float:x, &Float:y)
{
static coords[16], piece[10]
get_pcvar_string(g_msg_xypos, coords, 15)
strbreak(coords, piece, 9, coords, 15)
x = str_to_float(piece)
y = str_to_float(coords)
}
Sa-mi Spui daca este bun, apar online doar cei trecuti in vips.ini, nu mai trb sa pui flag in user.ini.
0
0
Back to top
QuIzZ
[Banned user]
Status: Offline
(since 03-02-2015 21:28)
Joined: 03 Jan 2015
Posts: 101
,
Topics: 20
Location:
Romania
Reputation:
24.2
Votes
: 9
Posted: 03-02-2015, 13:38:26
| Translate post to:
... (
Click for more languages
)
Nu intelegeti nici unul ce vreau sa zic.
Vipera,ca sa-l compilez imi trebuie fisieru zmvip.inc si nu-l am si nici nu l-am gasit.
Cititi cu atentie ce zic
: Pluginul goldmembers pe care vi l-am pus mai sus arata pe ecran intr-ul hud,sub radar pe cei care au flagul T in users.ini
Eu vreau sa apara cei care au flagul F in vips.ini. ATAT !
0
0
Back to top
destroi112
[DEV]
Status: Offline
(since 12-03-2020 22:13)
Joined: 24 May 2014
Posts: 4042
,
Topics: 119
Location:
---------
Reputation:
515.9
Votes
: 118
Posted: 03-02-2015, 13:44:42
| Translate post to:
... (
Click for more languages
)
QuIzZ wrote:
Nu intelegeti nici unul ce vreau sa zic.
Vipera,ca sa-l compilez imi trebuie fisieru zmvip.inc si nu-l am si nici nu l-am gasit.
Cititi cu atentie ce zic
: Pluginul goldmembers pe care vi l-am pus mai sus arata pe ecran intr-ul hud,sub radar pe cei care au flagul T in users.ini
Eu vreau sa apara cei care au flagul F in vips.ini. ATAT !
Zi asa=]] vezi ti l-am facut mai sus chiar daca nu am intels incearca-l si spune-mi daca e cum vrei tu.
Retired from Amxmodx
0
0
Back to top
EDUTz
[HardcoreAmxxScripter]
Status: Offline
(since 15-08-2021 16:34)
Joined: 27 Dec 2010
Posts: 4306
,
Topics: 244
Location:
Jud. Miserupia, sat Bagadanc
Reputation:
4085
Votes
: 179
Posted: 03-02-2015, 13:46:24
| Translate post to:
... (
Click for more languages
)
QuIzZ wrote:
Am pluginul asta de Gold Members ,problema este ca pentru a baga pe cineva Gold Member trebuie sa ii trec in users.ini cu flagul t,daca un admin ia Gold Member eu trebuie sa modific si pluginul /admins si sa pun flagul t la gradul pe care il are adminul ca sa apara ca admin,ceea ce nu e bine deloc.
Pe langa asta am si pluginul zm_vip care creeaza in configs fisierul vips.ini in care sunt trecuti vipii .Eu as vrea ca pun Membrii Gold in vips.ini cu flagul F .
e ok acum
Spoiler:
Code:
#include <amxmodx>
#include <engine>
#define PLUGIN "Show Admins Online"
#define VERSION "1.1"
#define AUTHOR "IceCreamCandy"
new bool:g_bAdminNick
new bool:is_admin_connected[33]
new g_msg[512]
new g_admin_enable
new g_online_color
new g_msg_xypos
new g_SyncAdmin
new g_iAdminCount
new g_iMaxPlayers
new g_ClassName[] = "admin_msg"
public plugin_init()
{
register_plugin( PLUGIN, VERSION, AUTHOR )
register_think(g_ClassName,"ForwardThink")
g_admin_enable = register_cvar("sa_plugin_on","1")
g_online_color = register_cvar("sa_online_color","0 130 0")
g_msg_xypos = register_cvar("sa_msg_xypos","0.02 0.2")
g_SyncAdmin = CreateHudSyncObj()
g_iMaxPlayers = get_maxplayers()
new iEnt = create_entity("info_target")
entity_set_string(iEnt, EV_SZ_classname, g_ClassName)
entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 2.0)
}
public client_putinserver(id)
{
if(get_user_flags(id) & ADMIN_MAP)
{
is_admin_connected[id] = true
g_iAdminCount++
set_admin_msg()
}
if(g_iAdminCount == 0)
set_admin_msg()
}
public client_disconnect(id)
{
if(is_admin_connected[id])
{
is_admin_connected[id] = false
g_iAdminCount--
set_admin_msg()
}
}
public client_infochanged(id)
{
if(is_admin_connected[id])
{
static NewName[32], OldName[32]
get_user_info(id, "name", NewName, 31)
get_user_name(id, OldName, 31)
if(!equal(OldName, NewName))
{
g_bAdminNick = true
}
}
}
public set_admin_msg()
{
static g_iAdminName[32], pos, i
pos = 0
pos += formatex(g_msg[pos], 511-pos, "Gold Members: %d", g_iAdminCount)
for(i = 1 ; i <= g_iMaxPlayers ; i++)
{
if(is_admin_connected[i])
{
get_user_name(i, g_iAdminName, 31)
pos += formatex(g_msg[pos], 511-pos, "^n%s", g_iAdminName)
}
}
}
public admins_online()
{
if(get_pcvar_num(g_admin_enable))
{
static r, g, b, Float:x,Float:y
HudMsgPos(x,y)
if (g_iAdminCount > 0)
{
HudMsgColor(g_online_color, r, g, b)
set_hudmessage(r, g, b, x, y, _, _, 4.0, _, _, 4)
ShowSyncHudMsg(0, g_SyncAdmin, "%s", g_msg)
}
}
return PLUGIN_HANDLED
}
public ForwardThink(iEnt)
{
admins_online()
if(g_bAdminNick)
{
set_admin_msg()
g_bAdminNick = false
}
entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 2.0)
}
public HudMsgColor(cvar, &r, &g, &b)
{
static color[16], piece[5]
get_pcvar_string(cvar, color, 15)
strbreak( color, piece, 4, color, 15)
r = str_to_num(piece)
strbreak( color, piece, 4, color, 15)
g = str_to_num(piece)
b = str_to_num(color)
}
public HudMsgPos(&Float:x, &Float:y)
{
static coords[16], piece[10]
get_pcvar_string(g_msg_xypos, coords, 15)
strbreak(coords, piece, 9, coords, 15)
x = str_to_float(piece)
y = str_to_float(coords)
}
vezi ca si destroi iti facuse acelasi lucru, tu testezi ce-ti dam noi sau ne tii de vorba ?
Pentru pluginuri complicate le fac cu $$ pe paypal/psc. PM
0
0
Back to top
Topic locked
Topic is closed, you cannot post any messages in it anymore
Locked by
EDUTz
, 03 February 2015 11:46
Freakz Forum Index
->
Trash Bin
->
CS 2006-2019 (Archived)
->
Plugins - Help / Support
The time now is 04-12-2024, 23:25:00
Copyright info
Based on phpBB
ro
/
com
B
Login
I forgot my password
World of Warcraft
Login for more...
Download WoW 7.3.5
Misc
eSports
Achievements
Buy reputation with votes
Reputation trades
Forum rules
Ban list
Members list
User guide (FAQ)
World of Warcraft
View details