Jump to content

ممكن احد يجاوب على الكود ؟؟


Recommended Posts

سلآم عليكم #

ممكن احد يقول لي ليش موراضي يغير الباسوورد ؟ :|:|

مع العلم ان

getPassword = الباسورد ( سترنق )

getitem = اسم الاعب انا جالبه مع الترايقر من القريد لست

  
-- # Server Side 
addEvent( 'setAccPassword', true ) 
addEventHandler( 'setAccPassword', root, 
function( getitem, getPassword ) 
local playerSource = getPlayerFromName(getitem) 
local playerAccount = getAccountName(getPlayerAccount(playerSource)) 
if ( not playerAccount or isGuestAccount(playerAccount) ) then 
return end 
setAccountPassword ( playerAccount, getPassword ) 
end 
) 

اللي يحلها يقول لي وين الخطأ وليش حط الشي اللي رح يغيره ّ

:wink:

Edited by Guest
Link to comment
  
  
  
-- # Server Side 
addEvent( 'setAccPassword', true ) 
addEventHandler( 'setAccPassword', root, 
function( getitem, getPassword ) 
local playerSource = getPlayerFromName(getitem) 
local player = getAccountPlayer(getAccount(accName)) 
if ( not playerAccount or isGuestAccount(playerAccount) ) then 
return end 
setAccountPassword ( playerAccount, getPassword ) 
end 
) 
  
  

جرب

Link to comment
  
  
  
-- # Server Side 
addEvent( 'setAccPassword', true ) 
addEventHandler( 'setAccPassword', root, 
function( getitem, getPassword ) 
local playerSource = getPlayerFromName(getitem) 
local player = getAccountPlayer(getAccount(accName)) 
if ( not playerAccount or isGuestAccount(playerAccount) ) then 
return end 
setAccountPassword ( playerAccount, getPassword ) 
end 
) 
  
  

جرب

هريس

addEvent( 'setAccPassword', true ) 
  
addEventHandler( 'setAccPassword', root, 
  
function( getitem , getPassword ) 
  
playerSource = getPlayerFromName( getitem ) 
  
if playerSource then 
  
playerAccount = getPlayerAccount ( playerSource  ) 
  
if ( isGuestAccount ( playerAccount ) ) then return end 
  
setAccountPassword ( playerAccount, getPassword ) 
  
    end 
end 
    ) ; 

مجربه وشغال , ماشتغل اطرح اكوادك كاملة

Link to comment
  
  
  
-- # Server Side 
addEvent( 'setAccPassword', true ) 
addEventHandler( 'setAccPassword', root, 
function( getitem, getPassword ) 
local playerSource = getPlayerFromName(getitem) 
local player = getAccountPlayer(getAccount(accName)) 
if ( not playerAccount or isGuestAccount(playerAccount) ) then 
return end 
setAccountPassword ( playerAccount, getPassword ) 
end 
) 
  
  
  
  

جرب

عدلته وضبط ^^

Link to comment
  
  
  
-- # Server Side 
addEvent( 'setAccPassword', true ) 
addEventHandler( 'setAccPassword', root, 
function( getitem, getPassword ) 
local playerSource = getPlayerFromName(getitem) 
local player = getAccountPlayer(getAccount(accName)) 
if ( not playerAccount or isGuestAccount(playerAccount) ) then 
return end 
setAccountPassword ( playerAccount, getPassword ) 
end 
) 
  
  
  
  

جرب

عدلته وضبط ^^

شغال يعني ؟

اي حاجة تاني ؟

Link to comment
  
  
  
-- # Server Side 
addEvent( 'setAccPassword', true ) 
addEventHandler( 'setAccPassword', root, 
function( getitem, getPassword ) 
local playerSource = getPlayerFromName(getitem) 
local player = getAccountPlayer(getAccount(accName)) 
if ( not playerAccount or isGuestAccount(playerAccount) ) then 
return end 
setAccountPassword ( playerAccount, getPassword ) 
end 
) 
  
  
  
  

جرب

عدلته وضبط ^^

شغال يعني ؟

اي حاجة تاني ؟

الحين مايجي اي خطأ والباسوورد مايتغير :|:roll:

Link to comment

جرب

addEvent( 'setAccPassword', true ) 
  
addEventHandler( 'setAccPassword', root, 
  
function( getitem , getPassword ) 
  
playerSource = getPlayerFromName( getitem ) 
  
if playerSource then 
  
playerAccount = getPlayerAccount ( playerSource  ) 
  
if ( isGuestAccount ( playerAccount ) ) then return end 
  
setAccountPassword ( playerAccount, getPassword ) 
  
    end 
end 
    ) ; 

مجربه وشغال , ماشتغل اطرح اكوادك كاملة

Link to comment

جرب

addEvent( 'setAccPassword', true ) 
  
addEventHandler( 'setAccPassword', root, 
  
function( getitem , getPassword ) 
  
playerSource = getPlayerFromName( getitem ) 
  
if playerSource then 
  
playerAccount = getPlayerAccount ( playerSource  ) 
  
if ( isGuestAccount ( playerAccount ) ) then return end 
  
setAccountPassword ( playerAccount, getPassword ) 
  
    end 
end 
    ) ; 

مجربه وشغال , ماشتغل اطرح اكوادك كاملة

نفس الشي

مايغير الباسوورد ومايطلع اي شي بالديبوق

