Hey guys, i'm trying to add country flags to my joinquits but i don't know if i am allowed to use 2 functions after each other
this is what i got:
addEventHandler('onClientPlayerJoin', root, showcountry)
function reason()
function showcountry()
local flag = exports.admin:getPlayerCountry ( source )
if flag then
AddingS("join", getPlayerName(source).."#FFFFFF has joined the game#FF4000[#FFFFFF :admin/client/images/flags/"..flag..".png #FF4000]")
else
flag = "N/A"
end
end
)
Hey guys, i have this script it works with quit and when i change my nick but it doesn't do anything when a player joins the server:
part of the code:
local joinSoundBlock = true
addEvent("onPlayerJoinFlag", true)
addEventHandler("onPlayerJoinFlag", getRootElement(), function(thePlayer, thecountry)
AddingS("join", getPlayerName(thePlayer).."#FFFFFF Oyuna girdi #FF4000[#ffffff"..thecountry.."#FF4000]")
if(joinSoundBlock)then
local sound = playSound("joinSound.mp3")
setSoundVolume(sound, 0.2)
joinSoundBlock = false
setTimer(function() joinSoundBlock = true end, 30000, 1)
end
end
)
I'm working on adding colors to the speed script i use but i got this problem
the code i use
dxDrawColorText ("0000", 4, screenHeight - dxGetFontHeight(2.00, 'bankgothic')/2, 100, 100, tocolor ( 0, 0, 0, 255 ), 1.2, 'bankgothic', 0.55, 'left')
and i get this error
attempt to perform arithmetic on global 'screenheight'