Jump to content

Michael_Sund

Members
  • Posts

    161
  • Joined

  • Last visited

Everything posted by Michael_Sund

  1. umm, debugscript 3= this error: "debugscript: Incorrect client type for this command" ???wtf
  2. i believe this can be because i added the KIHC as include to my GM, and none of the new scripts i made isn't working and kihc is a bit weird too because i get wrnings and stuff in the console, and i can't use the most of the commands in it weird
  3. ok, sorry i haven't posted for years... but now i got probs again, i want to get some cash ingame but my snippet doesn't work function consoleGiveCash ( thePlayer, command, amount ) givePlayerMoney ( thePlayer, amount ) end addCommandHandler ( "givecash", consoleGiveCash )
  4. Not broken, broken, not broken, broken? instead of Blink, blink, blink?
  5. function createTeamsOnStart () teamCivilians = createTeam ( "Civilians", 194, 194, 194 ) teamCops = createTeam ( "LSPD", 101, 101, 215 ) teamArmy = createTeam ( "Army", 26, 51, 0 ) end addEventHandler ( "onResourceStart", getResourceRootElement(getThisResource()), createTeamsOnStart ) function assignCopTeam ( player, commandName ) setPlayerTeam ( player, teamCops ) giveWeapon ( player, 31, 10000 ) giveWeapon ( player, 24, 10000 ) giveWeapon ( player, 25, 10000 ) giveWeapon ( player, 29, 10000 ) giveWeapon ( player, 17, 10000 ) giveWeapon ( player, 42, 10000 ) setPlayerArmor ( player, 0 ) setPlayerSkin ( player, 280 ) setElementPosition( player, 1552.4109, -1675.0485, 16.1953 ) setPlayerNametagColor ( player, 101, 101, 215 ) end addCommandHandler ( "imacop", assignCopTeam ) function assignArmyTeam ( player, commandName ) setPlayerTeam ( player, teamArmy ) giveWeapon ( player, 30, 10000 ) giveWeapon ( player, 22, 10000 ) giveWeapon ( player, 27, 10000 ) giveWeapon ( player, 32, 10000 ) giveWeapon ( player, 16, 10000 ) giveWeapon ( player, 44, 10000 ) setPlayerArmor ( player, 100 ) setPlayerSkin ( player, 287 ) setElementPosition( player, 2725.2253417969, -2384.9313964844, 17.213558197021 ) setPlayerNametagColor ( player, 26, 51, 0 ) end addCommandHandler ( "loginarmy", assignArmyTeam ) function assignCivilian ( player, commandName ) setPlayerTeam ( player, teamCivilians ) takeAllWeapons ( player ) setPlayerArmor ( player, 0 ) setPlayerSkin ( player, 0 ) setElementPosition( player, 2230.8967, -1159.5858, 25.8268 ) setPlayerNametagColor ( player, 255, 255, 255 ) end addCommandHandler ( "civilian", assignCivilian ) function assignNewCivilian ( ) setPlayerTeam ( source, teamCivilians ) spawnPlayer( source, 2230.8967, -1159.5858, 25.8268 ) fadeCamera ( source, true ) setPlayerNametagColor ( player, 255, 255, 255 ) end addEventHandler ( "onPlayerJoin", getRootElement(), assignNewCivilian ) function afterWasted() respawnPlayer(source, getPlayerTeam(source)) end function respawnPlayer(player, theTeam) if (theTeam == teamCops) then giveWeapon ( player, 31, 10000 ) giveWeapon ( player, 24, 10000 ) giveWeapon ( player, 25, 10000 ) giveWeapon ( player, 29, 10000 ) giveWeapon ( player, 17, 10000 ) giveWeapon ( player, 42, 10000 ) setPlayerSkin ( player, 280 ) spawnPlayer ( player, 1552.4109, -1675.0485, 16.1953 ) setPlayerNametagColor ( player, 101, 101, 215 ) elseif (theTeam == teamArmy) then giveWeapon ( player, 30, 10000 ) giveWeapon ( player, 22, 10000 ) giveWeapon ( player, 27, 10000 ) giveWeapon ( player, 32, 10000 ) giveWeapon ( player, 16, 10000 ) giveWeapon ( player, 44, 10000 ) setPlayerArmor ( player, 100 ) setPlayerSkin ( player, 287 ) spawnPlayer ( player, 2725.2253417969, -2384.9313964844, 17.213558197021 ) setPlayerNametagColor ( player, 26, 51, 0 ) elseif (theTeam == teamCivilians) then spawnPlayer ( player, 2230.8967, -1159.5858, 25.8268 ) setPlayerNametagColor ( player, 255, 255, 255 ) end end addEventHandler( "onPlayerWasted", getRootElement(), afterWasted ) function onPayday ( ) givePlayerMoney ( getRootElement(), 7000 ) end function setPaydayTimer ( ) setTimer ( onPayday, 1800000, 0 ) end addEventHandler ( "onResourceStart", getRootElement(), setPaydayTimer ) function paydayTest ( player, commandName ) setTimer ( onPayday, 5000, 1 ) end addCommandHandler ( "testpay", paydayTest ) Hmm, almost everything works, but not the function respawnPlayer, it spawns me on the right location all the time, but i don't get the skinid, weapons and other stuff only get spawned help me!!!
  6. LOL i'm doing some c++ right now just started ut i was doing Visual Basic a time ago too =D
  7. lol i know all that but i don't know how to code it anyway i need more infop can't u give me an example?
  8. I'm not protecting him, but TroyRulz007 didn't take SA-MP down, it was SA-MP Administration who did it... They still exist & it was just a little setback... Hacking makes you :~ side of a game... I saw a youtube video about his website he tried to hack sa-mp? he's a bitch i play SA-MP because of many players and the ERP clan which have been hacked as hell their URL got stolen by some f*cking a**hole :@
  9. Michael_Sund

    .

    LO i thought ppl who was walking about sa-mp would et banned
  10. Make a game with AB's (instead of AI for the suckers who don't know what i mean ) I want the new Airtificial Bitch game
  11. Can i have some help to make a code for check which team a player is in and spawn the player in that team after he died and with the right weapons? LOL when i'm waiting for answer i can listen to this song: https://www.youtube.com/watch?v=H_zp4fsDrNA and this omg it's so sad, Dean in Supernatural why did he get to hell!?!? <----Sucks :@but this got me happy look at 2:16
  12. Thx very much man, I thought would have to script all day for onPlayerWasted because of the weird args, and setTimer i read on that a little bit more and understood what i should do , the timeconverting was made on this http://www.csgnetwork.com/timemath.html
  13. LOL can you help making a payday script i want everyone to have a special amount of money after been on server in a halfhour i didn't understand how to use that setTimer EDIT: I need a to respawn the player after he's wasted, how? Plz, help me!!!
  14. Hmm i got one problem because when someone joins the server everyone gets a "You are a civilian message" i could just delete it i don't think it's so important anyway That has to be because i have when a player joins the message sends to a player and i haven't specified which player it should go to so it sends to all players
  15. Ok, i'm one step forward on the team.lua it works good, no problems right now but there will be problems later on function createTeamsOnStart () teamCivilians = createTeam ( "Civilians", 194, 194, 194 ) teamCops = createTeam ( "LSPD", 101, 101, 215 ) teamArmy = createTeam ( "Army", 26, 51, 0 ) end addEventHandler ( "onResourceStart", getResourceRootElement(getThisResource()), createTeamsOnStart ) function assignCopTeam ( player, commandName ) setPlayerTeam ( player, teamCops ) giveWeapon ( player, 31, 10000 ) giveWeapon ( player, 24, 10000 ) giveWeapon ( player, 25, 10000 ) giveWeapon ( player, 29, 10000 ) giveWeapon ( player, 17, 10000 ) giveWeapon ( player, 42, 10000 ) setPlayerSkin ( player, 280 ) setElementPosition( player, 1552.4109, -1675.0485, 16.1953 ) outputChatBox( "You are now logged in as a Los Santos Police Department officer", source, 0, 255, 0 ) setPlayerNametagColor ( player, 101, 101, 215 ) end addCommandHandler ( "loginpolice", assignCopTeam ) function assignArmyTeam ( player, commandName ) setPlayerTeam ( player, teamArmy ) giveWeapon ( player, 30, 10000 ) giveWeapon ( player, 22, 10000 ) giveWeapon ( player, 27, 10000 ) giveWeapon ( player, 32, 10000 ) giveWeapon ( player, 16, 10000 ) giveWeapon ( player, 44, 10000 ) setPlayerSkin ( player, 287 ) setElementPosition( player, 1552.4109, -1675.0485, 16.1953 ) outputChatBox( "You are now logged in at Los Santos Army", source, 0, 255, 0 ) setPlayerNametagColor ( player, 26, 51, 0 ) end addCommandHandler ( "loginarmy", assignArmyTeam ) function assignCivilian ( player, commandName ) setPlayerTeam ( player, teamCivilians ) takeAllWeapons ( player ) setPlayerSkin ( player, 0 ) setElementPosition( player, 2230.8967, -1159.5858, 25.8268 ) outputChatBox( "You are a civilian", source, 0, 255, 0 ) setPlayerNametagColor ( player, 255, 255, 255 ) end addCommandHandler ( "civilian", assignCivilian ) function assignNewCivilian ( ) setPlayerTeam ( source, teamCivilians ) outputChatBox( "You are a civilian", source, 0, 255, 0 ) spawnPlayer( source, 2230.8967, -1159.5858, 25.8268 ) fadeCamera ( source, true ) setPlayerNametagColor ( player, 255, 255, 255 ) end addEventHandler ( "onPlayerJoin", getRootElement(), assignNewCivilian ) 54 lines
  16. Hmm ok everything works fine the only thing that's not working is when i spawn it puts the camera up on a mountain and i have to use freeroam to spawn -.-'
×
×
  • Create New...