Author Topic: SendQuickly Issue / Usage Question  (Read 2724 times)

rxmarcus

  • Jr. Member
  • **
  • Thank You
  • -Given: 2
  • -Receive: 0
  • Posts: 62
    • View Profile
SendQuickly Issue / Usage Question
« on: September 07, 2017, 11:33:11 PM »
So in my game I've been sending player position using tno.SendQuickly.....
We had noticed with a few amount of players that their player position wasn't updating to other clients and today I realized it was because I was using SendQuickly. Now that I'm just using Send it is working for these users. If I'm not mistaken, SendQuickly uses UDP while Send uses TCP? Does that mean that these users that were having this issue had some compatibility issues with the UDP protocol?

Is it not wise to try and use SendQuickly for something like player position that I'm updating rather frequently? I need it to work with all players though so should I just be using Send?

cmifwdll

  • Global Moderator
  • Sr. Member
  • *****
  • Thank You
  • -Given: 0
  • -Receive: 149
  • Posts: 285
  • TNet Alchemist
    • View Profile
Re: SendQuickly Issue / Usage Question
« Reply #1 on: September 08, 2017, 12:02:11 AM »
Frequent but unimportant updates (like player position) is the intended usage for SendQuickly.

Did you forget to activate UDP on either the client or server?
Server has to be started with a -udp 5128 arg, and client has to call TNManager.StartUDP(rand(10k, 65k)) *after* connecting to the server.

rxmarcus

  • Jr. Member
  • **
  • Thank You
  • -Given: 2
  • -Receive: 0
  • Posts: 62
    • View Profile
Re: SendQuickly Issue / Usage Question
« Reply #2 on: September 11, 2017, 10:56:36 PM »
Thanks cmifwdll!
Just wanted to report back that I indeed had forgotten to call StartUDP in my OnConnect callback. It seems to be working fine with SendQuickly now!