DiSaMe Posted August 27, 2008 Share Posted August 27, 2008 First of all, I want to say I DO know client-side can't control server-side elements. But would there be any visible effect? For example, if I put non-local player into other position, would I see him there at least for one frame? I ask this because I want to make well synced position script that would show players in their estimated position like we shoot to the front of running players, not to them. But if it's not possible to do this, then it's a suggestion about better sync to implement into MTA Link to comment
Gamesnert Posted August 27, 2008 Share Posted August 27, 2008 For example, if I put non-local player into other position, would I see him there at least for one frame? Non local players? EDIT: Oh other players. In a client-side script? I don't think it's possible. Link to comment
=FAS=Shigawire Posted August 27, 2008 Share Posted August 27, 2008 First of all, I want to say I DO know client-side can't control server-side elements Whats with the "TriggerServerEvent" function? Or did i missunderstand your qustion? Link to comment
Gamesnert Posted August 27, 2008 Share Posted August 27, 2008 First of all, I want to say I DO know client-side can't control server-side elements Whats with the "TriggerServerEvent" function? Or did i missunderstand your qustion? You misunderstood it I think. Link to comment
haybail Posted August 27, 2008 Share Posted August 27, 2008 You could move them, can't you, and it would be visible. Just they'll flick back as the server syncs them. Unpractically you may be able to do something but it would look fruity. Like onClientRender setElementPosition but you couldn't get the proper cords from the real client cause that would take too long, and defeat the purpose, and estimating would be very difficult I suppose. Or you could be clever. It is possible to fix the sync, however. Or change it so theres less problems. Link to comment
DiSaMe Posted August 27, 2008 Author Share Posted August 27, 2008 You could move them, can't you, and it would be visible. Just they'll flick back as the server syncs them.Unpractically you may be able to do something but it would look fruity. Like onClientRender setElementPosition but you couldn't get the proper cords from the real client cause that would take too long, and defeat the purpose, and estimating would be very difficult I suppose. Or you could be clever. It is possible to fix the sync, however. Or change it so theres less problems. yeah, this is EXACTLY what I wanted to know. Thanks for the information. I think it would be possible to sync position by doing xpos + xvelocity*(other_player's_ping+local_player's_ping). Car position sync is important too. It would let to do P.I.T. and make drive-bys cool. Link to comment
Mr.Hankey Posted August 27, 2008 Share Posted August 27, 2008 I think it would be possible to sync position by doing xpos + xvelocity*(other_player's_ping+local_player's_ping). Car position sync is important too. It would let to do P.I.T. and make drive-bys cool. lol that would be like disabling half of the netcode that makes mta's sync so good^^ Link to comment
DiSaMe Posted August 27, 2008 Author Share Posted August 27, 2008 I think it would be possible to sync position by doing xpos + xvelocity*(other_player's_ping+local_player's_ping). Car position sync is important too. It would let to do P.I.T. and make drive-bys cool. lol that would be like disabling half of the netcode that makes mta's sync so good^^ No, it disables nothing, it makes sync even better. I do this line of code in my brain when I'm shooting and I choose much better position than super perfect wonderful (no, I don't say it's bad) MTA sync does. And script could even do better. It would be an add-on to the sync Link to comment
Gamesnert Posted August 27, 2008 Share Posted August 27, 2008 I think it would be possible to sync position by doing xpos + xvelocity*(other_player's_ping+local_player's_ping). Car position sync is important too. It would let to do P.I.T. and make drive-bys cool. lol that would be like disabling half of the netcode that makes mta's sync so good^^ No, it disables nothing, it makes sync even better. I do this line of code in my brain when I'm shooting and I choose much better position than super perfect wonderful (no, I don't say it's bad) MTA sync does. And script could even do better. It would be an add-on to the sync Sorry mate, but I don't really think synch will improve with this... If there is any change in position, it's directly passed through client-server-client. I think doing this will only increase the use of bandwidth, and maybe even lag the PC's themselves too. I don't know how it exactly works, but I do know it won't just simply work with a small script... =/ Link to comment
DiSaMe Posted August 27, 2008 Author Share Posted August 27, 2008 Sorry mate, but I don't really think synch will improve with this... If there is any change in position, it's directly passed through client-server-client. I think doing this will only increase the use of bandwidth, and maybe even lag the PC's themselves too. I don't know how it exactly works, but I do know it won't just simply work with a small script... =/ you misunderstand this. This has no influence on bandwidth. Not even a byte would be transfered between client and server. Position changes in client's side and goes back after one frame. Just because script is small, it doesn't mean it can't help. At least problem is small too - some player is shown a little bit to the side from where he exactly is. Big thing, huh? So we can use a small script that corrects this small problem. Link to comment
Gamesnert Posted August 27, 2008 Share Posted August 27, 2008 Sorry mate, but I don't really think synch will improve with this... If there is any change in position, it's directly passed through client-server-client. I think doing this will only increase the use of bandwidth, and maybe even lag the PC's themselves too. I don't know how it exactly works, but I do know it won't just simply work with a small script... =/ you misunderstand this. This has no influence on bandwidth. Not even a byte would be transfered between client and server. Position changes in client's side and goes back after one frame. Just because script is small, it doesn't mean it can't help. At least problem is small too - some player is shown a little bit to the side from where he exactly is. Big thing, huh? So we can use a small script that corrects this small problem. Ooooooh! I thought you were talking about real synch! Still, I give it a 70% guarantee it works. Because it might be that the position is bad transferred. Or isn't that how it works? Link to comment
Ace_Gambit Posted August 27, 2008 Share Posted August 27, 2008 This would totally mess up the MTA synchronization and make it even worse. You can move a player client side but the other client would still process its own position. In short, this idea makes no sense. Link to comment
Gamesnert Posted August 27, 2008 Share Posted August 27, 2008 This would totally mess up the MTA synchronization and make it even worse. You can move a player client side but the other client would still process its own position. In short, this idea makes no sense. As he said, for some reason MTA seems to draw some things in the incorrect coordinates, but still the client does know the right coordinates. That was his idea. But it's starting to get a bit strange... I think half the theory might be correct, other half that there is no way... Stop confusing me... Anyway, just try it. We'll see the results! Link to comment
DiSaMe Posted August 28, 2008 Author Share Posted August 28, 2008 Yeah, I will try it. But only when I return home. I'm in the countryside right now and I'm using my mobile phone to post here Link to comment
Ace_Gambit Posted August 28, 2008 Share Posted August 28, 2008 As he said, for some reason MTA seems to draw some things in the incorrect coordinates, but still the client does know the right coordinates. That was his idea. But it's starting to get a bit strange... I think half the theory might be correct, other half that there is no way... Stop confusing me... Anyway, just try it. We'll see the results! That doesn't change the fact that adjusting the position of a remote player makes no sense imo. What ever client side change you make to a remote player only affects what you see. In other words, the newly calculated position for lead aim will always be relative. Link to comment
DiSaMe Posted August 28, 2008 Author Share Posted August 28, 2008 As he said, for some reason MTA seems to draw some things in the incorrect coordinates, but still the client does know the right coordinates. That was his idea. But it's starting to get a bit strange... I think half the theory might be correct, other half that there is no way... Stop confusing me... Anyway, just try it. We'll see the results! That doesn't change the fact that adjusting the position of a remote player makes no sense imo. What ever client side change you make to a remote player only affects what you see. In other words, the newly calculated position for lead aim will always be relative. yeah, it only affects what you see, this is what we all need because lag makes us see the past. When I am shooting, I always shoot not where I see player, but where he should be after bit of time. In this way I shoot accurately. In other words, this script already works when I use it in my mind. Now I only need to move it to MTA where position will be calculated even better. Link to comment
Gamesnert Posted August 28, 2008 Share Posted August 28, 2008 As he said, for some reason MTA seems to draw some things in the incorrect coordinates, but still the client does know the right coordinates. That was his idea. But it's starting to get a bit strange... I think half the theory might be correct, other half that there is no way... Stop confusing me... Anyway, just try it. We'll see the results! That doesn't change the fact that adjusting the position of a remote player makes no sense imo. What ever client side change you make to a remote player only affects what you see. In other words, the newly calculated position for lead aim will always be relative. yeah, it only affects what you see, this is what we all need because lag makes us see the past. When I am shooting, I always shoot not where I see player, but where he should be after bit of time. In this way I shoot accurately. In other words, this script already works when I use it in my mind. Now I only need to move it to MTA where position will be calculated even better. Oh stop with arguments already... THAT is something of the past! We want to see some results. We'll see if it has been a waste of time or not. Link to comment
DiSaMe Posted August 28, 2008 Author Share Posted August 28, 2008 Oh stop with arguments already... THAT is something of the past! We want to see some results. We'll see if it has been a waste of time or not. OK, OK, but as I said, I can't do it right now because I'm in the countryside. But when I return, I will try it. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now