addEvent( 'setAccPassword', true ) 
addEventHandler( 'setAccPassword', root, 
function( getitem , getPassword ) 
playerSource = getPlayerFromName( getitem ) 
if playerSource then 
playerAccount = getPlayerAccount ( playerSource  ) 
setAccountPassword ( playerAccount, getPassword ) 
outputChatBox( '#Password set to : ' ..getPassword.. "", source, 0, 255, 0) 
end 
end 
) 

Link to comment
ترا مجربه وشغال , اطرح اكوادك كاملة كلينت وسيرفر ><

# Client :

open = {} 
Close = {
    Button = {}
}
Spectator = {
    Note = {}
}
RemoveAcc = {
    Button = {},
    Note = {}
}
Line2 = {
    Label = {}
}
Management = {}
Line = {
    Label = {}
}
PlayerSerial = {
    Note = {}
}
SetPassword = {
    Note = {}
}
ChangePassword = {
    Button = {}
}
PlayerAccount = {
    Note = {}
}
Players = {
    Grid = {}
}
PlayerMoney = {
    Note = {}
}
AccManage = {
    Label = {}
}
Money = {
    Label = {}
}
Kick = {
    Button = {},
    Note = {}
}
Slap = {
    Button = {},
    Note = {}
}
Spying = {
    Button = {}
}
Password = {
    Edit = {}
}
Ping = {
    Label = {}
}
Statur = {
    Label = {}
}
Search = {
    Edit = {},
    Image = {}
}
AdminManage = {
    Label = {}
}
PlayerPing = {
    Note = {}
}
Serial = {
    Label = {}
}
Account = {
    Label = {}
}
Management.Window = guiCreateWindow(0.25, 0.20, 0.50, 0.60, "#-| Management System |-#", true)
guiWindowSetSizable(Management.Window, false)
guiSetAlpha(Management.Window, 1.00)
guiSetVisible(Management.Window, false)
Players.Grid.Window = guiCreateGridList(0.01, 0.11, 0.30, 0.86, true, Management.Window)
guiGridListSetSelectionMode ( Players.Grid.Window, 0 )
guiGridListAddColumn(Players.Grid.Window, "# Players ...", 0.9)
Search.Edit.Window = guiCreateEdit(0.01, 0.06, 0.26, 0.04, "Search ...", true, Management.Window)
Search.Image.Window = guiCreateStaticImage(193, 27, 22, 18, ":admin/client/images/search.png", false, Management.Window)
guiSetProperty(Search.Image.Window, "ImageColours", "tl:FF22F500 tr:FF22F500 bl:FF22F500 br:FF22F500")
PlayerSerial.Note.Window = guiCreateLabel(0.32, 0.11, 0.13, 0.05, "* Player Serial :", true, Management.Window)
guiSetFont(PlayerSerial.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerSerial.Note.Window, 0, 224, 245)
guiLabelSetVerticalAlign(PlayerSerial.Note.Window, "center")
Serial.Label.Window = guiCreateLabel(0.45, 0.11, 0.53, 0.05, "", true, Management.Window)
guiSetFont(Serial.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Serial.Label.Window, "center")
PlayerAccount.Note.Window = guiCreateLabel(0.32, 0.16, 0.15, 0.05, "* Player Account :", true, Management.Window)
guiSetFont(PlayerAccount.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerAccount.Note.Window, 255, 23, 203)
guiLabelSetVerticalAlign(PlayerAccount.Note.Window, "center")
Account.Label.Window = guiCreateLabel(0.48, 0.16, 0.51, 0.05, "", true, Management.Window)
guiSetFont(Account.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Account.Label.Window, "center")
PlayerMoney.Note.Window = guiCreateLabel(0.32, 0.22, 0.14, 0.05, "* Player Money :", true, Management.Window)
guiSetFont(PlayerMoney.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerMoney.Note.Window, 246, 254, 23)
guiLabelSetVerticalAlign(PlayerMoney.Note.Window, "center")
Money.Label.Window = guiCreateLabel(0.46, 0.22, 0.52, 0.05, "", true, Management.Window)
guiSetFont(Money.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Money.Label.Window, "center")
PlayerPing.Note.Window = guiCreateLabel(0.32, 0.28, 0.12, 0.05, "* Player Ping :", true, Management.Window)
guiSetFont(PlayerPing.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerPing.Note.Window, 38, 254, 22)
guiLabelSetVerticalAlign(PlayerPing.Note.Window, "center")
Ping.Label.Window = guiCreateLabel(0.44, 0.28, 0.52, 0.05, "", true, Management.Window)
guiSetFont(Ping.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Ping.Label.Window, "center")
Statur.Label.Window = guiCreateLabel(0.32, 0.06, 0.13, 0.04, "#|* Status *|#", true, Management.Window)
guiSetFont(Statur.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Statur.Label.Window, "center")
AdminManage.Label.Window = guiCreateLabel(0.32, 0.38, 0.20, 0.05, "#|* Admin Manage *|#", true, Management.Window)
guiSetFont(AdminManage.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(AdminManage.Label.Window, "center")
Line.Label.Window = guiCreateLabel(0.32, 0.34, 0.67, 0.03, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", true, Management.Window)
guiSetFont(Line.Label.Window, "default-bold-small")
guiLabelSetColor(Line.Label.Window, 254, 21, 21)
guiLabelSetHorizontalAlign(Line.Label.Window, "center", false)
guiLabelSetVerticalAlign(Line.Label.Window, "center")
Spectator.Note.Window = guiCreateLabel(0.32, 0.45, 0.11, 0.05, "* Spectator :", true, Management.Window)
guiSetFont(Spectator.Note.Window, "default-bold-small")
guiLabelSetColor(Spectator.Note.Window, 254, 21, 21)
guiLabelSetVerticalAlign(Spectator.Note.Window, "center")
Spying.Button.Window = guiCreateButton(0.44, 0.45, 0.22, 0.05, "# Spying the player ~", true, Management.Window)
guiSetFont(Spying.Button.Window, "default-bold-small")
guiSetProperty(Spying.Button.Window, "NormalTextColour", "FFFF1D1D")
Kick.Note.Window = guiCreateLabel(0.32, 0.52, 0.12, 0.05, "* Kick player :", true, Management.Window)
guiSetFont(Kick.Note.Window, "default-bold-small")
guiLabelSetColor(Kick.Note.Window, 61, 255, 29)
guiLabelSetVerticalAlign(Kick.Note.Window, "center")
Kick.Button.Window = guiCreateButton(0.44, 0.52, 0.22, 0.05, "# Kick the player ~", true, Management.Window)
guiSetFont(Kick.Button.Window, "default-bold-small")
guiSetProperty(Kick.Button.Window, "NormalTextColour", "FFFFFFFF")
Slap.Note.Window = guiCreateLabel(0.32, 0.59, 0.12, 0.05, "* Slap player :", true, Management.Window)
guiSetFont(Slap.Note.Window, "default-bold-small")
guiLabelSetColor(Slap.Note.Window, 5, 46, 255)
guiLabelSetVerticalAlign(Slap.Note.Window, "center")
Slap.Button.Window = guiCreateButton(0.44, 0.59, 0.22, 0.05, "# Slap the player ~", true, Management.Window)
guiSetFont(Slap.Button.Window, "default-bold-small")
guiSetProperty(Slap.Button.Window, "NormalTextColour", "FFFFFFFF")
Line2.Label.Window = guiCreateLabel(0.32, 0.65, 0.67, 0.03, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", true, Management.Window)
guiSetFont(Line2.Label.Window, "default-bold-small")
guiLabelSetColor(Line2.Label.Window, 254, 21, 21)
guiLabelSetHorizontalAlign(Line2.Label.Window, "center", false)
guiLabelSetVerticalAlign(Line2.Label.Window, "center")
AccManage.Label.Window = guiCreateLabel(0.32, 0.69, 0.23, 0.05, "#|* Account Manange *|#", true, Management.Window)
guiSetFont(AccManage.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(AccManage.Label.Window, "center")
SetPassword.Note.Window = guiCreateLabel(0.32, 0.75, 0.21, 0.04, "* Set Account Password :", true, Management.Window)
guiSetFont(SetPassword.Note.Window, "default-bold-small")
guiLabelSetColor(SetPassword.Note.Window, 4, 252, 255)
guiLabelSetVerticalAlign(SetPassword.Note.Window, "center")
Password.Edit.Window = guiCreateEdit(0.54, 0.75, 0.26, 0.04, "Password ...", true, Management.Window)
ChangePassword.Button.Window = guiCreateButton(0.80, 0.75, 0.18, 0.04, "# Change ~", true, Management.Window)
guiSetFont(ChangePassword.Button.Window, "default-bold-small")
guiSetProperty(ChangePassword.Button.Window, "NormalTextColour", "FFFFFFFF")
RemoveAcc.Note.Window = guiCreateLabel(0.32, 0.80, 0.23, 0.04, "* Remove Player Account :", true, Management.Window)
guiSetFont(RemoveAcc.Note.Window, "default-bold-small")
guiLabelSetColor(RemoveAcc.Note.Window, 4, 252, 255)
guiLabelSetVerticalAlign(RemoveAcc.Note.Window, "center")
RemoveAcc.Button.Window = guiCreateButton(0.56, 0.80, 0.18, 0.04, "# Remove ~", true, Management.Window)
guiSetFont(RemoveAcc.Button.Window, "default-bold-small")
guiSetProperty(RemoveAcc.Button.Window, "NormalTextColour", "FFFFFFFF")
Close.Button.Window = guiCreateButton(0.91, 0.94, 0.07, 0.04, "X", true, Management.Window)
guiSetFont(Close.Button.Window, "default-bold-small")
guiSetProperty(Close.Button.Window, "NormalTextColour", "FFFF0303")
 
addEventHandler("onClientGUIChanged",root,
    function ()
        if ( source == Search.Edit.Window ) then
            local text = string.upper(guiGetText(Search.Edit.Window))
            if ( text == "" ) then
                addPlayers()    
            else
                guiGridListClear(Players.Grid.Window)
                for i,v in ipairs(getElementsByType("player")) do
                    local name = string.upper(getPlayerName(v))
                    if string.find(name,text) then
                        local row = guiGridListAddRow(Players.Grid.Window)
                        guiGridListSetItemText(Players.Grid.Window,row,1,getPlayerName(v),false,false)
                        else
                    end
                end
            end
        end
    end
)
 
addEvent( 'putINFO', true )
addEventHandler( 'putINFO', root,
function( playerAccount, playerSerial, playerMoney, playerPing )
guiSetText(Serial.Label.Window, playerSerial)
guiSetText(Account.Label.Window, playerAccount)
guiSetText(Money.Label.Window, playerMoney)
guiSetText(Ping.Label.Window, playerPing)
end
)
 
function addPlayers()
guiGridListClear(Players.Grid.Window)
for i, player in ipairs(getElementsByType('player')) do
local itemPlayer = guiGridListAddRow(Players.Grid.Window)
local itemText = guiGridListSetItemText(Players.Grid.Window, itemPlayer, 1, getPlayerName(player), false, false)
end
end
addEventHandler('onClientPlayerJoin', root, addPlayers)
addEventHandler('onClientPlayerQuit', root, addPlayers)
addEventHandler('onClientPlayerChangeNick', root, addPlayers)
addPlayers()
 
function open()
if ( guiGetVisible(Management.Window) == false ) then
guiSetVisible(Management.Window, true)
showCursor(true)
else
guiSetVisible(Management.Window, false)
showCursor(false)
end
end
bindKey ("F5", "down", open)
 
addEventHandler( 'onClientGUIClick', root,
function()
if (source == Close.Button.Window) then
guiSetVisible(Management.Window, false)
showCursor(false)
elseif (source == Search.Edit.Window) and (guiGetText(Search.Edit.Window) == "Search ...") then
guiSetText(Search.Edit.Window, "")
elseif (source == Password.Edit.Window) and (guiGetText(Password.Edit.Window) == "Password ...") then
guiSetText(Password.Edit.Window, "")
elseif (source == Players.Grid.Window) then
local getitem = guiGridListGetItemText( Players.Grid.Window, guiGridListGetSelectedItem(Players.Grid.Window), 1 )
local playerSource = getPlayerFromName(getitem)
if (not playerSource) then
return
end
triggerServerEvent( 'getInformation', localPlayer, getitem )
elseif (source == Spying.Button.Window) then
local getitem = guiGridListGetItemText( Players.Grid.Window, guiGridListGetSelectedItem(Players.Grid.Window), 1 )
local playerSource = getPlayerFromName(getitem)
if (not playerSource) then
return
end
Link to comment

--[[ 
changeGridListItemToPlayersName = function ( GridList, Column )
    if GridList and Column then -- Check Parematers
        if getElementType ( GridList ) == "gui-gridlist" then -- Check The Type of ' GridList '
            if guiGridListClear ( GridList ) then -- Clear GridList
                for i, v in next, getElementsByType ( "player" ) do -- Get Everything by Type ' player '
                    local Row = guiGridListAddRow ( GridList ) -- Add Row
                    guiGridListSetItemText ( GridList, Row, Column, getPlayerName ( v ), false, false ); -- Set New Values
                end; -- end of ' for '
            end; -- end of ' clear gridlist '
        end; -- end of ' check gridlist type '
    end; -- end of ' check parematers
end; -- end of ' function '
 
GUIEditor = {
    gridlist = {},
    window = {},
    button = {},
    edit = {}
}
 
        GUIEditor.window[1] = guiCreateWindow(209, 140, 393, 361, "", false)
        guiWindowSetSizable(GUIEditor.window[1], false)
        guiSetVisible ( GUIEditor.window[1], false )
        GUIEditor.gridlist[1] = guiCreateGridList(17, 31, 362, 238, false, GUIEditor.window[1])
       col = guiGridListAddColumn(GUIEditor.gridlist[1], "players", 0.9)
        GUIEditor.edit[1] = guiCreateEdit(18, 285, 361, 24, "", false, GUIEditor.window[1])
        GUIEditor.button[1] = guiCreateButton(123, 319, 136, 24, "", false, GUIEditor.window[1])
        guiSetProperty(GUIEditor.button[1], "NormalTextColour", "FFAAAAAA")    
changeGridListItemToPlayersName ( GUIEditor.gridlist[1], col )
bindKey("F5","down",function() guiSetVisible ( GUIEditor.window[1] , not guiGetVisible ( GUIEditor.window[1] ) ) showCursor ( not isCursorShowing ( ) ) end )
       
addEventHandler("onClientGUIClick",root,
function ()
 
if source  == GUIEditor.button[1] then
 
if GUIEditor.edit[1] == "" then return end
 
    local row = guiGridListGetSelectedItem( GUIEditor.gridlist[1] )
   
    if row and row ~= -1 then   
 
    local Player = guiGridListGetItemText ( GUIEditor.gridlist[1] , row, 1 )
   
    triggerServerEvent ("setAccPassword", localPlayer , Player , guiGetText ( GUIEditor.edit[1] ) )
 
        end
    end
end
)
--]]
 
open = {}
Close = {
    Button = {}
}
Spectator = {
    Note = {}
}
RemoveAcc = {
    Button = {},
    Note = {}
}
Line2 = {
    Label = {}
}
Management = {}
Line = {
    Label = {}
}
PlayerSerial = {
    Note = {}
}
SetPassword = {
    Note = {}
}
ChangePassword = {
    Button = {}
}
PlayerAccount = {
    Note = {}
}
Players = {
    Grid = {}
}
PlayerMoney = {
    Note = {}
}
AccManage = {
    Label = {}
}
Money = {
    Label = {}
}
Kick = {
    Button = {},
    Note = {}
}
Slap = {
    Button = {},
    Note = {}
}
Spying = {
    Button = {}
}
Password = {
    Edit = {}
}
Ping = {
    Label = {}
}
Statur = {
    Label = {}
}
Search = {
    Edit = {},
    Image = {}
}
AdminManage = {
    Label = {}
}
PlayerPing = {
    Note = {}
}
Serial = {
    Label = {}
}
Account = {
    Label = {}
}
Management.Window = guiCreateWindow(0.25, 0.20, 0.50, 0.60, "#-| Management System |-#", true)
guiWindowSetSizable(Management.Window, false)
guiSetAlpha(Management.Window, 1.00)
guiSetVisible(Management.Window, false)
Players.Grid.Window = guiCreateGridList(0.01, 0.11, 0.30, 0.86, true, Management.Window)
guiGridListSetSelectionMode ( Players.Grid.Window, 0 )
guiGridListAddColumn(Players.Grid.Window, "# Players ...", 0.9)
Search.Edit.Window = guiCreateEdit(0.01, 0.06, 0.26, 0.04, "Search ...", true, Management.Window)
Search.Image.Window = guiCreateStaticImage(193, 27, 22, 18, ":admin/client/images/search.png", false, Management.Window)
guiSetProperty(Search.Image.Window, "ImageColours", "tl:FF22F500 tr:FF22F500 bl:FF22F500 br:FF22F500")
PlayerSerial.Note.Window = guiCreateLabel(0.32, 0.11, 0.13, 0.05, "* Player Serial :", true, Management.Window)
guiSetFont(PlayerSerial.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerSerial.Note.Window, 0, 224, 245)
guiLabelSetVerticalAlign(PlayerSerial.Note.Window, "center")
Serial.Label.Window = guiCreateLabel(0.45, 0.11, 0.53, 0.05, "", true, Management.Window)
guiSetFont(Serial.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Serial.Label.Window, "center")
PlayerAccount.Note.Window = guiCreateLabel(0.32, 0.16, 0.15, 0.05, "* Player Account :", true, Management.Window)
guiSetFont(PlayerAccount.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerAccount.Note.Window, 255, 23, 203)
guiLabelSetVerticalAlign(PlayerAccount.Note.Window, "center")
Account.Label.Window = guiCreateLabel(0.48, 0.16, 0.51, 0.05, "", true, Management.Window)
guiSetFont(Account.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Account.Label.Window, "center")
PlayerMoney.Note.Window = guiCreateLabel(0.32, 0.22, 0.14, 0.05, "* Player Money :", true, Management.Window)
guiSetFont(PlayerMoney.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerMoney.Note.Window, 246, 254, 23)
guiLabelSetVerticalAlign(PlayerMoney.Note.Window, "center")
Money.Label.Window = guiCreateLabel(0.46, 0.22, 0.52, 0.05, "", true, Management.Window)
guiSetFont(Money.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Money.Label.Window, "center")
PlayerPing.Note.Window = guiCreateLabel(0.32, 0.28, 0.12, 0.05, "* Player Ping :", true, Management.Window)
guiSetFont(PlayerPing.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerPing.Note.Window, 38, 254, 22)
guiLabelSetVerticalAlign(PlayerPing.Note.Window, "center")
Ping.Label.Window = guiCreateLabel(0.44, 0.28, 0.52, 0.05, "", true, Management.Window)
guiSetFont(Ping.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Ping.Label.Window, "center")
Statur.Label.Window = guiCreateLabel(0.32, 0.06, 0.13, 0.04, "#|* Status *|#", true, Management.Window)
guiSetFont(Statur.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Statur.Label.Window, "center")
AdminManage.Label.Window = guiCreateLabel(0.32, 0.38, 0.20, 0.05, "#|* Admin Manage *|#", true, Management.Window)
guiSetFont(AdminManage.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(AdminManage.Label.Window, "center")
Line.Label.Window = guiCreateLabel(0.32, 0.34, 0.67, 0.03, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", true, Management.Window)
guiSetFont(Line.Label.Window, "default-bold-small")
guiLabelSetColor(Line.Label.Window, 254, 21, 21)
guiLabelSetHorizontalAlign(Line.Label.Window, "center", false)
guiLabelSetVerticalAlign(Line.Label.Window, "center")
Spectator.Note.Window = guiCreateLabel(0.32, 0.45, 0.11, 0.05, "* Spectator :", true, Management.Window)
guiSetFont(Spectator.Note.Window, "default-bold-small")
guiLabelSetColor(Spectator.Note.Window, 254, 21, 21)
guiLabelSetVerticalAlign(Spectator.Note.Window, "center")
Spying.Button.Window = guiCreateButton(0.44, 0.45, 0.22, 0.05, "# Spying the player ~", true, Management.Window)
guiSetFont(Spying.Button.Window, "default-bold-small")
guiSetProperty(Spying.Button.Window, "NormalTextColour", "FFFF1D1D")
Kick.Note.Window = guiCreateLabel(0.32, 0.52, 0.12, 0.05, "* Kick player :", true, Management.Window)
guiSetFont(Kick.Note.Window, "default-bold-small")
guiLabelSetColor(Kick.Note.Window, 61, 255, 29)
guiLabelSetVerticalAlign(Kick.Note.Window, "center")
Kick.Button.Window = guiCreateButton(0.44, 0.52, 0.22, 0.05, "# Kick the player ~", true, Management.Window)
guiSetFont(Kick.Button.Window, "default-bold-small")
guiSetProperty(Kick.Button.Window, "NormalTextColour", "FFFFFFFF")
Slap.Note.Window = guiCreateLabel(0.32, 0.59, 0.12, 0.05, "* Slap player :", true, Management.Window)
guiSetFont(Slap.Note.Window, "default-bold-small")
guiLabelSetColor(Slap.Note.Window, 5, 46, 255)
guiLabelSetVerticalAlign(Slap.Note.Window, "center")
Slap.Button.Window = guiCreateButton(0.44, 0.59, 0.22, 0.05, "# Slap the player ~", true, Management.Window)
guiSetFont(Slap.Button.Window, "default-bold-small")
guiSetProperty(Slap.Button.Window, "NormalTextColour", "FFFFFFFF")
Line2.Label.Window = guiCreateLabel(0.32, 0.65, 0.67, 0.03, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", true, Management.Window)
guiSetFont(Line2.Label.Window, "default-bold-small")
guiLabelSetColor(Line2.Label.Window, 254, 21, 21)
guiLabelSetHorizontalAlign(Line2.Label.Window, "center", false)
guiLabelSetVerticalAlign(Line2.Label.Window, "center")
AccManage.Label.Window = guiCreateLabel(0.32, 0.69, 0.23, 0.05, "#|* Account Manange *|#", true, Management.Window)
guiSetFont(AccManage.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(AccManage.Label.Window, "center")
SetPassword.Note.Window = guiCreateLabel(0.32, 0.75, 0.21, 0.04, "* Set Account Password :", true, Management.Window)
guiSetFont(SetPassword.Note.Window, "default-bold-small")
guiLabelSetColor(SetPassword.Note.Window, 4, 252, 255)
guiLabelSetVerticalAlign(SetPassword.Note.Window, "center")
Password.Edit.Window = guiCreateEdit(0.54, 0.75, 0.26, 0.04, "Password ...", true, Management.Window)
ChangePassword.Button.Window = guiCreateButton(0.80, 0.75, 0.18, 0.04, "# Change ~", true, Management.Window)
guiSetFont(ChangePassword.Button.Window, "default-bold-small")
guiSetProperty(ChangePassword.Button.Window, "NormalTextColour", "FFFFFFFF")
RemoveAcc.Note.Window = guiCreateLabel(0.32, 0.80, 0.23, 0.04, "* Remove Player Account :", true, Management.Window)
guiSetFont(RemoveAcc.Note.Window, "default-bold-small")
guiLabelSetColor(RemoveAcc.Note.Window, 4, 252, 255)
guiLabelSetVerticalAlign(RemoveAcc.Note.Window, "center")
RemoveAcc.Button.Window = guiCreateButton(0.56, 0.80, 0.18, 0.04, "# Remove ~", true, Management.Window)
guiSetFont(RemoveAcc.Button.Window, "default-bold-small")
guiSetProperty(RemoveAcc.Button.Window, "NormalTextColour", "FFFFFFFF")
Close.Button.Window = guiCreateButton(0.91, 0.94, 0.07, 0.04, "X", true, Management.Window)
guiSetFont(Close.Button.Window, "default-bold-small")
guiSetProperty(Close.Button.Window, "NormalTextColour", "FFFF0303")
 
addEventHandler("onClientGUIChanged",root,
    function ()
        if ( source == Search.Edit.Window ) then
            local text = string.upper(guiGetText(Search.Edit.Window))
            if ( text == "" ) then
                addPlayers()    
            else
                guiGridListClear(Players.Grid.Window)
                for i,v in ipairs(getElementsByType("player")) do
                    local name = string.upper(getPlayerName(v))
                    if string.find(name,text) then
                        local row = guiGridListAddRow(Players.Grid.Window)
                        guiGridListSetItemText(Players.Grid.Window,row,1,getPlayerName(v),false,false)
                        else
                    end
                end
            end
        end
    end
)
 
addEvent( 'putINFO', true )
Link to comment
--[[ 
changeGridListItemToPlayersName = function ( GridList, Column )
    if GridList and Column then -- Check Parematers
        if getElementType ( GridList ) == "gui-gridlist" then -- Check The Type of ' GridList '
            if guiGridListClear ( GridList ) then -- Clear GridList
                for i, v in next, getElementsByType ( "player" ) do -- Get Everything by Type ' player '
                    local Row = guiGridListAddRow ( GridList ) -- Add Row
                    guiGridListSetItemText ( GridList, Row, Column, getPlayerName ( v ), false, false ); -- Set New Values
                end; -- end of ' for '
            end; -- end of ' clear gridlist '
        end; -- end of ' check gridlist type '
    end; -- end of ' check parematers
end; -- end of ' function '
 
GUIEditor = {
    gridlist = {},
    window = {},
    button = {},
    edit = {}
}
 
        GUIEditor.window[1] = guiCreateWindow(209, 140, 393, 361, "", false)
        guiWindowSetSizable(GUIEditor.window[1], false)
        guiSetVisible ( GUIEditor.window[1], false )
        GUIEditor.gridlist[1] = guiCreateGridList(17, 31, 362, 238, false, GUIEditor.window[1])
       col = guiGridListAddColumn(GUIEditor.gridlist[1], "players", 0.9)
        GUIEditor.edit[1] = guiCreateEdit(18, 285, 361, 24, "", false, GUIEditor.window[1])
        GUIEditor.button[1] = guiCreateButton(123, 319, 136, 24, "", false, GUIEditor.window[1])
        guiSetProperty(GUIEditor.button[1], "NormalTextColour", "FFAAAAAA")    
changeGridListItemToPlayersName ( GUIEditor.gridlist[1], col )
bindKey("F5","down",function() guiSetVisible ( GUIEditor.window[1] , not guiGetVisible ( GUIEditor.window[1] ) ) showCursor ( not isCursorShowing ( ) ) end )
       
addEventHandler("onClientGUIClick",root,
function ()
 
if source  == GUIEditor.button[1] then
 
if GUIEditor.edit[1] == "" then return end
 
    local row = guiGridListGetSelectedItem( GUIEditor.gridlist[1] )
   
    if row and row ~= -1 then   
 
    local Player = guiGridListGetItemText ( GUIEditor.gridlist[1] , row, 1 )
   
    triggerServerEvent ("setAccPassword", localPlayer , Player , guiGetText ( GUIEditor.edit[1] ) )
 
        end
    end
end
)
--]]
 
open = {}
Close = {
    Button = {}
}
Spectator = {
    Note = {}
}
RemoveAcc = {
    Button = {},
    Note = {}
}
Line2 = {
    Label = {}
}
Management = {}
Line = {
    Label = {}
}
PlayerSerial = {
    Note = {}
}
SetPassword = {
    Note = {}
}
ChangePassword = {
    Button = {}
}
PlayerAccount = {
    Note = {}
}
Players = {
    Grid = {}
}
PlayerMoney = {
    Note = {}
}
AccManage = {
    Label = {}
}
Money = {
    Label = {}
}
Kick = {
    Button = {},
    Note = {}
}
Slap = {
    Button = {},
    Note = {}
}
Spying = {
    Button = {}
}
Password = {
    Edit = {}
}
Ping = {
    Label = {}
}
Statur = {
    Label = {}
}
Search = {
    Edit = {},
    Image = {}
}
AdminManage = {
    Label = {}
}
PlayerPing = {
    Note = {}
}
Serial = {
    Label = {}
}
Account = {
    Label = {}
}
Management.Window = guiCreateWindow(0.25, 0.20, 0.50, 0.60, "#-| Management System |-#", true)
guiWindowSetSizable(Management.Window, false)
guiSetAlpha(Management.Window, 1.00)
guiSetVisible(Management.Window, false)
Players.Grid.Window = guiCreateGridList(0.01, 0.11, 0.30, 0.86, true, Management.Window)
guiGridListSetSelectionMode ( Players.Grid.Window, 0 )
guiGridListAddColumn(Players.Grid.Window, "# Players ...", 0.9)
Search.Edit.Window = guiCreateEdit(0.01, 0.06, 0.26, 0.04, "Search ...", true, Management.Window)
Search.Image.Window = guiCreateStaticImage(193, 27, 22, 18, ":admin/client/images/search.png", false, Management.Window)
guiSetProperty(Search.Image.Window, "ImageColours", "tl:FF22F500 tr:FF22F500 bl:FF22F500 br:FF22F500")
PlayerSerial.Note.Window = guiCreateLabel(0.32, 0.11, 0.13, 0.05, "* Player Serial :", true, Management.Window)
guiSetFont(PlayerSerial.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerSerial.Note.Window, 0, 224, 245)
guiLabelSetVerticalAlign(PlayerSerial.Note.Window, "center")
Serial.Label.Window = guiCreateLabel(0.45, 0.11, 0.53, 0.05, "", true, Management.Window)
guiSetFont(Serial.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Serial.Label.Window, "center")
PlayerAccount.Note.Window = guiCreateLabel(0.32, 0.16, 0.15, 0.05, "* Player Account :", true, Management.Window)
guiSetFont(PlayerAccount.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerAccount.Note.Window, 255, 23, 203)
guiLabelSetVerticalAlign(PlayerAccount.Note.Window, "center")
Account.Label.Window = guiCreateLabel(0.48, 0.16, 0.51, 0.05, "", true, Management.Window)
guiSetFont(Account.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Account.Label.Window, "center")
PlayerMoney.Note.Window = guiCreateLabel(0.32, 0.22, 0.14, 0.05, "* Player Money :", true, Management.Window)
guiSetFont(PlayerMoney.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerMoney.Note.Window, 246, 254, 23)
guiLabelSetVerticalAlign(PlayerMoney.Note.Window, "center")
Money.Label.Window = guiCreateLabel(0.46, 0.22, 0.52, 0.05, "", true, Management.Window)
guiSetFont(Money.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Money.Label.Window, "center")
PlayerPing.Note.Window = guiCreateLabel(0.32, 0.28, 0.12, 0.05, "* Player Ping :", true, Management.Window)
guiSetFont(PlayerPing.Note.Window, "default-bold-small")
guiLabelSetColor(PlayerPing.Note.Window, 38, 254, 22)
guiLabelSetVerticalAlign(PlayerPing.Note.Window, "center")
Ping.Label.Window = guiCreateLabel(0.44, 0.28, 0.52, 0.05, "", true, Management.Window)
guiSetFont(Ping.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Ping.Label.Window, "center")
Statur.Label.Window = guiCreateLabel(0.32, 0.06, 0.13, 0.04, "#|* Status *|#", true, Management.Window)
guiSetFont(Statur.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(Statur.Label.Window, "center")
AdminManage.Label.Window = guiCreateLabel(0.32, 0.38, 0.20, 0.05, "#|* Admin Manage *|#", true, Management.Window)
guiSetFont(AdminManage.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(AdminManage.Label.Window, "center")
Line.Label.Window = guiCreateLabel(0.32, 0.34, 0.67, 0.03, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", true, Management.Window)
guiSetFont(Line.Label.Window, "default-bold-small")
guiLabelSetColor(Line.Label.Window, 254, 21, 21)
guiLabelSetHorizontalAlign(Line.Label.Window, "center", false)
guiLabelSetVerticalAlign(Line.Label.Window, "center")
Spectator.Note.Window = guiCreateLabel(0.32, 0.45, 0.11, 0.05, "* Spectator :", true, Management.Window)
guiSetFont(Spectator.Note.Window, "default-bold-small")
guiLabelSetColor(Spectator.Note.Window, 254, 21, 21)
guiLabelSetVerticalAlign(Spectator.Note.Window, "center")
Spying.Button.Window = guiCreateButton(0.44, 0.45, 0.22, 0.05, "# Spying the player ~", true, Management.Window)
guiSetFont(Spying.Button.Window, "default-bold-small")
guiSetProperty(Spying.Button.Window, "NormalTextColour", "FFFF1D1D")
Kick.Note.Window = guiCreateLabel(0.32, 0.52, 0.12, 0.05, "* Kick player :", true, Management.Window)
guiSetFont(Kick.Note.Window, "default-bold-small")
guiLabelSetColor(Kick.Note.Window, 61, 255, 29)
guiLabelSetVerticalAlign(Kick.Note.Window, "center")
Kick.Button.Window = guiCreateButton(0.44, 0.52, 0.22, 0.05, "# Kick the player ~", true, Management.Window)
guiSetFont(Kick.Button.Window, "default-bold-small")
guiSetProperty(Kick.Button.Window, "NormalTextColour", "FFFFFFFF")
Slap.Note.Window = guiCreateLabel(0.32, 0.59, 0.12, 0.05, "* Slap player :", true, Management.Window)
guiSetFont(Slap.Note.Window, "default-bold-small")
guiLabelSetColor(Slap.Note.Window, 5, 46, 255)
guiLabelSetVerticalAlign(Slap.Note.Window, "center")
Slap.Button.Window = guiCreateButton(0.44, 0.59, 0.22, 0.05, "# Slap the player ~", true, Management.Window)
guiSetFont(Slap.Button.Window, "default-bold-small")
guiSetProperty(Slap.Button.Window, "NormalTextColour", "FFFFFFFF")
Line2.Label.Window = guiCreateLabel(0.32, 0.65, 0.67, 0.03, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", true, Management.Window)
guiSetFont(Line2.Label.Window, "default-bold-small")
guiLabelSetColor(Line2.Label.Window, 254, 21, 21)
guiLabelSetHorizontalAlign(Line2.Label.Window, "center", false)
guiLabelSetVerticalAlign(Line2.Label.Window, "center")
AccManage.Label.Window = guiCreateLabel(0.32, 0.69, 0.23, 0.05, "#|* Account Manange *|#", true, Management.Window)
guiSetFont(AccManage.Label.Window, "default-bold-small")
guiLabelSetVerticalAlign(AccManage.Label.Window, "center")
SetPassword.Note.Window = guiCreateLabel(0.32, 0.75, 0.21, 0.04, "* Set Account Password :", true, Management.Window)
guiSetFont(SetPassword.Note.Window, "default-bold-small")
guiLabelSetColor(SetPassword.Note.Window, 4, 252, 255)
guiLabelSetVerticalAlign(SetPassword.Note.Window, "center")
Password.Edit.Window = guiCreateEdit(0.54, 0.75, 0.26, 0.04, "Password ...", true, Management.Window)
ChangePassword.Button.Window = guiCreateButton(0.80, 0.75, 0.18, 0.04, "# Change ~", true, Management.Window)
guiSetFont(ChangePassword.Button.Window, "default-bold-small")
guiSetProperty(ChangePassword.Button.Window, "NormalTextColour", "FFFFFFFF")
RemoveAcc.Note.Window = guiCreateLabel(0.32, 0.80, 0.23, 0.04, "* Remove Player Account :", true, Management.Window)
guiSetFont(RemoveAcc.Note.Window, "default-bold-small")
guiLabelSetColor(RemoveAcc.Note.Window, 4, 252, 255)
guiLabelSetVerticalAlign(RemoveAcc.Note.Window, "center")
RemoveAcc.Button.Window = guiCreateButton(0.56, 0.80, 0.18, 0.04, "# Remove ~", true, Management.Window)
guiSetFont(RemoveAcc.Button.Window, "default-bold-small")
guiSetProperty(RemoveAcc.Button.Window, "NormalTextColour", "FFFFFFFF")
Close.Button.Window = guiCreateButton(0.91, 0.94, 0.07, 0.04, "X", true, Management.Window)
guiSetFont(Close.Button.Window, "default-bold-small")
guiSetProperty(Close.Button.Window, "NormalTextColour", "FFFF0303")
 
addEventHandler("onClientGUIChanged",root,
    function ()
        if ( source == Search.Edit.Window ) then
            local text = string.upper(guiGetText(Search.Edit.Window))
            if ( text == "" ) then
                addPlayers()    
            else
                guiGridListClear(Players.Grid.Window)
                for i,v in ipairs(getElementsByType("player")) do
                    local name = string.upper(getPlayerName(v))
                    if string.find(name,text) then
                        local row = guiGridListAddRow(Players.Grid.Window)
                        guiGridListSetItemText(Players.Grid.Window,row,1,getPlayerName(v),false,false)
                        else
                    end
                end
            end
        end
    end
)
 
Edited by Guest
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...