- Initiateur de la discussion
L
LaCriMoZ
Geek
- Messages
- 49
- Score réaction
- 1
- Points
- 90
POUR INFO SE N'EST PAS MOI QUI L'AI CREE !!!
Bonjour/Bonsoir
Je vous montre rapidement se que j'ai trouver sur INTERNET. Tous ceci est du PHP.
J'aimerais savoir lequel de ses 2 scripts est le bon et dans qu'elle dossier du ftp je doit mettre ceci.
--------------------------------------------------------------------------------------------------------------------------------
#include <amxmodx>
#include <amxmisc>
#define MAX_GROUPS 10
new g_groupNames[MAX_GROUPS][] = {
"[1]-- DetinatoR --",
"[2]-- OwneR --",
"[3]-- Co-OwneR --",
"[4]-- MaresaL --",
"[5]-- GeneraL --",
"[6]-- ColoneL --",
"[7]-- MaioR --",
"[8]-- SergenT --",
"[9]-- Slot --",
"[10]-- V.I.P --"
}
new g_groupFlags[MAX_GROUPS][] = {
"abcdefghijklmnopqrstu",
"abcdefghijklmnopqrsu",
"abcdefghijmnopqrsu",
"abcdefghijmnopqrs",
"bcdefgijmnpqr",
"bcdefgijmnp",
"bcdefgijmn",
"bcefijmn",
"b",
"bit"
}
new g_groupFlagsValue[MAX_GROUPS]
public plugin_init() {
register_plugin("AMX WHO -by Assassination", "1.3", "by Assassination")
register_concmd("admin_who", "cmdWho", 0)
register_concmd("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, "..::: Staff of server :::..")
for(i = 0; i < MAX_GROUPS; i++) {
console_print(id, "%s", 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, "....:::: Staff of server ::::....")
return PLUGIN_HANDLED
}
--------------------------------------------------------------------------------------------------------------------------------
OU
function insertChatTags(ply, msg)
if ply:IsValid() then
local ply_team = ply:Team()
local team_name = team.GetName( ply_team )
--local h,s,v = ColorToHSV( team.GetColor( ply_team ) )
--local comp_col = HSVToColor( 180-h, s, v )
--PHX-Server specifics
if ( team_name == "Leader Builder" ) then
comp_col = Color(55,126,206)
elseif ( team_name == "Admin Builder" ) then
comp_col = Color(79,115,158)
elseif ( team_name == "Wullys Builder" ) then
comp_col = Color(0,178,255)
elseif ( team_name == "Ultimate Builder" ) then
comp_col = Color(121,0,221)
elseif ( team_name == "Precision Builder" ) then
comp_col = Color(0,147,12)
elseif ( team_name == "Loyal Builder" ) then
comp_col = Color(173,0,23)
elseif ( team_name == "Creative Builder" ) then
comp_col = Color(0,13,132)
elseif ( team_name == "Novice Builder" ) then
comp_col = Color(255,242,0)
elseif ( team_name == "Bronze Builder" ) then
comp_col = Color(135,81,0)
elseif ( team_name == "Silver Builder" ) then
comp_col = Color(135,135,135)
elseif ( team_name == "Gold Builder" ) then
comp_col = Color(237,197,0)
elseif ( team_name == "Respected" ) then
comp_col = Color(169,186,198)
elseif ( team_name == "user" ) then
comp_col = Color(100,100,100)
team_name = "New Builder"
else
comp_col = Color(255, 255, 255)
end
chat.AddText( team.GetColor( ply_team ), "[",comp_col, team_name,team.GetColor( ply_team ), "] ", ply:GetName(), color_white, ": ", msg )
return true
end
end
hook.Add( "OnPlayerChat", "ulx_chattags", insertChatTags )
--------------------------------------------------------------------------------------------------------------------------------
Merci d'avoir lu.
Cordialement LaCriMoZ
Bonjour/Bonsoir
Je vous montre rapidement se que j'ai trouver sur INTERNET. Tous ceci est du PHP.
J'aimerais savoir lequel de ses 2 scripts est le bon et dans qu'elle dossier du ftp je doit mettre ceci.
--------------------------------------------------------------------------------------------------------------------------------
#include <amxmodx>
#include <amxmisc>
#define MAX_GROUPS 10
new g_groupNames[MAX_GROUPS][] = {
"[1]-- DetinatoR --",
"[2]-- OwneR --",
"[3]-- Co-OwneR --",
"[4]-- MaresaL --",
"[5]-- GeneraL --",
"[6]-- ColoneL --",
"[7]-- MaioR --",
"[8]-- SergenT --",
"[9]-- Slot --",
"[10]-- V.I.P --"
}
new g_groupFlags[MAX_GROUPS][] = {
"abcdefghijklmnopqrstu",
"abcdefghijklmnopqrsu",
"abcdefghijmnopqrsu",
"abcdefghijmnopqrs",
"bcdefgijmnpqr",
"bcdefgijmnp",
"bcdefgijmn",
"bcefijmn",
"b",
"bit"
}
new g_groupFlagsValue[MAX_GROUPS]
public plugin_init() {
register_plugin("AMX WHO -by Assassination", "1.3", "by Assassination")
register_concmd("admin_who", "cmdWho", 0)
register_concmd("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, "..::: Staff of server :::..")
for(i = 0; i < MAX_GROUPS; i++) {
console_print(id, "%s", 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, "....:::: Staff of server ::::....")
return PLUGIN_HANDLED
}
--------------------------------------------------------------------------------------------------------------------------------
OU
function insertChatTags(ply, msg)
if ply:IsValid() then
local ply_team = ply:Team()
local team_name = team.GetName( ply_team )
--local h,s,v = ColorToHSV( team.GetColor( ply_team ) )
--local comp_col = HSVToColor( 180-h, s, v )
--PHX-Server specifics
if ( team_name == "Leader Builder" ) then
comp_col = Color(55,126,206)
elseif ( team_name == "Admin Builder" ) then
comp_col = Color(79,115,158)
elseif ( team_name == "Wullys Builder" ) then
comp_col = Color(0,178,255)
elseif ( team_name == "Ultimate Builder" ) then
comp_col = Color(121,0,221)
elseif ( team_name == "Precision Builder" ) then
comp_col = Color(0,147,12)
elseif ( team_name == "Loyal Builder" ) then
comp_col = Color(173,0,23)
elseif ( team_name == "Creative Builder" ) then
comp_col = Color(0,13,132)
elseif ( team_name == "Novice Builder" ) then
comp_col = Color(255,242,0)
elseif ( team_name == "Bronze Builder" ) then
comp_col = Color(135,81,0)
elseif ( team_name == "Silver Builder" ) then
comp_col = Color(135,135,135)
elseif ( team_name == "Gold Builder" ) then
comp_col = Color(237,197,0)
elseif ( team_name == "Respected" ) then
comp_col = Color(169,186,198)
elseif ( team_name == "user" ) then
comp_col = Color(100,100,100)
team_name = "New Builder"
else
comp_col = Color(255, 255, 255)
end
chat.AddText( team.GetColor( ply_team ), "[",comp_col, team_name,team.GetColor( ply_team ), "] ", ply:GetName(), color_white, ": ", msg )
return true
end
end
hook.Add( "OnPlayerChat", "ulx_chattags", insertChatTags )
--------------------------------------------------------------------------------------------------------------------------------
Merci d'avoir lu.
Cordialement LaCriMoZ