Jump to content

dzek (varez)

Retired Staff
  • Posts

    4,144
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by dzek (varez)

  1. put your config into your config here tags. and about gate maker - i dont know how its working, but you have to specify some coordinates, right?
  2. xx3 just download basemode, and search for "addEvent" and "addEventHandler" inside all lua files
  3. just tell use which resource you was willing to use, send us your configuration and we will try to help you and point your mistakes if you dont have a time, you can use public resources, or get some money, and make an offer. you wont find free scripter that will be fullfilling your request. this is help forum
  4. what you mean outside gta sa? give coordinates
  5. i cant belive my eyes.. life could be a lot easier for 20 people if you, loler, found all that links 2 months ago
  6. put you column name in ->> ` <--- this chars (quotes) (one the left from "1" key on keyboard) like Select `character` from `mytable` where id='5'
  7. gudenmike, all scripts you want actually ARE in the community.multitheftauto.com if you have problems with them - ask, but they are actually working and probably you are doing something wrong..
  8. and paying for parts of script? MySQL is not developed by MTA team and MySQL module is not by MTA team as well (AFAIK)
  9. you mean "request"? so.. this forum is not for request. this forum is for HELP
  10. and wtf is "thePlayer".. you asked for example, i gave you one, but you have to have the slightest idea about WHAT YOU ARE ACTUALLY DOING
  11. DEBUG FFS! function PlayMusic(thePlayer) -- edited if (isObjectInACLGroup ("user."..getAccountName(getPlayerAccount(thePlayer)),aclGetGroup("Admin"))) then triggerClientEvent(getRootElement(), "playMyMusic", getRootElement()) end end addCommandHandler("mario", PlayMusic)
  12. addCommandHandler("killAll", function(thePlayer) if (isObjectInACLGroup ("user."..getAccountName(getPlayerAccount(thePlayer)),aclGetGroup("Admin"))) then local players=getElementsByType("player") for key,val in ipairs(players) do killPed(val) end outputChatBox("* "..getPlayerName(thePlayer).." killed all players *", getRootElement(), 255, 0, 0) else outputChatBox("* You need to be admin to kill all players *", thePlayer, 255, 0, 0) end end) and for client-side, you have to check it like that (but i dont see a point in client-side admin thing) --[[ ***************** client-side part ***************** ]] addCommandHandler("pushMyCarClientSide", function() triggerServerEvent("checkAdmin", getLocalPlayer(), "pushMyCarClientSideEvent") -- 3rd argument is the event we want to trigger after check end) addEvent("pushMyCarClientSideEvent", true) addEventHandler("pushMyCarClientSideEvent", getRootElement(), function() local veh = getPedOccupiedVehicle(getLocalPlayer()) if (veh) then local xx,yy,zz = getElementVelocity(veh) setElementVelocity(veh, xx,yy,zz+4) else outputChatBox("* You need to be in car *", 255, 0, 0) end end) --[[ ***************** server-side part ***************** ]] addEvent("adminCheck", true) addEventHandler("adminCheck", getRootElement(), function(eventToFire) if (isObjectInACLGroup ("user."..getAccountName(getPlayerAccount(thePlayer)),aclGetGroup("Admin"))) then triggerClientEvent(source, eventToFire, source) else outputChatBox("* You need to be an admin *", source, 255, 0, 0) end )
  13. oh, sorry, i didnt notice that isPlayerLoggedIn is your custom function loler is right - i dont know which version is not using setPedModel anymore, but you should change it setElementModel u tried to debug it with debugscript ? @loler: i said same thing to you few days ago, i see you learnt something
  14. if you are behind more than one NAT ( http://en.wikipedia.org/wiki/Network_ad ... ranslation ) there could be a problem. It also depends on your ISP. Have you successfully created any server (any game) before?
  15. saving something to xml is faster than creating normal text-save reading from saved xml is even faster, cause you are just getting needed arguments, than splitting strings etc
  16. -- part of your code: local playerAccount = isPlayerLoggedIn(player) -- you are checking if the player is logged (getting true or false) if playerAccount then -- if true setAccountData(playerAccount, "s.HandMoney", tonumber(getPlayerMoney(player))) -- save data to .. "true"? -- conclusion: -- you need to getPlayerAccount after checking if he/she is logged in -- then save/read to this account
  17. local carCount = 0 remove local
  18. how about pre-payments? (scripting/paying for parts of script)
  19. need more script, post whole
  20. isn't it faster to try them both than waiting 12h to reply? ;| ... 0
  21. local root = getRootElement() addEventHandler("onVehicleEnter", root, function(player) local vehicle = source local id = getElementModel(vehicle) if id == 416 then local team = getPlayerTeam(player) if team then local teamName = getTeamName(team) if (teamName) == "Medic" then outputChatBox("((* Don't abuse your lights! *))", player) else removePedFromVehicle(player) outputChatBox("((* You are not allowed to get in here! *))", player) end else removePedFromVehicle(player) outputChatBox("((* You are not allowed to get in here! *))", player) end elseif id == 420 then local team = getPlayerTeam(player) if team then local teamName = getTeamName(team) if (teamName) == "Taxi" then outputChatBox("((pickup people and bring them to their chosen place))", player) else removePedFromVehicle(player) outputChatBox("((*You are not allowed to get in here*))", player) end else removePedFromVehicle(player) outputChatBox("((* You are not allowed to get in here! *))", player) end end end )
  22. after checking your code: one thing is missing - players without team can drive ambulance.. rest is working ok (Medics can drive it, others teams can not)
  23. download my "tele" script from community.multitheftauto.com - my script is doing what you want i think, and you will see better way than looping through whole table (assigning string keys to tables)
×
×
  • Create New...