Jump to content

ScofieldX

Members
  • Posts

    6
  • Joined

  • Last visited

Details

  • Gang
    Grove street

ScofieldX's Achievements

Vic

Vic (3/54)

0

Reputation

  1. Ah thanks, and it's edited, thanks again man.
  2. Here's the tip end of what I'm talking about. function updateCarRadio() local state = getElementData(localPlayer, "streams") if (state == "0") then setRadioChannel(0) -- kill all radio channels for _, value in pairs(soundElementsOutside) do stopSound(value) end soundElementsOutside = {} -- kill the mp3 player if mp3Sound then stopSound(mp3Sound) mp3Sound = nil mp3Station = nil end else -- repopulate all radio channels local vehicles = getElementsByType("vehicle") for _, theVehicle in ipairs(vehicles) do if (isElementStreamedIn(theVehicle)) then spawnSound(theVehicle) end end end end addEvent("accounts:settings:updateCarRadio", false) addEventHandler("accounts:settings:updateCarRadio", getRootElement(), updateCarRadio) -- local mp3Window = nil local width, height = mp3_w, mp3_h function destroyMP3Window() if mp3Window then destroyElement(mp3Window) mp3Window = nil end end addEventHandler('onClientChangeChar', root, function() if mp3Sound then stopSound(mp3Sound) mp3Sound = nil mp3Station = nil end destroyMP3Window() end) function showMP3GUI() destroyMP3Window() mp3Window = guiCreateStaticImage(mp3_x, mp3_y, mp3_w, mp3_h, ":resources/window_body.png", false) local grid = guiCreateGridList(10, 10, width - 20, height - 50, false, mp3Window) local col = guiGridListAddColumn(grid, 'Station', 0.85) for k, v in ipairs(streams) do if k ~= 0 then local row = guiGridListAddRow(grid) guiGridListSetItemText(grid, row, col, v[1], false, false) guiGridListSetItemData(grid, row, col, tostring(k)) end end addEventHandler('onClientGUIClick', grid, function() local item = guiGridListGetSelectedItem(grid) if item ~= -1 then local station = tonumber(guiGridListGetItemData(grid, item, col)) if mp3Sound then stopSound(mp3Sound) mp3Sound = nil end mp3Sound = playSound(streams[station][2], true) mp3Station = station end end, false) local off = guiCreateButton(10, height - 35, 85, 25, 'Turn Off', false, mp3Window) addEventHandler('onClientGUIClick', off, function() if mp3Sound then stopSound(mp3Sound) mp3Sound = nil mp3Station = nil end end, false) local close = guiCreateButton(105, height - 35, 85, 25, 'Close', false, mp3Window) addEventHandler('onClientGUIClick', close, destroyMP3Window, false) end addEvent('realism:mp3:off', true) addEventHandler('realism:mp3:off', root, function() if mp3Sound then stopSound(mp3Sound) mp3Sound = nil mp3Station = nil end end)
  3. I have this small problem. It involves carradio that's the resource, Now here's my problem The car radio streams good when the engine is running, but when I turn the engine off, to save gas, the radio turns off, I'm not a scripter when it comes to .lua But if anyone can help me out with how to make the radio still play even when the engine is turned off that would be fantastic.
  4. Alright so.. If I wanted to force them.. to login How would i go about doing that? Lol.
  5. [2014-04-26 15:35:14] WARNING: [DayZ]\DayZ\login.lua_dayz:0: Bad argument @ 'setAccountData' [Expected account at argument 1, got boolean Do I need to change something in this?
  6. Here's the details. 1. I'm looking for someone to make a DayZ script / game mode. 2. I'm willing to pay that scripter the money for the work he does. 3. As long it's not over $50 4. He can have administrator spot, if he chooses to work with us in case we need constant updates or other things done with the server within itself. 5. I'll give him the desire information for him to upload his work to the server.. So then either myself or my friends can test it out.. then go from there with payment options. 6. I only do deals via paypal only. Anything else you may want to know and such.. Feel free to contact me on here.
×
×
  • Create New...