Adobe Director network game code

The game I am currently working is a multiplayer 'sidescroller' I did with adobe director 8.5.

Whenever you press the key to move your character, it sends a code to the opponent, and then you move it on the screen of the opponent.

However, it is very slow and laggy? How can I better script that kind of games in real time? I always used to make games RPG/touring base, it's new to me.

Here is an example of my project!

The first thing you need to check is, how many messages you send. When you send a lot of messages, they will be identified and a treatment. You can speed this up the by the processing of all messages in the message of mark only once.

 mcnt=pMuXtra.getNumberWaitingNetMessages()

 if mcnt>0 then
   pMuXtra.checkNetMessages(mcnt)
 end if

Maybe you should also think about changing your code a bit to control the players with the least amount of messages. Maybe not to send each image a message, but like all 5 seconds and interpolate the characters between these points. You will also find a lot of information on the internet on methods to minimize the number of necessary position updates.

Another thing is, you will never get rid of the LAG completely. You can try to pass TCP/IP to UDP for faster communication. UDP is faster, but the lost messages will be lost and not send again. It's good for the position updates and other things where you might lose a few messages. Anything that contains important information, must be using TCP/IP protocol.

Tags: Director

Similar Questions

Maybe you are looking for

  • synchronization settings iCloud causes interference with synchronization server

    Specification of the server: Mac Mini server (MacMini5, 3) 10.10.5 OSX Server 5.0.15 I had a very big problem with the synchronization settings iCloud interfering with my server synchronization. I'm in an office of 29 BYO Apple laptops in my Mac serv

  • Satellite C660 - no support OpenGL

    Hello everyone I have a Toshiba Satellite C660 core i 3 and I try a bit of motion graphics and when I try to use the 3D space in Photoshop, it is said that my PC does not support Open GL them more when I try to use a plug-in called 3-d element that i

  • Create thumbnails / resampling of image for DisplayImageFile?

    Hi all I tried to build a Panel to display several photos (50) to audit (double click to see the whole picture in a separate window) before downloading for final storage. I need to re - sample / vignettes about adapted to the control so that the memo

  • Formatting a new hard drive

    Just bought a new drive hard 500gig. If I use it as an external drive, I need to format it? I f I use it to replace the smallest disk in my Pavilion dv6910 and install the OS, I have to first format? Also, I just bought a HP 2000-2b10nr and think to

  • WCG200 Factory Reset - what happens?

    If I use the reset on the back of the WCG200 and reset to the original settings, the version of the firmware revert to the original version? Thank you!