Jump to content

JanriKallas

Members
  • Posts

    19
  • Joined

  • Last visited

Details

  • Gang
    red

JanriKallas's Achievements

Square

Square (6/54)

0

Reputation

  1. is there way to getPedWeapon and ammo and insert it into table so after respawn it gets the table? I tried toJSON but it can give only one value so like weaponID but not ammo..
  2. function setEngineState(source) if (source) then local car = getPedOccupiedVehicle(source) if (car) then local state = getVehicleEngineState ( car) setVehicleEngineState ( car, not state ) setElementData(car,"enginestate", not state) end end end function enterVehicle ( player, seat, jacked ) --when a player enters a vehicle local state = getElementData(source, "enginestate") if (state) then setVehicleEngineState(source, state) end end addEventHandler ( "onVehicleStartEnter", getRootElement(), enterVehicle )
  3. Lets say theres a three markers MechanicMarker MedicMarker PoliceMarker They are all invisible. Then function makes one of the Marker visible that player chose from clientside. So to not make three different function for policemarker, medicmarker, mechanicmarker Function () --clientside duty = GuigetText (bla1) TriggerEvent ("serverfunc", localplayer, localplayer, duty) End Function (player,duty) --duty is "Mechanic" / "Medic" / "Police" setElementVisibleTo (player, ..duty..Marker) end I alrady tried: (tostring(duty)Marker) and tostring (duty)..Marker
  4. Lets say theres a three markers MechanicMarker MedicMarker PoliceMarker They are all invisible. Then function makes one of the Marker visible that player chose from clientside. So to not make three different function for policemarker, medicmarker, mechanicmarker Function () --clientside duty = GuigetText (bla1) TriggerEvent ("serverfunc", localplayer, duty End Function (player,duty) --duty is "Mechanic" / "Medic" / "Police" setElementVisibleTo (player, MARKERNAME) end I alrady tried: (tostring(duty)Marker) and tostring (duty)..Marker
  5. mechanicmarker medicmarker etc.. local duty = "Mechanic" setElementVisibleTo(player, dutyMarker) I want to make something like this but cant figure out how..
  6. Can you answer one more question? local duty = "Mechanic" setElementVisibleTo(player, dutyMarker) in ElementVisibleTo I want to replace the duty word. How to do it?
  7. How to calculate position front of the car. I want to put ped on to the front of the car.
  8. If anyone is wondering on getting started, I made little account data save system https://community.multitheftauto.com/in ... s&id=12278
  9. oh my bad, case sensitive Thanks a lot really!
  10. I tried but it gets all the time ID 1 when inserting new row??
  11. Problem solved.. dbExec(CREATE TABLE USER_TABLE (id INT NOT NULL AUTO_INCREMENT, x INT, y INT, z INT, PRIMARY KEY (id)) so everytime you insert it automatically puts an ID
×
×
  • Create New...