Jump to content

abu5lf

Members
  • Posts

    2,193
  • Joined

  • Last visited

Everything posted by abu5lf

  1. abu5lf

    Problem get()

    Is it possible addenda to the Event
  2. abu5lf

    Problem get()

    client side bindkey = get("bindkey") bindKey( bindkey,'down', function( ) guiSetVisible( win,not guiGetVisible( win ) ) showCursor( not isCursorShowing( ) ) guiSetInputEnabled( not guiGetInputEnabled( ) ) end )
  3. Sent to you via the private
  4. I can not but I put together for the same function button other than closing the window ! Does this affect ?
  5. function closeTheWindow() guiSetVisible(win, false) showCursor(false) end addEventHandler("onClientGUIClick", ok, closeTheWindow, true)
  6. addEventHandler("onPlayerLogin", root, function (Player) if isObjectInACLGroup ("user."..getAccountName ( getPlayerAccount ( Player ) ), aclGetGroup ( "Admin" ) ) then outputChatBox("Admin"..getPlayerName(source).." has logged in!", root) end end )
  7. local sMessage = '' function fStart(sText) sMessage = sText end setTimer ( function fDraw() if sMessage ~= '' then dxDrawText("Roll :", 17.0, 189.0, 61.0, 206.0, tocolor(255, 255, 0, 255), 1.0, "default-bold", "center", "bottom", false, false, false) dxDrawText(sMessage, 61.0, 189.0, 264.0, 226.0, tocolor(0, 225, 0, 255), 1.0, "default-bold", "center", "bottom", false, false, false, false) end end function ( ) removeEventHandler ( "onClientRender", root, ffDraw ) end ,1500,1 ) addEvent("new", true) addEventHandler("new", root, fStart) addEventHandler("onClientRender", root, fDraw) Removal did not work
  8. local restriction = {} addCommandHandler("roll", function(player, cmd) local playerName = getPlayerName ( player ):gsub ( "#%x%x%x%x%x%x", "" ) if restriction[player] then local sMessage = "You have to wait 30 seconds" outputChatBox(sMessage, player, 255, 0, 0) else restriction[player] = true setTimer(restrictionEnd, 30000, 1, player) local randomroll = math.random(1, 3000) local roller = math.random(1, 4) local weapon = math.random(1, 40) if ( roller == 1 ) then givePlayerMoney(player, randomroll) local sMessage = playerName .. '#FFFF00 roll and wins ' .. randomroll .. ' !' triggerClientEvent("new", root, sMessage) elseif ( roller == 2 ) then local sMessage = playerName .. ' roll and is now changed the Weapon ' .. getWeaponNameFromID ( weapon ) .. '!' giveWeapon(player, weapon) triggerClientEvent("new", root, sMessage) else local sMessage = "Good luck next time!" outputChatBox ( sMessage, player, 255, 0, 0) end end end ) function restrictionEnd(player) restriction[player] = nil end That'll remove the HEX colors. And yes, it'll appear to everyone. How can I make it appear on the same player only ?
  9. I mean you name the player
  10. You very much , but the codes colors show ! How to delete ? ---------- Does the message appear in front of everyone?
  11. Did not work anything, did not work also
  12. server side triggerClientEvent("new", getRootElement(),message) restriction = {} addCommandHandler("roll", function(thePlayer) local playerName = getPlayerName(thePlayer) if restriction[playerName] then local sMessage = "You have to wait 30 seconds" outputChatBox(sMessage, thePlayer, 255, 0, 0) else restriction[playerName] = true setTimer(restrictionEnd, 100, 1, playerName) randomroll = math.random(1, 3000) roller = math.random(1, 4) Weapon = math.random(1, 40) if roller == 1 then givePlayerMoney(thePlayer, randomroll) local sMessage = playerName .. '#FFFF00 roll and wins ' .. randomroll .. ' !' outputChatBox(sMessage, getRootElement(), 255, 255, 0, true) elseif roller == 2 then local sMessage = playerName .. ' roll and is now changed the Weapon ' .. Weapon .. '!' giveWeapon(thePlayer, Weapon) outputChatBox(sMessage, getRootElement(), 255, 255, 0, true) end end end ) function restrictionEnd(playerName) restriction[playerName] = nil end client side addEvent( 'new', true ) local sMessage = '' function fStart( sText ) sMessage = sText end function fDraw( ) if sMessage ~= '' then dxDrawText ( "message :", 17.0, 189.0, 61.0, 206.0, tocolor( 255,0,0,255 ), 1.0, "default-bold", "left", "top", false, false, false ) dxDrawText ( sMessage, 61.0, 189.0, 264.0, 226.0, tocolor( 255,225,225,255 ), 1.0, "default-bold", "left", "top", false, false, false ) end end addEventHandler( 'new', root, fStart ) addEventHandler( 'onClientRender', root, fDraw ) , 1.0,
  13. abu5lf

    How ?

    Why ؟ are some servers have it !
  14. abu5lf

    How ?

    How do I get player's name appears in a different language?
  15. abu5lf

    How ?

    How do I make the player accept the name of multilingualism UTF-8 encoding ?
  16. local button = guiCreateButton( 0.7, 0.1, 0.2, 0.1, 'Output!', true ) local editBox = guiCreateEdit( 0.3, 0.1, 0.4, 0.1, 'Type your message here!', true ) guiEditSetMaxLength( editBox, 128 ) guiSetVisible( button, false ) guiSetVisible( editBox, false ) function outputEditBox ( ) Time = get("Time") mount = get("mount") local text = guiGetText( editBox ) triggerServerEvent ( "outputMessage", localPlayer, text ) setTimer( outputEditBox, Time, mount ) end addEventHandler( 'onClientGUIClick', button, outputEditBox, false ) bindKey( 'num_3', 'down', function( ) guiSetVisible( button, not guiGetVisible( button ) ) guiSetVisible( editBox, not guiGetVisible( editBox ) ) showCursor( not isCursorShowing( ) ) end ) meta.xml <meta> <info name="X" author="Cx.83" version="1.0" type="script" /> <script src="s_rotep.lua" type="server"/> <script src="client.lua" type="Client"/> <settings> <setting name="*Time" value="1000" /> <setting name="*mount" value="9999" /> </settings> </meta>
  17. It appears from the text without pressing the button Also appear for all, not only a group admin
  18. Did not work properly Show for all and not a group admin Also do not repeat message after time Also when I press "F1" does not show or closed. Also when it wrote "bindme" not taking place is something
  19. server.lua function wla(thePlayer, commandName,...) local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) if isObjectInACLGroup ( "user." .. accName, aclGetGroup ( "Admin" ) ) then triggerClientEvent("yanas", getRootElement(),yana) end --- client.lua button = guiCreateButton( 0.7, 0.1, 0.2, 0.1, "Output!", true ) editBox = guiCreateEdit( 0.3, 0.1, 0.4, 0.1, "Type your message here!", true ) addEventHandler ( "onClientGUIClick", editBox, outputEditBox ) guiEditSetMaxLength ( editBox, 128 ) function outputEditBox () local text = guiGetText ( editBox ) outputChatBox ( text ) setTimer ( text, 1000, 0 ) end addEventHandler ( "onClientGUIClick", button, outputEditBox ) function bindTheKeys ( player, commandName ) bindKey ( player, "F1", "down", outputEditBox ) end addEvent("yanas", true ) addEventHandler("yanas", getRootElement(), outputEditBox)
  20. abu5lf

    about GUİ

    addEvent("GUIwins",true) addEventHandler("GUIwins",root,function() wins = getElementData(source,"wins") triggerClientEvent(source,"GUIwins",source,wins) end ) addEvent("GUIpoints",true) addEventHandler("GUIpoints",root,function() points = getElementData(source,"points") triggerClientEvent(source,"GUIpoints",source,points) end ) addEvent("GUIsecond",true) addEventHandler("GUIsecond",root,function() second = getElementData(source,"second") triggerClientEvent(source,"GUIsecond",source,second) end ) addEvent("GUIthird",true) addEventHandler("GUIthird",root,function() third = getElementData(source,"third") triggerClientEvent(source,"GUIthird",source,third) end ) addEvent("GUIrank",true) addEventHandler("GUIrank",root,function() rank = getElementData(source,"rank") triggerClientEvent(source,"GUIrank",source,rank) end ) function addbind(player) unbindKey(player, "F1", "down", toggleManager) end function unbind(player) bindKey(player, "F1", "down", toggleManager) end
  21. Very cool script, but there are people who do not understand English never I invite you to set multiple languages, or give me the script and will do so
×
×
  • Create New...