Jump to content

Chronos

Members
  • Posts

    71
  • Joined

  • Last visited

Everything posted by Chronos

  1. Fixed the issue by adding dinput8.dll Thanks for your time.
  2. Hi there, Well, The problem is I can't aim .. and I've got this issue once I updated my MTA to 1.5.1 Here's my MTADiag log https://pastebin.mtasa.com/562722359
  3. Well ,I recommend you to use GTW open source turf system Here's a link for the resource https://community.multitheftauto.com/in ... ls&id=9056
  4. Great resource , keep it up MrBrutus @Wisam In case you wanna add a vehicle limits just add a check Here's an example function playerVehicles() return dbQuery("SELECT * FROM vehicles WHERE owner=? AND ID=?", getAccountName(getPlayerAccount( client )) end Then add a check to the vehicleBuyRequest function function vehicleBuyRequest( model ) -- some functions if playerVehicles(client) >= 10 then outputChatBox(client,"You can't buy more than 10 vehicles.",255,0,0) return end -- functions end
  5. You can use this script https://community.multitheftauto.com/index.php?p=resources&s=details&id=8338 read the description to understand how stuffs work.
  6. local elementBackpack = {} function backPackBack (dataName,oldValue) if getElementType(source) == "player" and dataName =="rucksak" then local newValue = getElementData(source,dataName) if not #newValue or #newValue <= 0 then setElementData ( source, "rucksak", { 0 } ) return true end if not oldValue or not #oldValue then oldValue = { 0 } end if newValue[1] == 0 then if elementBackpack[source] then detachElementFromBone(elementBackpack[source]) destroyElement(elementBackpack[source]) elementBackpack[source] = false end elseif newValue[1] ~= oldValue[1] then if elementBackpack[source] then detachElementFromBone(elementBackpack[source]) destroyElement(elementBackpack[source]) elementBackpack[source] = false end local x,y,z = getElementPosition(source) local rx,ry,rz = getElementRotation(source) local model = newValue[1] if model == 1 then elementBackpack[source] = createObject(3026,x,y,z) elseif model == 2 then elementBackpack[source] = createObject(1248,x,y,z) elseif model == 3 then elementBackpack[source] = createObject(1575,x,y,z) elseif model == 4 then elementBackpack[source] = createObject(1252,x,y,z) elseif model == 5 then elementBackpack[source] = createObject(2405,x,y,z) else return false end if model == 3 then attachElementToBone(elementBackpack[source],source,3,0,-0.16,0.05,270,0,180) else attachElementToBone(elementBackpack[source],source,3,0,-0.225,0.05,90,0,0) end end end if getElementType(source) == "player" and dataName == "helmetOn" then if getElementData ( source, dataName ) then local x, y, z = getElementPosition(source) local helmet = createObject(2052, x, y, z) setElementData ( source, "helmetObject", helmet ) local skin = getElementModel ( source ) if skin == 73 then attachElementToBone(helmet, source, 1, 0, 0.02, -0.53, 0, 0, 90) elseif skin == 287 then attachElementToBone(helmet, source, 1, 0, 0.01, -0.56, 0, 0, 90) elseif skin == 18 then attachElementToBone(helmet, source, 1, 0.015, 0.025, -0.54, 0, 0, 90) elseif skin == 23 then attachElementToBone(helmet, source, 1, 0, 0.015, -0.574, 0, 0, 90) elseif skin == 24 then attachElementToBone(helmet, source, 1, 0, 0.015, -0.575, 0, 0, 90) elseif skin == 1 then attachElementToBone(helmet, source, 1, 0, 0.015, -0.545, 0, 0, 90) elseif skin == 2 then attachElementToBone(helmet, source, 1, 0.015, 0.025, -0.59, 0, 0, 90) else attachElementToBone(helmet, source, 1, 0, 0.015, -115, 0, 0, 90) end else if isElement ( getElementData ( source, "helmetObject" ) ) then detachElementFromBone( getElementData ( source, "helmetObject" ) ) destroyElement ( getElementData ( source, "helmetObject" ) ) setElementData ( source, "helmetObject", false ) end end end end addEventHandler ( "onElementDataChange", getRootElement(), backPackBack )
  7. Chronos

    Topic Moved

    Cool ! keep it up
  8. Wow, cool to see such thing ^^
  9. Try this setElementDimension ( source, 1 )
  10. Check this http://forum.mtasa.com/viewtopic.php?f=148&t=40809
  11. This board for scripting helps not for requests,To script such thing use createTeam setPlayerTeam setPlayerNametagColor
  12. Chronos

    Timers

    Check this example from wiki,It might be usefull for you theTimer = setTimer(function() end, 1000, 10) -- A timer that does nothing. function timerDetails() remaining, executesRemaining, totalExecutes = getTimerDetails(theTimer) -- Get the timers details if (remaining and executesRemaining and totalExecutes) then outputChatBox("Time remaining this second: "..remaining.." Executes remaining: "..executesRemaining.." Total executes: "..totalExecutes) else outputChatBox("Timer no longer exists") end end addCommandHandler("timerdetails", timerDetails)
  13. Chronos

    Timers

    You can use getTimerDetails
  14. Check the script above I've already use local job = getElementData(player, "Police Officer") if job then ....
  15. This script's outdate could recompile it ! also to get data i use this but doesn't work function createPoliceTeam () Policeteam = createTeam ("Police ", 0, 0, 200) end addEventHandler ("onResourceStart", resourceRoot, createPoliceTeam) -- Join the police forces function joinPolice() local job = getElementData(player, "Police Officer") if job then ...
  16. Greeting everybody, I am working on something which is a rhino that can fly with some attached weapons such as MG and missiles,The problem is I search all over wiki /Forum for a function that I can use to set missiles locked in target (Like the hydra one's)
  17. [19:01:10] SCRIPT ERROR: groups_system\group.slua:155: 'end' expected near 'return' [19:01:10] ERROR: Loading script failed: groups_system\group.slua:155: 'end' expected near 'return' ^^
  18. i can't create a group i got this error: [18:46:27] ERROR: Client ................ triggered serverside event groupSystem.attemptMakeGroup, but event is no added serverside what's that ??
  19. i think i got your point,download Navicate Premium,after installation open it, create SQLite connection and chose internal.db, then open it,you will find some tables,check accounts one. still need help post here or send me a pm.
  20. also you just copy my script and post it here,if you copy something then please do it professionally. http://cit2.net/index.php?topic=80583.0
×
×
  • Create New...