Jump to content

haybail

Members
  • Posts

    145
  • Joined

  • Last visited

Everything posted by haybail

  1. Just useless data. Don't make me so what it is. I can think of four ways to do it, what do you guys think? 1. triggerServerEvent. 2. triggerClientEvent > triggerServerEvent. 3. setElementData ( element, key, true ) 4. output to xml and read the data server side. Any good, any of them?
  2. Race requires ModifyOtherObjects in ACL also. I was follow something up I said earlier, don't worry about that bit
  3. haybail

    Script help

    getRootElement is in clientside too. You only make them server and client side in the meta, before you start the resource. By default, there serverside. onMarketHit, if you use getRoot it will trigger everytime someone hits a marker. However if you use the name of a marker, then it will only trigger when an element hits that specific marker. Thats what getRoot is for. Sort of all, or everything ( getRoot ) or specific ( a name ). onMarketHit, getRootElement(), onMarkerHit - will trigger for all markers marker = createMarker (0, 5, 1, "cylinder", 3, 255, 0, 0, 175) onMarkerHit, marker, onMarkerHit2 - will trigger only when something comes in contact with your marker.
  4. And if I couldn't? If for some reason the function broke or data was getting lost. If I had to get them client side, hypothetically. What would be the best way.
  5. haybail

    Script help

    I'm not sure exactly but I usually look at the information after eof. like the line number etc, and the error. Um, I think you forgot the "" around cylinder. And the comma at the end may be a problem.
  6. I dont want to say, its stupid. You will laugh at me But not that. There are some events I use clientSide that arn't serverSide but there not completly necessary. Just if you can, see if you can help me with this question, if not its ok. I'll figure something out If I wanted to, what is the best way of retrieving data from clients as fast and smoothly as possible? Regular data, pretend the player is walking and I want to send information back everytime the player walks so far a distance, sometimes twice or three times faster than 450ms. What is the best way of getting that data from the client to the server everytime he passes that distance? Would it be what I have now?
  7. Oh I see what you do! You put your resource under one of the groups, instead of adding the Defaults one by one as you go. DUH! I quess I never really looked before But back on topic, when you try the map editors did you try race? Race also requires the same function. Normally the first function people enable, I think.
  8. haybail

    Script help

    if you have $500 and you use givePlayerMoney, it will plus it on so say you do givePlayerMoney $250 it will be $500 + $250 = $750. Same but opposite for takePlayerMoney. setPlayerMoney doesn't and it will set the money as whatever you say so if you do $5000 and have on you $750 it will put it at $5000. If it was givePlayerMoney it would be $5750.
  9. The map editor in deathmatch? Is not released at the moment. I can't remember exactly what the message is when you click on it. Race has an older map editor which is included but you may have to switch some files around if you download 1.1.2. Its recommended you download and install 1.1.1 and then 1.1.2 on top of that.
  10. Oh um, the problem is, as I use it so heavily so often, it becomes unreliable and damaging to the server. And the reason I use it so much is to tell the server exactly what the client is doing. I thought it would be ok since its such a tiny peice of data. Like the server updating the players position. Is there a better way of transferring data between the client and the server so often without hurting it so much?
  11. Mmm, i'd still like to know You know I once used names to store information under knowing the risk. I waited for players to figure it out. At first one guy got it, he emailed me to tell me, nice guy. I told him to keep it hush. And then eventually someone got it who had bad intentions and started stealing accounts. Lol. And then it spread, quicker and quicker. So I switched to serials. But I think its fun to leave quirks and see how well players catch on. Normally there quite quick but sometimes they take a while. But I quess i'd rather take the risk and find out than play it safe all the time and never know.
  12. But there restricted to admins Of course if you enable them... is that what they mean? So functions are safe. Speaking of this stuff, is there a /mute command. In the acl theres one but mute does nothing. Was it removed?
  13. haybail

    Script help

    Good idea. its a little difficult at first but as you get it you'll get quicker. it becomes so easy u forget why u didn't get it in the first place
  14. What should I do? I need to tell the server what the client is doing. Is there another way?
  15. But its a function. How can they use it? Can they get into client scripts? Give me a worse case scenario so I can understand
  16. Hello, I have a script that uses heavily triggerServerEvent, so often so I have to put a delay, as it can go twice so fast nothing will happen. And I think it may be hurting the server. And its players. When I first tried the script, it caused network trouble and dropped players, even the entire server couple times. I did a test and this is what I have: Bit funny, one of the results. No crashes or network trouble but the only thing I really changed was 450 ms to 550 ms and some checks and outputs Worst offender: In sync ( majority of players, vast majority ): Tiny offset: Note: you look at the players in a row and how often they trigger. Below 450ms ( the minimum delay ) is unusual. Because there bypassing the delay. This is my code on the triggers: if not count then triggerServerEvent ( "onPlayerH", getLocalPlayer(), hE, 1 ) count = 0 setTimer ( onPlayerDelay, 450, 1 ) end And my delay: function onPlayerDelay ( ) if count > 0 then triggerServerEvent ( "onH", getLocalPlayer(), p, c ) setTimer ( onPlayerDelay, 550, 1 ) count = 0 else --outputChatBox ( "CLEAR" ) count = nil end end
  17. Can you explain? I'm struggling to see the harm, but of course I want to understand. What do you mean user objects?
  18. haybail

    Script help

    Its because of the source used in outputChatBox function. It makes it only visible to the player who switched their weapon. Like this: outputChatBox ( string text, [ element visibleTo=getRootElement(), int r=255, int g=255, int b=255, bool colorCoded=false ] ) visibleTo: This specifies who the chat is visible to. Any players in this element will see the chat message. See visibility. http://development.mtasa.com/index.php? ... putChatBox
  19. I think its a good idea. When your scripting them you can optionally turn on those preferences via the functions provided.
  20. haybail

    Script help

    It looks serverside, are you sure? You said you have the bank script, that does all the bank stuff you mentioned almost down to a tee. Did you manage to get it working?
  21. You could do moveable gates at the teams bases. And maybe a map file to accompany the script.
  22. They stay for race, not 1.1.2 Just say race, lol.
  23. There was intended to be, like keyboard controls, but it didn't make it and was put it off for a latter version. Like controller support.
×
×
  • Create New...