Jump to content

50p

Retired Staff
  • Posts

    2,973
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by 50p

  1. If the object needs to exist at its place all the time then use map files instead.
  2. I've never experienced it in SP. If you have, that may be a problem with a graphic card not the game.
  3. Yeah, sure: http://www.lua.org/pil/2.html
  4. Make a variable which will enable/disable "god-mode" with the command. Then check if the variable is true or false, if it's true then cancel event.
  5. There is no way to check if sound is already playing. If MTA Devs accepted my patch, you'd be able to detect when the sound has stopped or started playing. Currently, there is no way to check if sound is being played.
  6. If I ware you varez, I'd change the "Move by vector (X)" to "X position offset"
  7. 50p

    Commands..!

    Last part of your sentence is void. It doesn't seem to be true.
  8. Custom maps should be made in the boundary of the SA map, that is, 3000 units in each direction of the center of the map (0,0). Don't go over 3000 or -3000.
  9. 50p

    Commands..!

    I don't see any hexadecimal numbers in here. Could you tell me which line has hexadecimal number because I think I'm blind? Remember to read wiki and try to understand how hex coloured text works. https://wiki.multitheftauto.com/wiki/OutputChatBox it's right at the top.
  10. Right... Locking the topic.
  11. 50p

    [REL]MTA Sites

    LOL, I don't know what this thing is but it's probably useless. Well, I have all MTA tabs open at all time (except for main website). Besides, if you're a scripter and use MTA:SE then you will get the websites in Help menu.
  12. What was wrong then? Tell us and then we can close the topic.
  13. Change type of what? Error message gives you a lot of hints on what if wrong with your code. You've probably forgotten about ")" somewhere, or you have too many of "(".
  14. Well, as far as I know, they all create a angle of 180 degrees.. Specify your question.
  15. What code are you talking about? Yes it's correct. I wonder why people don't use the 3rd parameter for addCommandHandler which is "restricted". There is no need for extra code, just change acl.xml a bit to block the command for everyone and let some groups use it. So simple and shortens the script.
  16. ... local balance = exports.bank:getBankAccountBalance( source ) -- make sure source is player element or account name ... ... function banklabel( balance ) guiSetText(DaPlayerBank,"Bank: $ " ..tostring(balance)) ...
  17. Well said, you "think".. https://wiki.multitheftauto.com/wiki/GetAccount https://wiki.multitheftauto.com/wiki/GetAccounts
  18. http://www.lua.org/manual/5.1/manual.html#pdf-tonumber You don't want to change the base parameter but string.gsub returns 2 values. One being the substring and the other the place (integer) at which the sub string starts. Both of these values are passed to your tonumber and it causes the error. Why? Because your base will be 1 (where $ is found), but you can't pass a value smaller than 2 and larger than 35. If you expect $ to be anywhere else than at start then you want to assign the first returned value from string.gsub to a variable and pass it to tonumber later but if you expect the $ to be as the first character then you can use this method instead: tonumber( string.sub( "$900", 2, -1 ) )
  19. Bank resource has a number of exported functions, 2 of them are: setBankAccountBalance( player or accountName, newBalance ) getBankAccountBalance( player or accountName ) They are obviously server-side functions to be safer.
  20. 50p

    Scripting Help!

    Just export that function from admin resource and call it from your resource...
  21. Not necessarily. Events handlers are called asynchronously, that is, first function added to an even doesn't always mean it will be called first. Anyway, what's the point of hiding a window and a millisecond later showing it? I think this GUI tutorial on wiki needs to be changed to give proper tips. Unfortunately I barely get time to reply here recently so I don't have time to make it look better.
  22. It's a known bug since early DP releases but hasn't been fixed yet. I would suggest you do it client-side - use onClientRender and change the position of the colshape or marker to where the vehicle is at the moment. After all, that's what MTA does with attached elements if not a timer.
×
×
  • Create New...