khaledmhammed Posted August 19, 2015 Share Posted August 19, 2015 مرحبا شباب كيفككم سويت ليبل على لوحه وابي لاحد فتح اللوحه يطلع القروبات الاسل اللي هو فيها كيف الطريقة يشوف قروبات هو بس Link to comment
iMr.SFA7 Posted August 19, 2015 Share Posted August 19, 2015 قصدك يجيب قروبات الأسل الي هو مضاف فيها ؟ Link to comment
khaledmhammed Posted August 19, 2015 Author Share Posted August 19, 2015 قصدك يجيب قروبات الأسل الي هو مضاف فيها ؟ ايه وانا بحطها ب ايديت الاعب يشوف قروبات الاسل اللي هو بها بس Link to comment
khaledmhammed Posted August 19, 2015 Author Share Posted August 19, 2015 وينكم شباب اعتقد طلبي ماهو صعب عليكم ليبل يجي فيه القروبات الاسل اللي مضاف فيها الاعب الاعب هو يشوف اليبل حقه بس ماحد يقدر يشوفه كل واحد يشوف حقته Link to comment
TAPL Posted August 19, 2015 Share Posted August 19, 2015 aclGroupList isObjectInACLGroup Link to comment
</Mr.Tn6eL> Posted August 19, 2015 Share Posted August 19, 2015 هذا كود من الاخ Booo بسم الله الرحمن الرحيم وظيفه تقوم بجلب جميع القروبات للاعب * لازم يكون مسجل دخول بحسابه فقط سيرفر صيغة الوظيفه getPlayerAllGroups(player) الكود function getPlayerAllGroups(player) local account = getPlayerAccount ( player) if ( isGuestAccount ( account ) ) then return false end local AclList = {} AclList["Groups"] = {} AclList["getGroups"] = {} for _, group in ipairs ( aclGroupList() ) do table.insert ( AclList["Groups"],aclGroupGetName ( group ) ) end for k ,v in pairs(AclList.Groups) do if isObjectInACLGroup ( "user."..getAccountName ( account ), aclGetGroup (v) )then table.insert ( AclList["getGroups"],v) end end return table.concat(AclList.getGroups, ",") end مثآل مثآل من عناد الله يعطيه العآفيه addCommandHandler ( "mygroups", function ( p ) local groups = getPlayerAllGroups ( p ) if groups then outputChatBox ( getPlayerName ( p ).. " [ "..groups.." ].", root, 255, 255, 0, true ) end end ) https://wiki.multitheftauto.com/wiki/GetPlayerAllGroups جيبهم واستخدم triggerClientEvent guiSetText Link to comment
khaledmhammed Posted August 19, 2015 Author Share Posted August 19, 2015 مافهمت زين من الردود لكن عدلت شوي كذا صح s addEventHandler ( "onPlayerLogin", root, function ( _, acl ) local Account = aclGetName ( acl ) setElementData(source,"acl",Accoun) end ) addEventHandler("onElementDataChange",root, function (name) if getElementType(source) == "player" then if name == "acl" then triggerClientEvent(source,"Accoun",source) end end end ) c addEvent ( "Accoun", true ) addEventHandler ( "Accoun", root, function () if getElementData( getLocalPlaye(),"acl") then guiSetText ( Lebelacl, tostring(getElementData(getLocalPlayer(),"acl")) ) else guiSetText ( Lebelacl, "N/A") end end ) Link to comment
Naif Posted August 19, 2015 Share Posted August 19, 2015 -- Server Side function getPlayerAllGroups(player) local account = getPlayerAccount ( player) if ( isGuestAccount ( account ) ) then return false end local AclList = {} AclList["Groups"] = {} AclList["getGroups"] = {} for _, group in ipairs ( aclGroupList() ) do table.insert ( AclList["Groups"],aclGroupGetName ( group ) ) end for k ,v in pairs(AclList.Groups) do if isObjectInACLGroup ( "user."..getAccountName ( account ), aclGetGroup (v) )then table.insert ( AclList["getGroups"],v) end end return table.concat(AclList.getGroups, ",") end addEvent('get',true) addEventHandler('get',root, function ( thePlr ) if ( not isGuestAccount ( getPlayerAccount ( thePlr ) ) ) then triggerClientEvent(thePlr,'setGr',thePlr,getPlayerAllGroups ( thePlr )) else triggerClientEvent(thePlr,'setGr1',thePlr) end end) -- Client Side addEventHandler('onClientResourceStart',resourceRoot, function ( ) triggerServerEvent('get',localPlayer) end) addEvent('setGr',true) addEventHandler('setGr',root, function ( groups ) if ( groups ) then guiSetText(Lebelacl,tostring(groups)) end end) addEvent('setGr1',true) addEventHandler('setGr1',root, function ( ) guiSetText(Lebelacl,'N\A') end) ماجربته , Link to comment
khaledmhammed Posted August 19, 2015 Author Share Posted August 19, 2015 -- Server Side function getPlayerAllGroups(player) local account = getPlayerAccount ( player) if ( isGuestAccount ( account ) ) then return false end local AclList = {} AclList["Groups"] = {} AclList["getGroups"] = {} for _, group in ipairs ( aclGroupList() ) do table.insert ( AclList["Groups"],aclGroupGetName ( group ) ) end for k ,v in pairs(AclList.Groups) do if isObjectInACLGroup ( "user."..getAccountName ( account ), aclGetGroup (v) )then table.insert ( AclList["getGroups"],v) end end return table.concat(AclList.getGroups, ",") end addEvent('get',true) addEventHandler('get',root, function ( thePlr ) if ( not isGuestAccount ( getPlayerAccount ( thePlr ) ) ) then triggerClientEvent(thePlr,'setGr',thePlr,getPlayerAllGroups ( thePlr )) else triggerClientEvent(thePlr,'setGr1',thePlr) end end) -- Client Side addEventHandler('onClientResourceStart',resourceRoot, function ( ) triggerServerEvent('get',localPlayer) end) addEvent('setGr',true) addEventHandler('setGr',root, function ( groups ) if ( groups ) then guiSetText(Lebelacl,tostring(groups)) end end) addEvent('setGr1',true) addEventHandler('setGr1',root, function ( ) guiSetText(Lebelacl,'N\A') end) ماجربته , مو شغال Link to comment
khaledmhammed Posted August 19, 2015 Author Share Posted August 19, 2015 debugscript 3 ? شووف الديبوق انت اشتغل عندك انا هههههه < شطحات 2017 ههه ذذ هذي الاخطاء طال عمركك Link to comment
Naif Posted August 19, 2015 Share Posted August 19, 2015 addEvent('get',true) addEventHandler('get',root, function ( thePlr ) local groups = getPlayerAllGroups ( thePlr ) if ( groups ) then triggerClientEvent(thePlr,'setGr',thePlr,groups) else triggerClientEvent(thePlr,'setGr1',thePlr) end end) Link to comment
khaledmhammed Posted August 19, 2015 Author Share Posted August 19, 2015 مايشتغل يطلع خطاء بذا السطر local groups = getPlayerAllGroups ( thePlr ) ويطلع فيه getPlayerAllGroups Link to comment
khaledmhammed Posted August 19, 2015 Author Share Posted August 19, 2015 وش الحل ي جماعه الخير مافهمتو طلبي ولا وش في Link to comment
Naif Posted August 20, 2015 Share Posted August 20, 2015 function getPlayerAllGroups(player) local account = getPlayerAccount ( player) if ( isGuestAccount ( account ) ) then return false end local AclList = {} AclList["Groups"] = {} AclList["getGroups"] = {} for _, group in ipairs ( aclGroupList() ) do table.insert ( AclList["Groups"],aclGroupGetName ( group ) ) end for k ,v in pairs(AclList.Groups) do if isObjectInACLGroup ( "user."..getAccountName ( account ), aclGetGroup (v) )then table.insert ( AclList["getGroups"],v) end end return table.concat(AclList.getGroups, ",") end حط ذأ بـ ملف السيرفر .. Link to comment
</Mr.Tn6eL> Posted August 20, 2015 Share Posted August 20, 2015 Client addEventHandler("onClientElementDataChange", root, function(data) if source == localPlayer and data == "Groups" then guiSetText(Lebelacl, getElementData(source, "Groups")) end end) Server function getPlayerAllGroups(player) local account = getPlayerAccount ( player) if ( isGuestAccount ( account ) ) then return false end local AclList = {} AclList["Groups"] = {} AclList["getGroups"] = {} for _, group in ipairs ( aclGroupList() ) do table.insert ( AclList["Groups"],aclGroupGetName ( group ) ) end for k ,v in pairs(AclList.Groups) do if isObjectInACLGroup ( "user."..getAccountName ( account ), aclGetGroup (v) )then table.insert ( AclList["getGroups"],v) end end return table.concat(AclList.getGroups, ",") end addEventHandler("onPlayerLogin", root, function( ) setElementData(source, "Groups", getPlayerAllGroups(source) or "N/A") end) addEventHandler("onPlayerLogout", root, function( ) setElementData(source, "Groups", "N/A") end) addEventHandler("onResourceStart", resourceRoot, function( ) for k,v in ipairs(getElementsByType("player")) do setElementData(v, "Groups", getPlayerAllGroups(v) or "N/A") end end) Link to comment
khaledmhammed Posted August 20, 2015 Author Share Posted August 20, 2015 Client addEventHandler("onClientElementDataChange", root, function(data) if source == localPlayer and data == "Groups" then guiSetText(Lebelacl, getElementData(source, "Groups")) end end) Server function getPlayerAllGroups(player) local account = getPlayerAccount ( player) if ( isGuestAccount ( account ) ) then return false end local AclList = {} AclList["Groups"] = {} AclList["getGroups"] = {} for _, group in ipairs ( aclGroupList() ) do table.insert ( AclList["Groups"],aclGroupGetName ( group ) ) end for k ,v in pairs(AclList.Groups) do if isObjectInACLGroup ( "user."..getAccountName ( account ), aclGetGroup (v) )then table.insert ( AclList["getGroups"],v) end end return table.concat(AclList.getGroups, ",") end addEventHandler("onPlayerLogin", root, function( ) setElementData(source, "Groups", getPlayerAllGroups(source) or "N/A") end) addEventHandler("onPlayerLogout", root, function( ) setElementData(source, "Groups", "N/A") end) addEventHandler("onResourceStart", resourceRoot, function( ) for k,v in ipairs(getElementsByType("player")) do setElementData(v, "Groups", getPlayerAllGroups(v) or "N/A") end end) شغال وتمام يعطيكم الف الف عافيه ونايف ماقصصرررررررت شكرا وكل اللي ردو Link to comment
Naif Posted August 20, 2015 Share Posted August 20, 2015 # حيـأإأكككَ الله بـ أي وَقتت Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now