Jump to content

The_Ex

Members
  • Posts

    66
  • Joined

  • Last visited

Everything posted by The_Ex

  1. Well, if you add them onClientResourceStart, then it's added when downloading is done, that wouldn't be problem anyways.
  2. Didn't even put script file in meta? This is getting retarted.
  3. Yes, it cleans all the data but if you use 1st option by 50p and re-do the loop, players will be there, just clean it before you add them.
  4. Next time have a look at functions list... -> guiGridListClear You can also do loop through player list when you join(onClientResouceStart). Then add player onClientPlayerJoin and remove player from grid onClientPlayerQuit. This way grid will update even if adminpanel is opened.
  5. I'm not the one who accused you for stealing scripts, lol. Start with debugging your code. https://wiki.multitheftauto.com/wiki/Debugging (/debugscript 3 is NOT debugging in general)
  6. 2 years of MTA scripting experience? REALLY? Your mistakes are simple and stupid and seems like you just copy your script here when it doesn't work. Did you at least read the line which produces error? GUIEditor_Label[2] = guiCreateLabel(30,28,161,24,"Player money:"playerMoney,false,GUIEditor_Window[1]) You're missing .. GUIEditor_Label[2] = guiCreateLabel(30,28,161,24,"Player money:"..playerMoney,false,GUIEditor_Window[1])
  7. The_Ex

    text display

    The problem is that you are not passing player element to serverside. And why not to make everything serverside then? Server-client is pretty slow.
  8. The_Ex

    createobject

    Isn't this wrong topic for that problem? It should be like this setVehicleFrozen ( veh,not isVehicleFrozen ( veh) ) Have you ever visited wiki.multitheftauto.com? There's information about every single function with examples.
  9. Simple script would be creating a colshape. When onClientPlayerDamage is triggered check if element is within colshape and if attacker is player/ped and just cancelEvent() if it's true. That would cancel all the damage done to player.
  10. The_Ex

    createobject

    function showDisco () local Pnick = getPlayerName( source ) if ( getPlayerMoney (source) >= 0 ) then takePlayerMoney(source, 0) x,y,z = getElementPosition( source ) createObject ( 18102, x, y, z, 0, 0, 0 ) outputChatBox( Pnick.. " started the disco for $500, Have fun", source, 255, 255, 0, true) end end addCommandHandler("buy disco",showDisco) and takePlayerMoney(source, 0) Really? take 0?
  11. The_Ex

    Player gridlist

    It's pretty easy. -.- local players = getElementsByType("player") for k,v in ipairs(players) do local row = guiGridListAddRow(grid1) --grid1 is your grid... guiGridListSetItemText(grid1, row, 1,getPlayerName(v), false, false) end EDIT: This code should be executed when local player joins and just add players to grid or remove them when onClientPlayerJoin/onClientPlayerQuit is called.
  12. Jesse, create colShape around gates when someone hits colShape check if he has right skin then open the gates , close gates when he leaves. Open/close gates with moveObject. I've such script but i'm not interested in sharing only because you should at least try to do it yourself.
  13. Went to the forum because of curiosity. And there was loler applying for Head Scripter... That made me rofl hard. If you need head scripter, then no good scripters will join your project because they can make their own.
  14. The_Ex

    DD/DM WIN

    You don't know how to code/script and as far as i can see neither you pay some time to understand the code or learn from others. Start from the basics here: https://wiki.multitheftauto.com/wiki/Scr ... troduction You just ask for the solution... That's really WRONG.
  15. The_Ex

    timer :S

    this is really wrong. Have you ever thought about what each part of your code does?
  16. The_Ex

    sql save

    No, it shouldn't. Learn to use google for fucks sake... for i=0,12 do end
  17. The_Ex

    race loses

    Well, actually you haven't explained your code. We're not here to make guesses BUT my last guess is... As you mistyped onPlayerWasted in your code which you edited later then the thing you want might be: addEventHandler("onPlayerWasted",getRootElement(), function() setElementData(source,"Race Loses",getElementData(source,"Race Loses")+1) end ) Anyways, you need to explain the problem and give us more code to help you.
  18. The_Ex

    race loses

    onPlayerWasted doesn't sound like a player element. Change onPlayerWasted with winner as you use it for getElementData.
  19. Maybe spend some time studying table.sort not look for easier way to do it.
  20. onPlayerWasted has source (player who died) and argument (killer) so there shouldn't be any problems setting streaks/outputting messages or playing sounds for both of them. Just a little example: function checkKSandDS(ammon, attacker, weapon, bodypart) gCurrentKS[source] = 0 gCurrentDS[source] = gCurrentDS[source] + 1 if (attacker ~= false and attacker ~= source) then gCurrentKS[attacker] = gCurrentKS[attacker] + 1 gCurrentDS[attacker] = 0 end end addEventHandler("onPlayerWasted", getRootElement(), checkKSandDS)
  21. flemm, you can set no respawn and other settings by manually editing meta.xml of your race.
  22. Actually your script isn't safe, anyone who joins your server will get clientside scripts downloaded.
  23. http://development.mtasa.com/index.php? ... Attributes This function should make it easier, just look at example.
×
×
  • Create New...