احم
انا جرربت اسويها اول ما انا فقط اسجل دخولي
( سيريال معين )
تشتغل نغمة لكل الي في السيرفر ..
لكن كالعادة ما اشتغل
,,
الاكواد Here you are ,
طبعا انا ماخذ شوي من المثال الي في الويكي !
SERVER SIDE#
Firewall =
{
['abodeoom'] = 'B4CF2031FF33EAE75430A9956FAE6353',
}
addEventHandler ("onPlayerLogin", getRootElement(),
function (_, theCurrentAccount)
local Serial = Firewall[getAccountName(theCurrentAccount)]
if ( Serial ) then
if serial == getPlayerSerial (source) then
for _,value in ipairs ( getElementsByType ( "player" ) ) do
triggerClientEvent ( value, "StartSound2", value )
end
end
end
end
)
Client Side #
addEvent ( "StartSound2", true )
addEventHandler ( "StartSound2", root,
function ( )
if ( isElement ( Sound ) ) then
destroyElement ( Sound )
Sound = nil
end
Sound = playSound ( "LOGIN.mp3" )
end )