Jump to content

50p

Retired Staff
  • Posts

    2,973
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by 50p

  1. 50p

    Problem...

    You want to cancelEvent() (cancel the onPlayerChat event) and output your own message.
  2. 50p

    Help file

    You said "don't require". "help.xml" file needs to be send to client so it is required. @Burger_Man Replace spaces in your map file name with "-" or remove them completely and do so in meta.xml as well and try again. This is the most common problem. If that won't help, make sure your help.xml file is in the resource's root directory.
  3. 50p

    Help file

    https://wiki.multitheftauto.com/wiki/Meta.xml
  4. If in doubt: http://www.lua.org/pil/11.2.html
  5. Loading and unloading of what?
  6. You don't have any values with "name" inside the upgradeType table, so table.find will always return false. I just now understood what you're trying to do... You want this: if not table.find( upgradeType, name ) then
  7. 50p

    Problem...

    Why don't you explain to him why it's client-side? Saying "yes, you have to put it into a clientside script file such as fr_client.lua" doesn't teach him at all. @BumbiS* Log in as an admin and use "debugscript 3" command to see any errors in your script (server-side and client-side). Check your server console to see if you have any server-side errors (only if you don't use debug window - debugscript command - because it's wasting time to switch between console and game to see the same thing as you see in debug window). You would get an error because getLocalPlayer does not exist on server-side.
  8. Why did you use: if not name == table.find ( upgradeType, "name", name ) then if I asked you to do: if not table.find ( upgradeType, "name", name ) then
  9. 50p

    Problem...

    You can leave server running and save any changes you make. Then you have to "restart " then server reloads the resource with the changes that you made.
  10. You can do: if not table.find( someTable, "name", name ) then
  11. What's the reason for not unzipping the resource? As you asked, you can't write to files (save configurations) which are zipped.
  12. 50p

    Problem...

    You can unzip them and edit the files inside them. When you extract, make sure you extract it to a folder under the same name as the zip because MTA server first tries to load resource from a folder and ignores the zip with the same name.
  13. 50p

    Problem...

    Make sure you edit resources in resources folder, not resource-cache. Also, you can't edit files in your client's folder, always edit resources that are on the server.
  14. What did you change? You changed absolutely nothing. @daKillar2000 There are a few problems with your script. - hawkcar1 will be string which you didn't use anywhere in the code - you have 2 commas in your upgrades table after 1001 - you didn't define car variable anywhere.. NOTE: When you use the same returned value twice then instead of calling function twice with same arguments, just assign returned value to a variable and reuse it later (look at your line 1 and 2). -- assign value to a variable: local carStr = getAccountData (getAccount(source), "car") if carStr then ...
  15. Custom vehicle collision is not supported by MTA. If it is, I must have missed it.
  16. [lua]yourcode here[/lua]
  17. -- server-side bindKey( player, "YOURKEY", "down", "spawnbot", "0 32" ); -- /spawnbot 0 32 or -- client-side bindKey( "YOURKEY", "down", "spawnbot", "0 32" ); -- /spawnbot 0 32
  18. This good? This is how you're supposed to ask for help.
  19. Why? https://forum.multitheftauto.com/viewtop ... 91&t=27027
  20. 50p

    /ss ??

    function setSkin(thePlayer,cmd,skin) skin = skin and tonumber(skin) -- skin will be "true" now if skin then -- skin=true, we are passing this setElementModel(thePlayer,skin) -- bad argument fadeCamera(thePlayer,true) end end addCommandHandler("ss", setSkin) skin will not be true.
  21. But you're not doing what you think you are... 'name' is string. name is a variable. See the difference. Have you even clicked at the links I gave you in previous post?
  22. If you know how SQL works, then what are you trying to do here: executeSQLUpdate ( "zKills", "player = 'name', rank = 'rank', kills = 'zombieKills'" )
  23. I can't give you straight answer and correct the code for you because you wouldn't learn at all but you need to learn SQL queries if you don't know how it works and what string is in programming/scripting languages. You also need to know what variables are and how to concatenate strings in Lua. I know there will be someone who will correct the code for you but I'm trying to teach you something.
×
×
  • Create New...