Jump to content

mehmet145

Members
  • Posts

    22
  • Joined

  • Last visited

Details

  • Gang
    Are You Gang ? Haha
  • Location
    Ukraina

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

mehmet145's Achievements

Civilian

Civilian (7/54)

0

Reputation

  1. Thanks for all ! Succesfully work!! i'm fixed code addEvent("test", true) addEventHandler("test",root, function( myText ) local label = guiCreateLabel ( 0, 0, 1, 1, "", true ) guiSetText(label, myText ) -- just use the variable as if it was created here, client-side end) function testt ( playerSource, commandName, playerName ) local text = "bla bla bla" triggerClientEvent ( root, "test", root, text) end addCommandHandler ( "test", testt )
  2. Don't work.. Can you do it test_c.lua addEvent("test", true) addEventHandler("test",getRootElement(),function( myText ) -- make sure you define the variable from server-side up here in the brackets local label = guiCreateLabel ( 0, 0, 1, 1, "", true ) guiSetText(label, myText ) -- just use the variable as if it was created here, client-side end) test_s.lua local text = "bla bla bla" triggerClientEvent ( root, "test", root, text) -- make sure you include the variable in the triggerClientEvent
  3. Hi Guys RolePlay HandBrake Script. https://community.multitheftauto.com/index.php?p=resources&s=details&id=11981
  4. Example; ffs = exports["SDT_GUI"] ffs:dxSetVisible(GuiName, true)
  5. triggerClientEvent ( [table/element sendTo=getRootElement()], string name, element sourceElement, [arguments...] ) Example local text = "bla bla bla" triggerClientEvent ( client, "EventName",client, text) ??? addEvent("test", true) addEventHandler("test",getRootElement(), function() guiSetText(label, "" ) end end ) function test() local text = "bla bla bla" triggerClientEvent ( client, "test",getRootElement(), text) end
  6. Hi Guys. how to triggerClientEvent for label ? Server-side function; https://wiki.multitheftauto.com/wiki/GetServerName My Label Element Code; GUIEditor = { button = {}, window = {}, edit = {} } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[1] = guiCreateWindow(0.35, 0.32, 0.35, 0.31, "MTA:SA Admin Announce GUI Panel", true) guiWindowSetMovable(GUIEditor.window[1], false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.edit[1] = guiCreateEdit(0.06, 0.15, 0.87, 0.13, "", true, GUIEditor.window[1]) GUIEditor.button[1] = guiCreateButton(0.21, 0.35, 0.54, 0.21, "Give Announce!", true, GUIEditor.window[1]) guiSetFont(GUIEditor.button[1], "default-bold-small") guiSetProperty(GUIEditor.button[1], "NormalTextColour", "FF48FE00") label = guiCreateLabel(0.01, 0.31, 0.20, 0.39, "", true) end ) addEventHandler("onClientGUIClick",root, function() if source == GUIEditor.button[1] then guiSetText(label, "[ANNOUNCE]; \n" .. guiGetText ( GUIEditor.edit[1] ) ) end end )
  7. math.random setPlayerTeam Example; messages = { "Better luck next time", "Don't think you're so cool now, do you?", "Nice one, pal", "Your opinion is void" } function wastedMessage ( killer, weapon, bodypart ) local randomID = math.random ( 1, #messages ) --get a random ID from the table local randomMessage = messages[randomID] --use that to retrieve a message outputChatBox ( randomMessage, 255, 0, 0 ) --output the message end
  8. mehmet145

    cancel death

    https://wiki.multitheftauto.com/wiki/OnClientPlayerWasted https://wiki.multitheftauto.com/wiki/SetPedAnimation
×
×
  • Create New...