Jump to content

Metall

Members
  • Posts

    44
  • Joined

  • Last visited

About Metall

  • Birthday October 17

Details

  • Gang
    None
  • Location
    Sweden
  • Interests
    Doing... stuff...

Recent Profile Visitors

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

Metall's Achievements

Rat

Rat (9/54)

0

Reputation

  1. Metall

    Delete

    Seems cool, good job.
  2. You posted a code where you could choose an URL directly from the command. I posted a little guide how to do it with a GUI and a table.
  3. 1. Make a GUI using something like GUIEditor. 2. Create a table looking something like this, urls = { {"www.youradress.com/song.mp3"}, } 3. Get the data from that table, for index, data in ipairs(urls) do url = data[1] -- Do something with that data, ex. outputChatBox(data[1]) -- Outputs the url into the chatbox (not needed). end 4. Set that data into a gridlist or something of your choice using something like this, guiCreateGridList guiGridListAddColumn guiGridListAddRow guiGridListSetItemText Should turn into something like this (not tested, only an example) window = guiCreateWindow(0, 0, 0, 0, "Example", false) gridlist = guiCreateGridList(0, 0, 0, 0, false, window) column = guiGridListAddColumn(gridlist, "URLs", 1) urls = { {"http://www.181.fm/asx.php?station=181-eagle"}, } for index, data in ipairs(urls) do local row = guiGridListAddRow(gridlist) guiGridListSetItemText(gridlist, row, column, index, false, false) end And then ofcourse you would have to get that URL from the gridlist and play it using playSound or playSound3D.
  4. I guess this is what you wanted to do, Server: local LV = createColRectangle(866, 656, 2100, 2300) function onEnter(player, md) if (player and isElement(player) and getElementType(player) == "player" and md) then outputChatBox("Welcome to Las Venturas!", player, 0, 255, 0) end end addEventHandler("onColShapeHit", LV, onEnter) md is short for matchingDimension, both can be used in as included parameters. It's probably not even needed unless you only want it to be triggered in the main dimension (0).
  5. You could use dxDrawText to draw a text on your screen, but you want to be able to write in it don't you? If so, I have no idea. dxDrawText
  6. Metall

    Question

    setWeaponProperty For example, to set the weapon accuracy property of an M4 to "poor" you code it like this function setDamage() setWeaponProperty(31, "poor", "damage", 200) end addCommandHandler("damage", setDamage) "poor" means that all the players who have that effect will get increased damage on their M4. It can be changed to "std" and "pro" also.
  7. Try taking a look at this resource, https://community.multitheftauto.com/index.php?p= ... ils&id=844
  8. I saw that OVH doesen't accept offers in Sweden, means i won't be able to buy a dedicated server. What should i do? Is it possible getting a middle? Or something..?
  9. Stop the play gamemode/resource
  10. Well, if the commandHandler you made has a "-" in it, then yes. Like if your command handler under your function is: addCommandHandler("staff", function) Then it's executeCommandHandler("staff", localPlayer)
  11. function commandPanel(plr) executeCommandHandler("yourCommand1", plr) executeCommandHandler("yourCommand2", plr) end addCommandHandler("commandpanel", commandPanel) ?
  12. Well if i get it right you can do it like this: addCommandHandler("cmd", function) addCommandHandler("cmd", function) Multiple times for different functions.
  13. local marker = createMarker() setElementInterior(marker, interior) setElementDimension(marker, dimension)
  14. function teleportarPlayer (player, CMD, targetName) local accountName = getAccountName(getPlayerAccount(player)) if isObjectInACLGroup("user."..accountName , aclGetGroup("Admin")) then if not targetName then outputChatBox("Uso Correto: /goto nick") else local target = getPlayerFromName (targetName ) if not target then -- check if the name is valit outputChatBox("ERRO: Jogador não encontra-se online!") else local x,y,z = getElementPosition ( target ) setElementPosition ( player,x,y,z+1) --setElementPosition ( player, getElementPosition ( target )) end end end end addCommandHandler ( "goto", teleportarPlayer ) Tested and works! NOTE: Must be serverside.
  15. Metall

    FPS 49 lagg

    Try setting the FPS on 60, otherwise if it's on 49, it will go from 49 to 30, and repeat, which causes lag.
×
×
  • Create New...