Jump to content


kirisaku

Member Since 23 Oct 2009
Offline Last Active Apr 17 2013 05:54 PM

Posts I've Made

In Topic: 39.dll lag issue

09 June 2012 - 02:27 PM

I believe the problem was that only the server had setnagle(false) , so now I will try to add this to client also.

In Topic: 39.dll lag issue

06 June 2012 - 07:49 PM

Can you post the client receive code?


var temp_id,temp_x,temp_y,temp_spr,temp_img;
temp_id=readushort();
temp_x=readushort();
temp_y=readushort();
temp_spr=readushort();
temp_img=readbyte();
with(obj_player_other_parent)
{
    if (char_id==temp_id && sprite_exists(temp_spr))
    {
        x=temp_x;
        y=temp_y;
        sprite_index=temp_spr;
        image_index=temp_img;
    }
}

In Topic: Check if 2 keys are released at the same time

05 June 2012 - 07:49 PM

fixed, it actually checks all the released keys, problem was with the alarm, I switched to using script and everything was ok.

In Topic: 39.dll lag issue

05 June 2012 - 02:47 PM

omg, I just tried my idea, when not moving send another packet that is less sized. But still I get the lag...

Now I'm confused. Why sending location packet contentiously doesn't lag, but why I replace packet that is less sized(just packet header 1 byte) , I get lag.

In Topic: 39.dll lag issue

04 June 2012 - 08:45 PM

I've tested this not only with my application, but with others also.
I took example of "Doogie's 39.dll" more info here: http://gmc.yoyogames...pic=362963&st=0

His code contained:
Alarm[0]:

send_location(); //script that sends location 
alarm[0]=1; //so the location packet is sent continuously

What I had changed:
Removed the alarm[0]=1;
ant added in step event when movement keys are pressed then alarm[0]=1;

So I get the same result as in my application, when testing on 1 PC, the lag would not be seen at all,
But when other clients from other PC start to connect, the lag is seen to the one who is not moving(he receives packets slower).

So the reason is maybe because, when the internet line between 1 PC and other, is not continuously used, then the PC which does not send packets
gets other packets slower.

Quick lame fix for this issue that I thought would be:
make location packet to be sent continuously (adding alarm[0]=1, in alarm event).
Or to waste less recourse, create another packet with less size then location packet
and make it send when not moving(not sending location packet.)

So then again, please post any ideas, that you can think of, or other fixing solutions. It would be grateful.