Jump to content

Search the Community

Showing results for tags 'warning'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Multi Theft Auto: San Andreas 1.x
    • Support for MTA:SA 1.x
    • User Guides
    • Open Source Contributors
    • Suggestions
    • Ban appeals
  • General MTA
    • News
    • Media
    • Site/Forum/Discord/Mantis/Wiki related
    • MTA Chat
    • Other languages
  • MTA Community
    • Scripting
    • Maps
    • Resources
    • Other Creations & GTA modding
    • Competitive gameplay
    • Servers
  • Other
    • General
    • Multi Theft Auto 0.5r2
    • Third party GTA mods
  • Archive
    • Archived Items
    • Trash

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Gang


Location


Occupation


Interests

Found 9 results

  1. My previous topic was blocked just like that, there was nothing, even comments and advertisements that could violate the forum rule. Please help fix the warnings
  2. Hi friends, I have a small problem In the console it gives this warning Bad argument @ 'setElementModel' [Expected element at argument 1, got number '100'] Which corresponds to the following line setElementModel (tonumber(getElementData(accSys:getPlayerAcc(thePlayer), "cSkin"))) cods ---- admin duty skin ---- addCommandHandler("a209", function ( thePlayer, command ) if tonumber(getElementData(accSys:getPlayerAcc(thePlayer), "pAdmin")) < 10 then return false end setElementData(accSys:getPlayerAcc(thePlayer), "dSkin", 209) setElementModel (thePlayer, 209) end) --- admin off skin ---- addCommandHandler("o209", function ( thePlayer, command ) if tonumber(getElementData(accSys:getPlayerAcc(thePlayer), "pAdmin")) < 10 then return false end setElementModel (tonumber(getElementData(accSys:getPlayerAcc(thePlayer), "cSkin"))) end) in part of ---- admin duty skin ---- There is no problem in the ---- admin duty skin ---- part but In the second part, --- admin off skin ----, when I order, Warning comes The second part must set the player model from the part of cSkin But it does not and gives high warning Sorry for the bad English language Please help me, my only hope is you
  3. addEventHandler ("onResourceStart", getRootElement(), function() setTimer ( moneyZoneTimerFunction, 2500, 0) local allGreenzones = getElementsByType ("radararea") for i,v in ipairs (allGreenzones) do local r,g,b,a = getRadarAreaColor (v) if (r == 0) and (g == 255) and (b == 0) and (a == 127) then local x,y = getElementPosition (v) local sx,sy = getRadarAreaSize (v) local col = createColCuboid (x,y, -50, sx,sy, 7500) setElementID (col, "greenzoneColshape") end end end) addEventHandler ("onColShapeHit", getRootElement(), function(hitElement, matchingDimension) if (getElementType (hitElement) == "player") and (getElementID (source) == "greenzoneColshape") then outputChatBox ("", hitElement, 255, 0, 0, true) toggleControl (hitElement, "fire", false) toggleControl (hitElement, "next_weapon", false) toggleControl (hitElement, "previous_weapon", false) toggleControl (hitElement, "sprint", true) toggleControl (hitElement, "aim_weapon", false) toggleControl (hitElement, "vehicle_fire", false) setPlayerHudComponentVisible (hitElement, "ammo", false) setPlayerHudComponentVisible (hitElement, "weapon", false) triggerClientEvent (hitElement, "enableGodMode", hitElement) end if (source == moneyZoneCol) and (getElementType (hitElement) == "vehicle") then setElementVelocity (hitElement, 0, 0, 0) setElementPosition (hitElement, 2018.33, 1534.77, 12.37) setVehicleRotation (hitElement, 0,0,270) if (getVehicleOccupant (hitElement, 0)) then outputChatBox ("", getVehicleOccupant (hitElement, 0), 255, 0, 0, false) end end end) addEventHandler ("onColShapeLeave", getRootElement(), function(leaveElement, matchingDimension) if (getElementType (leaveElement) == "player") and (getElementID (source) == "greenzoneColshape") then outputChatBox ("", leaveElement, 255, 0, 0, false) toggleControl (leaveElement, "fire", true) toggleControl (leaveElement, "next_weapon", true) toggleControl (leaveElement, "previous_weapon", true) toggleControl (leaveElement, "sprint", true) toggleControl (leaveElement, "aim_weapon", true) toggleControl (leaveElement, "vehicle_fire", true) setPlayerHudComponentVisible (leaveElement, "ammo", false) setPlayerHudComponentVisible (leaveElement, "weapon", false) triggerClientEvent (leaveElement, "disableGodMode", leaveElement) end end) --money zone col moneyZoneCol = createColCuboid (1993.12, 1519.14, -100, 17.43, 54.24, 117) --stop moneyzone col -- marker bij hospital createMarker (1607.36, 1814.24, -10, "cylinder", 24, 0, 255, 0, 190, getRootElement()) Boa noite, estou usando um script de Zona Verde e continuo recebendo warnings sobre um setTimer para uma função que não existe supostamente, queria saber se alguém pode me indicar um modo de retirar esse warning e se eu preciso manter esse setTimer, não programo em Lua porém consigo entender algumas coisas e até alterar outras, porém essa está difícil de entender para mim. Mensagem:
  4. CLIENT: function cancelTazerDamage(attacker, weapon, bodypart, loss) if (weapon==24) then -- deagle local mode = getElementData(attacker, "handTaser") if (mode==true) then cancelEvent() end end end addEventHandler("onClientPlayerDamage", localPlayer, cancelTazerDamage) local cFunc = {} local cSetting = {} cSetting["shots"] = {} cSetting["shot_calcs"] = {} local last_shot = 1 cFunc["draw_shot"] = function(x1, y1, z1, x2, y2, z2) table.insert(cSetting["shots"], last_shot, {x1, y1, z1, x2, y2, z2}) local lastx, lasty, lastz = x1, y1, z1 local dis = getDistanceBetweenPoints3D(x1, y1, z1, x2, y2, z2) cSetting["shot_calcs"][last_shot] = {} last_shot = last_shot+1 end cFunc["wait_shot"] = function() toggleControl("fire", false) setTimer(function() toggleControl("fire", true) end, 15000, 1) end cFunc["shot_check"] = function(wp, _, _, hitX, hitY, hitZ, element, startX, startY, startZ) if(wp == 24) and (getElementData(localPlayer,"handTaser"))then cFunc["shot_weapon"](hitX, hitY, hitZ, startX, startY, startZ) cancelEvent() if(source == localPlayer) then cFunc["wait_shot"]() end end end cFunc["anim_check"] = function(attacker, wep, bodypart,loss) if(wep == 24) and (getElementData(localPlayer,"handTaser"))then local playerX,playerY,playerZ = getElementPosition(localPlayer) local targetX,targetY,targetZ = getElementPosition(source) if getDistanceBetweenPoints3D(playerX,playerY,playerZ,targetX,targetY,targetZ) <= 12 then triggerServerEvent("tazerFired", getRootElement(), source) end end end addEventHandler("onClientPlayerWeaponFire", getRootElement(), cFunc["shot_check"]) addEventHandler("onClientPedDamage", getRootElement(),cFunc["anim_check"]) addEventHandler("onClientPlayerDamage", getRootElement(),cFunc["anim_check"]) addEventHandler("onClientResourceStart",resourceRoot,function() setElementData(localPlayer, "tazed",0) end) addEventHandler("onClientRender",getRootElement(),function() if getElementData(localPlayer, "tazed") == 1 then toggleAllControls(false, false, false) toggleControl("fire", false) toggleControl("sprint", false) toggleControl("crouch", false) toggleControl("jump", false) toggleControl('next_weapon',false) toggleControl('previous_weapon',false) toggleControl('aim_weapon',false) end end) SERVER: local cFunc = {} local cSetting = {} function tazerFired(target) if (isElement(target) and getElementType(target)=="player") then fadeCamera ( target, false, 1.0, 255, 255, 255 ) setElementData(target, "tazed", 1) toggleAllControls(target, false, false, false) setPedAnimation(target, "ped", "FLOOR_hit_f", -1, false, false, true) setTimer(removeAnimation, 30000, 1, target) end end addEvent("tazerFired", true ) addEventHandler("tazerFired", getRootElement(), tazerFired) function removeAnimation(thePlayer) if (isElement(thePlayer) and getElementType(thePlayer)=="player") then fadeCamera(thePlayer, true, 0.5) if getElementData(thePlayer,"isAnim") then setElementFrozen(thePlayer,true) setPedAnimation(thePlayer,"sweet","sweet_injuredloop",-1,false,false,false) else setPedAnimation(thePlayer,nil,nil) toggleAllControls(thePlayer, true, true, true) end setElementData(thePlayer, "tazed", 0) end end I do not get any errors/warnings in debugscript 3, just simply does not working the script.. What wrong in this codes? :s
  5. So, friend of mine got this error: Picture He was like: dbConnection was in use, this is why it happened, but i was like: thats impossible, so this is why i ask you guys. btw: This is just a question, and i dont need a script-fix for is, just an answer about it.Thx in advance.
  6. local screenW, screenH = guiGetScreenSize() addEventHandler("onClientRender", root, function() dxDrawRectangle(screenW * 0.0021, screenH * 0.7356, screenW * 0.2104, screenH * 0.0367, tocolor(0, 0, 0, 164), false) dxDrawText(text, screenW * 0.0014, screenH * 0.7367, screenW * 0.2125, screenH * 0.7722, tocolor(255, 255, 255, 255), 1.00, "default-bold", "center", "center", false, false, false, true, false) end ) addEventHandler("onClientPlayerJoin", root, function() local l_2_0 = getPlayerName(source) text = "#00ff00" .. l_2_0 .. " csatlakozott!" pic = "j" end ) addEventHandler("onClientPlayerQuit", root, function(l_3_0) local l_3_1 = getPlayerName(source) text = "#FF0000" .. l_3_1 .. " lelépett!" pic = "q" end ) addEventHandler("onClientPlayerChangeNick", root, function(l_4_0, l_4_1) text = "" .. l_4_0 .. "#00FF00 Új neve #00BAFF: " .. l_4_1 .. "" pic = "c" end ) fileDelete("client.lua") and i got this warning: : 6 : bad argument 'dxDrawText' [expected string at argument 1, got nil] how to fix this?
  7. Hi all! I'm dont speak English, I use google translate ERROR: [DayZ-MTA]/DayZ/survivorSystem.lua:374: attempt to index global 'elementWeaponRaplace' (a nil value) Function: Line warning if elementWeaponRaplace[source] then Help remove this warning please!
  8. function boom ( ) local pX, pY, pZ = getElementPosition ( source ) createExplosion ( pX, pY, pZ, 2 ) end addCommandHandler( "rob", boom, getLocalPlayer() ) bad argument @ 'addCommandHandler' [Expected bool at argument 3, got player]
×
×
  • Create New...