Jump to content

مساعدة


Guest

Recommended Posts

بدي أكتب عدد اللاعبين في dxDrawText

بس لي على قيد الحياة

server

	function aliveplayers ()
alivePlayers = getAlivePlayers ()
if ( alivePlayers ) then -- if we got the table
    alivePlayersList = "none"
    -- Loop through the table
    for playerKey, playerValue in ipairs(alivePlayers) do
        -- add their name to the list
        if ( alivePlayersList == "none" ) then
            alivePlayersList = getPlayerName ( playerValue )
        end
    end
    triggerClientEvent ( source, "getallaliveplayers" )
end
end
    function alives ()
	local screenW, screenH = guiGetScreenSize()
        dxDrawText("Alive", (screenW - 110) / 2, (screenH - 37) / 2, ((screenW - 110) / 2) + 110, ( (screenH - 37) / 2) + 37, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
        dxDrawText(tonumber (alivePlayersList), 660, 403, 681, 430, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
    end
	addEventHandler("onClientRender", root, alives) 
addEvent( "getallaliveplayers", true )
addEventHandler( "getallaliveplayers", localPlayer, alives )

 

Link to comment

 سويتها و الكود شغال و أسف على الإزعاج عندي سؤالين

	setElementData(resourceRoot,'Players',#getAlivePlayers())

ليش ضفت 

resourceRoot 

و

#

Edited by Guest
Link to comment
Just now, Scarfas said:

سويتها و الكود شغال و أسف على الإزعاج عندي


	setElementData(resourceRoot,'Players',#getAlivePlayers())

ليش ضفت 

resourceRoot 

و

#

resourceRoot : عشان يحط الداتا علي المود

-------------------------------------------------------

getAlivePlayers

الكود دا بيرجعلك تيبل بكل الاعبين اللي علي قيد الحياة

احنا نبي عدد الاعبين اللي في التيبل ذا

مشان كدا استخدم 

#

عشان يجيبلك عدد اللاعبين اللي علي قيد الحياة اللي في التيبل

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...