Blaawee Posted October 20, 2011 Share Posted October 20, 2011 (edited) hi everyone i want to know how to hide the Hex Code in this line dxDrawText ( getPlayerName ( player ), px + 1, py + 1, px, py, ICON_TEXT_SHADOW, scale ) -- text dxDrawText ( getPlayerName ( player ), px, py, px, py, color, scale ) [solved] Thx TAPL Edited October 20, 2011 by Guest Link to comment
TAPL Posted October 20, 2011 Share Posted October 20, 2011 dxDrawText ( string.gsub(getPlayerName (player), "#%x%x%x%x%x%x", ""), px + 1, py + 1, px, py, ICON_TEXT_SHADOW, scale ) -- text dxDrawText ( string.gsub(getPlayerName (player), "#%x%x%x%x%x%x", ""), px, py, px, py, color, scale ) Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 i'v made i playsound3D But I'm the only i can hear it @@ here it's playSound3D("music.mp3", 614.5419921875, -1895.9779052734, 3.4590957164764, true) playSound3D("music.mp3", -404.003784179, 340.27352905273, 1.2498687076, true) playSound3D("music.mp3", -1490.0997314453, 762.89318847656, 8.3803997039795, true) should be like this ? i see the example in the wiki!! function Music() playSound3D("music.mp3", 614.5419921875, -1895.9779052734, 3.4590957164764, true) playSound3D("music.mp3", -404.003784179, 340.27352905273, 1.2498687076, true) playSound3D("music.mp3", -1490.0997314453, 762.89318847656, 8.3803997039795, true) end addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), Music) Link to comment
TAPL Posted October 20, 2011 Share Posted October 20, 2011 i didn't get you but maybe this what you want viewtopic.php?f=91&t=36572 Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 Yup TAPL like this , But I want it without Command Link to comment
^Dev-PoinT^ Posted October 20, 2011 Share Posted October 20, 2011 Like This function onResourceStart() local sound = playSound3D("sounds/song.mp3", 373.14, -125.21, 1001, true) end addCommandHandler( "Play", onResourceStart ) ?? Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 Without Command ^^ Link to comment
TAPL Posted October 20, 2011 Share Posted October 20, 2011 this should work as you making it function Music() playSound3D("music.mp3", 614.5419921875, -1895.9779052734, 3.4590957164764, true) playSound3D("music.mp3", -404.003784179, 340.27352905273, 1.2498687076, true) playSound3D("music.mp3", -1490.0997314453, 762.89318847656, 8.3803997039795, true) end addEventHandler("onClientResourceStart", resourceRoot, Music) Link to comment
^Dev-PoinT^ Posted October 20, 2011 Share Posted October 20, 2011 lol sry i dont see it function Music() playSound3D("music.mp3", 614.5419921875, -1895.9779052734, 3.4590957164764, true) playSound3D("music.mp3", -404.003784179, 340.27352905273, 1.2498687076, true) playSound3D("music.mp3", -1490.0997314453, 762.89318847656, 8.3803997039795, true) end addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), Music) Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 is meta should be like this ? Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 what if i but the type type="client" /> or type="server" /> ? Link to comment
^Dev-PoinT^ Posted October 20, 2011 Share Posted October 20, 2011 yub dont put it like this ----------------------- put like This Link to comment
TAPL Posted October 20, 2011 Share Posted October 20, 2011 try this function Music() local sounds = { playSound3D("music.mp3", 614.5419921875, -1895.9779052734, 3.4590957164764, true), playSound3D("music.mp3", -404.003784179, 340.27352905273, 1.2498687076, true), playSound3D("music.mp3", -1490.0997314453, 762.89318847656, 8.3803997039795, true)} setSoundMaxDistance(sounds, 10) end addEventHandler("onClientResourceStart", resourceRoot, Music) Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 thx TAPL it's Worked But There somthing @@ the ped not there -------------------------------------------------------------------------------------------------------------- function pedLoad() dancer1 = createPed(292, -1495.1926269531, 761.52935791016, 7.1834278106689, 0) dancer2 = createPed(293, -1496.5218505859, 765.72064208984, 7.1875, 0) dancer3 = createPed(298, -1498.4525146484, 761.25640869141, 7.1875, 0) dancer4 = createPed(304, -1499.099609375, 763.75598144531, 7.1875, 0) guard1 = createPed(17, -1513.1009, 764.656738, 7.1875, 0) guard2 = createPed(17, -1513.09411, 761.21850, 7.1875, 0) setPedRotation(dancer1, 35) setPedRotation(dancer2, 100) setPedRotation(dancer3, -20) setPedRotation(dancer4, 150) setPedRotation(guard1, 100) setPedRotation(guard2, 100) setPedAnimation(dancer1, "DANCING", "dnce_M_a") setPedAnimation(dancer2, "DANCING", "DAN_Left_A") setPedAnimation(dancer3, "DANCING", "dance_loop") setPedAnimation(dancer4, "DANCING", "dnce_M_d") end addEventHandler ( "onResourceStart", resourceRoot, pedLoad ) Link to comment
TAPL Posted October 20, 2011 Share Posted October 20, 2011 did you put it in meta as type server ? Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 edit it's work Soory ^^ Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 Thx TAPL for the help but i have something , is there any code tell me who has been loged in ?? Link to comment
TAPL Posted October 20, 2011 Share Posted October 20, 2011 -- Server Side -- function Login (thePreviousAccount, theCurrentAccount) outputChatBox (getPlayerName(source).."has logged into "..getAccountName(theCurrentAccount), root, 255, 255, 0 ) end addEventHandler ("onPlayerLogin", root, Login) Link to comment
Blaawee Posted October 20, 2011 Author Share Posted October 20, 2011 thx But what if his name have Hex Code ? 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