Jump to content

50p

Retired Staff
  • Posts

    2,973
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by 50p

  1. 50p

    Image

    I don't quite understand you.
  2. 1. You don't want to trigger the event for every player, because that would create progress bar for every player: triggerClientEvent( player, "onTread", getRootElement() ) 2. Debug your createProgressBar function and check if it's called at all.
  3. This forum is English only. If you say something in your language, translate it to English.
  4. No you can't delete resources with commands because there is no such function available.
  5. 50p

    mapnames

    What was map name resource doing? And why did you show this code if everything is fine with it?
  6. Debug, Debug, Debug.
  7. OK, PM'ed. Example of usage: myXML = XML:Load( "file.xml" ); outputChatBox( myXML.Nodes[ 1 ]:Value( ) );
  8. Add setWaterLevel to your script... setWaterLevel( LEVEL ); -- replace LEVEL with your level
  9. 50p

    Leader

    Namorek, visit http://gtamscripting.info/ they may be able to help you.
  10. What do you mean you can't click it? showCursor if you can't see it. PS. Why did you come back? To spam the forum again? Ask stupid questions?
  11. What's the point of converting number to number then?
  12. Are you sure that account name is not the same as player name? Usually when players register they register with their name so account name will be the same as their name. Also, you use getAccount and use player's name for username (which is the account name) and then you getAccountName (of the account that you know the name already). Use getPlayerAccount instead: local who = getPlayerFromName (client); local account = getPlayerAccount( who );
  13. Yes. It's supposed to use as many addEventHandlers as many events for GUI there are. Why? Because it makes it easier for scripters to add functions to the GUI events. For instance, if you want to add a function to "OnClick" event, you simply do, button:AddOnClick( functionName ) this will simply attach functionName to OnClick event. Isn't it simpler than addEventHandler( "onClientGUIClick", buttonGUI, functionName, false ) That's the whole purpose of libraries. EDIT: Piotr1, I made an XML Lib too. It makes reading/writing XML files easier too. If you need it just PM me and I'll send you the lib. If I remember correctly, it hasn't been finished yet but for simple read/write functionality it works fine.
  14. How many times do I have to tell you? Do NOT name any function parameters client if the function is called by triggerServerEvent.
  15. type="server" is not required if the script is server-side. If script is client-side then type="client" is necessary.
  16. 50p

    weird problem

    Use my code... As you can see, there is new player variable and client is changed to playerName.
  17. 50p

    weird problem

    ok, i changed to repairVehicle as function name but still same problem with getPedOccupiedVehicle, this is the error. Bad argument @ "getPedOccupiedVehicle" Your client parameter will be string (player's name from grid list, I suppose), this will also overwrite MTA's client variable which is passed to server event with triggerServerEvent. Just rename the parameter name to something more like what the argument will be (like playerName) and inside the function getPlayerFromName. Also, change all the client to player and try this code: function repairVehicle( playerName ) local player = getPlayerFromName( playerName ); -- rest of your code ... end
  18. 50p

    weird problem

    When you create a function with the name of one native MTA function, you overwrite it.. That will make MTA fixVehicle function unavailable... Be careful when naming your functions.
  19. he wasnt asking for this O_o, he asked for a character system maybe? Oh, well, it was hard to understand him and from the picture I couldn't understand it either.
  20. Stop spamming and behave. I may release my spawn script that has been running on FREESTATEPROJECT server. If anyone has ever played there, then you know what I mean. It was/is pretty nice script and admins can set their teams/factions in an xml file. But I'll release it only if I'll see more people requesting spawn scripts.
  21. It's not good idea to loop through the grid list and remove the row which has name of the player but instead I'd make a table of players and hold their row id in that table. Something like: plrIDs = { }; -- table of players and their row IDs -- when you add new row add the player to the table and set row id local tempRow = guiGridListAddRow( playerList ); plrsIDs[ source ] = tempRow; -- then, when player leaves the server it's easier and quicker to remove specific row: guiGridListRemoveRow( playerList, plrsIDs[ source ] ); plrsIDs[ source ] = nil; -- this is also easier to change text of cell when player changes his name: guiGridListSetItemText( playerList, plrsIDs[ source ], playerColumn, newNick, false, false );
  22. 50p

    Skins

    You need a few applications: - TXD Workshop or G-TXD - Image editing application (Photoshop, Gimp, etc.) - original .txd file from gta3.img that you can get with IMG Tool or any other GTA archive tool - and a little knowledge about Lua to replace the skin Is this what you wanted?
  23. Yes that's what you should do. Client->Server->Client But if you want to add players to grid list when resource starts, you can use getElementsByType to get all players connected to the server and add them to the grid list with a loop.
×
×
  • Create New...