Jump to content


  • Posts

  • Joined

  • Last visited

Everything posted by Tox

  1. Hello I am stuck on a script attaching M4 to a maverick here is the server-side function createMaverick(source,arac,model,posX,posY,posZ,rotX,rotY,rotZ,ad,scale) local Target = getPlayerFromName (source) local pX,pY,pZ = getElementPosition (Target) local maverick = createVehicle (487, tonumber(posX),tonumber(posY),tonumber(posZ),tonumber(rotX),tonumber(rotY),tonumber(rotZ)) kX, kY, kZ = getElementPosition (maverick) if (maverick) then warpPedIntoVehicle (Target, maverick, 0) end end addCommandHandler ("maverick", createMaverick) function attachM4(player) triggerClientEvent (player,"creatingM4") attachElements (maverick,m4,tonumber(posX),tonumber(posY),tonumber(posZ),tonumber(rotX),tonumber(rotY),tonumber(rotZ) ) end addEventHandler ("creatingM4",resourceRoot, attachM4) function atesM4 (player) triggerClientEvent(player,"firingM4") end addEventHandler ("firingM4",resourceRoot, atesM4) and here is the client-side addEvent ("creatingM4",true) addEvent ("firingm4", true) function createM4 () m4 = createWeapon("31", kX, kY, kZ) end addEventHandler ("creatingM4", resourceRoot, createM4) function fireM4() fireWeapon (m4) end addEventHandler("firingM4", resourceRoot, fireM4)
  2. Tox


    hello, do you guys know how can I find function parameters like "who, player, sourcePlayer" and is there a priority for each parameter to type them inside the function brackets?
  • Create New...