Official Everybody Edits Forums

Do you think I could just leave this part blank and it'd be okay? We're just going to replace the whole thing with a header image anyway, right?

You are not logged in.

#1 2017-07-09 10:37:50

nopjaz
Member
Joined: 2017-06-25
Posts: 4

People lose connection when my bot is in the world?

Hello, it's me again, searching for advice.

I've got a unique bot idea and it's up and running, but the bot places a lot of blocks very quickly - if they went any slower the bot would be 'unresponsive' as most players are very, very impatient.
When people try to join my world, 90% of the time they have to join twice because they lose connection the second they join.
Is this my bot, or is it EE? Is there any way to stop overloading a player's client? Thanks in advance.

- nopjaz


Programmer Life:
"It doesn't work! Why?!"
"It works! Why?!"

Offline

#2 2017-07-09 10:41:53

Processor
Member
Joined: 2015-02-15
Posts: 2,210

Re: People lose connection when my bot is in the world?

It is EE, if the bot places a block while they are joining, their client will crash. Since EE is no longer receiving updates, you're out of luck //forums.everybodyedits.com/img/smilies/big_smile


I have never thought of programming for reputation and honor. What I have in my heart must come out. That is the reason why I code.

Offline

Wooted by:

#3 2017-07-09 10:46:38, last edited by LukeM (2017-07-09 10:53:05)

LukeM
Member
From: England
Joined: 2016-06-03
Posts: 3,009
Website

Re: People lose connection when my bot is in the world?

The speed you can send / recieve messages is based on your internet connection, this means that if you place a load of blocks while they are also connecting, you can disconnect (this can also happen if you place too fast when not connecting, but it has to be much faster).
So no its not EE, and its not an easy thing to fix with your bot. The best thing to do would probably be to just slow down placing blocks, or I guess you could only limit it while people are connecting (5 or so seconds after their 'add' message).
Depending on what you are doing, there could also be other fancy fixes, so if you could let us know what the bot does, then if I can think of a better way to fix it then ill let you know.

In response to Processor: Its not directly EE, its PlayerIO timing out if you recieve too many messages too quickly and cant process them all (I dont think the devs can fix this without using some hacky fix, like cacheing all messages until someone sends init2, then sending them slowly, or somehow multithreading the init message). I guess it could be fixed through PlayerIO (or by not using PlayerIO), but the disconnecting is there for a reason, and it could have a detrimental impact on other games if it were removed.

Offline

#4 2017-07-09 11:02:01

Processor
Member
Joined: 2015-02-15
Posts: 2,210

Re: People lose connection when my bot is in the world?

The issue with joining is a completely different one than PlayerIO's buffer overflow (which I wouldn't even consider a bug). There is a small window during join in which the EE client crashes if it receives any block placement messages.


I have never thought of programming for reputation and honor. What I have in my heart must come out. That is the reason why I code.

Offline

#5 2017-07-09 11:14:30

LukeM
Member
From: England
Joined: 2016-06-03
Posts: 3,009
Website

Re: People lose connection when my bot is in the world?

Processor wrote:

The issue with joining is a completely different one than PlayerIO's buffer overflow (which I wouldn't even consider a bug). There is a small window during join in which the EE client crashes if it receives any block placement messages.

Um... are you talking about an actual crash? Because if you are, since when has that happened, because thats never happened to me. Also, it doesnt sound to me that nopjaz is talking about a real crash, just a disconnect, which is probably the buffer overflow thing.

Offline

#6 2017-07-09 11:30:09

nopjaz
Member
Joined: 2017-06-25
Posts: 4

Re: People lose connection when my bot is in the world?

Yes, it is just a disconnect. I have had to problem myself when I connect as a guest, to see if my bot registers people properly. The world is about using commands to use pre-built templates to build a parkour defence - so when this happens is against my will. There is a period in the bot where no one can build anything (the raid period) and that's when most people can join. If it is the buffer overflow, increasing x in Thread.Sleep(x) seems like a good idea to me.


Programmer Life:
"It doesn't work! Why?!"
"It works! Why?!"

Offline

#7 2017-07-09 11:47:18

LukeM
Member
From: England
Joined: 2016-06-03
Posts: 3,009
Website

Re: People lose connection when my bot is in the world?

nopjaz wrote:

If it is the buffer overflow, increasing x in Thread.Sleep(x) seems like a good idea to me.

Either that, or if youve implimented it in a way that means you can slow down placements while people are joining, doing that

Offline

Wooted by:

#8 2017-07-09 12:04:43

Gosha
Member
From: Russia
Joined: 2015-03-15
Posts: 6,202

Re: People lose connection when my bot is in the world?

destroyer123 wrote:
Processor wrote:

The issue with joining is a completely different one than PlayerIO's buffer overflow (which I wouldn't even consider a bug). There is a small window during join in which the EE client crashes if it receives any block placement messages.

Um... are you talking about an actual crash? Because if you are, since when has that happened, because thats never happened to me. Also, it doesnt sound to me that nopjaz is talking about a real crash, just a disconnect, which is probably the buffer overflow thing.

When you crash you disconnect
I think we designed that way to show disconnected box after crash

Offline

Gosha1499598283667034

Board footer

Powered by FluxBB

[ Started around 1711713395.1127 - Generated in 0.041 seconds, 10 queries executed - Memory usage: 1.42 MiB (Peak: 1.54 MiB) ]