Jump to content

Castillo

Retired Staff
  • Posts

    21,935
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Castillo

  1. This topic is in the wrong section, it should go in the "Scripting" section instead. Answer to your question(1): We don't accept requests here, I can give you a start but nothing else, you have to learn by yourself like we all did. addEvent("onZombieWasted",true) addEventHandler("onZombieWasted",root, function (killer) givePlayerMoney(killer,100) end) Wiki page: https://wiki.multitheftauto.com/wiki/Scr ... troduction Answer to your question(2): There aren't much free hosts, you can take a look in here: viewforum.php?f=116, but I would suggest buying one.
  2. This topic should go in the "Scripting" section. local x = 0 local y = 0 local z = 5 function onPlayerWastedRespawnPlayer() setTimer(spawnPlayer,1500,1,source,x,y,z,0,getElementModel(source)) end
  3. giveWeapon is only server side so, server side: function xxx ( thePlayer, commandName ) giveWeapon ( thePlayer, 2, 200 ) setPedWeaponSlot ( thePlayer, math.random ( 2, 200) ) end addCommandHandler ( "giveweapons", givePlayerWeapons ) function resourceStart () setGlitchEnabled ( "quickreload", true ) setGlitchEnabled ( "fastmove", true ) setGlitchEnabled ( "fastfire", true ) setGlitchEnabled ( "crouchbug", true ) end addEventHandler ( "onResourceStart", getResourceRootElement ( ), resourceStart )
  4. addEventHandler("onMarkerHit",marker, function (hitElement, matchingDim) if isPedInVehicle(hitElement) then return end if not matchingDim then return end local vehicle = createVehicle(411, x, y, z) warpPedIntoVehicle(hitElement, vehicle) end) Change x, y, z to the position where you want the vehicle to be created.
  5. Castillo

    Gamemode

    Well, maybe that game mode is not supported by AMX, try another?
  6. Copy the code again, I forgot something. P.S: What are you trying to achieve?
  7. No, to get a player name you do getPlayerName(playerElement). getPlayerFromName returns a player element from a player name.
  8. Firstly, try not to create two topics with the same question. local marker = createMarker ( x, y, z, "cylinder", 1.5, 255, 255, 0, 170 ) local blip = createBlip ( x, y, z, 33, 2, 255, 15, 75, 255, 0, 99999.0, getRootElement()) local ped = createPed( skin, x, y, z ) local pname = getPlayerFromName("x-Racer")
  9. Castillo

    Gamemode

    Oh, well, it's been long time since I don't use AMX, but if I'm right, you need to start AMX and the resource AMX created with the game mode file.
  10. Castillo

    Gamemode

    Do you mean game mode name? if so, you can use the function setGameType or just from the admin panel (default one, but is not permanent, so setGameType would be better). setGameType is used in a script server side.
  11. Make a marker with "finish" type?
  12. Oh, I get it now, maybe someone should create a program to make this easier, like doing from 0 to 50 and the program will auto complete it like: file0.png, file1.png etc.
  13. triplesnake, don't double post please.
  14. I don't understand what do you mean, I would put a timer to set teams, as the team may not be created before setPlayerTeam is executed, and that would return setting team to nil.
  15. Do you mean encrypt? if so, you'll need a LUA compiler. There are various here: viewtopic.php?f=91&t=31891
  16. I don't get your point, could you try to explain it again (with a better English if you can).
  17. Castillo

    sa-mp>mta

    No, you can't convert them, but you can use some of SA-MP (not 0.3) scripts in MTA using a resource called "AMX".
  18. function check(player) for o, data in pairs(Teams) do if not getTeamFromName(data[1]) then createTeam(data[1], getColorFromString(data[3])) end if string.find(getPlayerName(player), data[2]) then local team = getTeamFromName(data[1]) setPlayerTeam( player, team) for p,b in pairs(getAttachedElements(player)) do if getElementType(b)=="blip" then setBlipColor ( b, getColorFromString(data[3])) end end else setPlayerTeam(player, nil) end end end
  19. Oh, my bad, I didn't noticed about that .
  20. The command is /showhelp, you should change it to "help" if you want it like that.
  21. 1) You can do this using the functions: createPed setPedAnimation 2) You simple need to write in the chatbox or console /start zombies.
  22. My answer is No, don't you think you are being abussive? this is not a place where you requests and you get it done, start learning how to script by yourself. https://wiki.multitheftauto.com/wiki/Main_Page
  23. Would you tell me in which line? I'm not telephatic you know?
×
×
  • Create New...