Control the re-entering the game after CD

Developers and contributors can find a link to our github page and engage in development project planning here.
Post Reply
Message
Author
User avatar
Flame
Posts: 116
Joined: Tue Oct 24, 2017 6:16 am
Location: Ukraine
Karma: 70
Contact:

Control the re-entering the game after CD

#1 Post by Flame » Mon Dec 28, 2020 1:12 am

I know that it's already done in webDip sourse code.
Scripts control the player re-entering the game for another power after being kicked out due to CD.

Who can point me the file and the code-line where it is written down?
1

User avatar
Flame
Posts: 116
Joined: Tue Oct 24, 2017 6:16 am
Location: Ukraine
Karma: 70
Contact:

Re: Control the re-entering the game after CD

#2 Post by Flame » Mon Dec 28, 2020 10:27 am

I mean after CD the power is already taken by other player. And I want the code which prevents the old owner of the power to get into the game for another country.

User avatar
Flame
Posts: 116
Joined: Tue Oct 24, 2017 6:16 am
Location: Ukraine
Karma: 70
Contact:

Re: Control the re-entering the game after CD

#3 Post by Flame » Tue Dec 29, 2020 3:00 am

I didn't find this in webDip sourcecode too.
I think it is considered to be a bug.

A_Tin_Can
Lifetime Site Contributor
Posts: 283
Joined: Fri Sep 29, 2017 9:18 pm
Karma: 451
Contact:

Re: Control the re-entering the game after CD

#4 Post by A_Tin_Can » Tue Dec 29, 2020 5:49 am

I’m pretty sure it’s in there. I don’t have time to look right now, but I remember seeing the check in the join game code (have a look for anything that writes to the wd_members table). From memory, the check is not explicit, but implied.

If there’s a bug where you are able to take over another power when you CD, get taken over, and then someone else CDs, I think it would be the easy fix of checking the CD table too.

It would be easy to confirm that the code isn’t there by looking for everything that reads the CD table.

User avatar
Flame
Posts: 116
Joined: Tue Oct 24, 2017 6:16 am
Location: Ukraine
Karma: 70
Contact:

Re: Control the re-entering the game after CD

#5 Post by Flame » Tue Dec 29, 2020 8:04 am

A_Tin_Can wrote:
Tue Dec 29, 2020 5:49 am
I’m pretty sure it’s in there. I don’t have time to look right now, but I remember seeing the check in the join game code (have a look for anything that writes to the wd_members table). From memory, the check is not explicit, but implied.

If there’s a bug where you are able to take over another power when you CD, get taken over, and then someone else CDs, I think it would be the easy fix of checking the CD table too.

It would be easy to confirm that the code isn’t there by looking for everything that reads the CD table.
I see. Thank you for your reply.
Besides, I'm not sure banned users are out of halloffame.
Anyway I do this fix for Ru-server.

jmo1121109
Lifetime Site Contributor
Posts: 1099
Joined: Fri Sep 29, 2017 4:20 pm
Karma: 2944
Contact:

Re: Control the re-entering the game after CD

#6 Post by jmo1121109 » Wed Dec 30, 2020 6:05 am

I don't think it's a bug, if you check the comment on line 79 of webDiplomacy\board\member.php from Kestas you'll see this.

Code: Select all

/*
		 * Remove the CD mark from this person's record
		 * Someone could possible go into CD, be taken over, join another country, go CD again, then rejoin, so country has to be specified
		 */
Sounds like this was intended functionality on his part.

jmo1121109
Lifetime Site Contributor
Posts: 1099
Joined: Fri Sep 29, 2017 4:20 pm
Karma: 2944
Contact:

Re: Control the re-entering the game after CD

#7 Post by jmo1121109 » Wed Dec 30, 2020 6:06 am

jmo1121109 wrote:
Wed Dec 30, 2020 6:05 am
I don't think it's a bug, if you check the comment on line 79 of webDiplomacy\board\member.php from Kestas you'll see this.

Code: Select all

/*
		 * Remove the CD mark from this person's record
		 * Someone could possible go into CD, be taken over, join another country, go CD again, then rejoin, so country has to be specified
		 */
Sounds like this was intended functionality on his part.
That said, I could swear ATC is right and there is a check that was added later that was implied, but I only skimmed the code for 2 minutes to find this.

User avatar
Flame
Posts: 116
Joined: Tue Oct 24, 2017 6:16 am
Location: Ukraine
Karma: 70
Contact:

Re: Control the re-entering the game after CD

#8 Post by Flame » Wed Dec 30, 2020 9:16 pm

Thank you for attention to my request. I will continue the investigation ))
1

User avatar
Flame
Posts: 116
Joined: Tue Oct 24, 2017 6:16 am
Location: Ukraine
Karma: 70
Contact:

Re: Control the re-entering the game after CD

#9 Post by Flame » Tue Mar 22, 2022 12:47 pm

Flame wrote:
Wed Dec 30, 2020 9:16 pm
Thank you for attention to my request. I will continue the investigation ))
I have finally found this update and installed it. Thanks to everyone.
WebDiplomacy enthusiast. Adaptor of webdiplomacy variants: Classic Cataclysm, Classic 1898, Classic 1898 Fog of War, Punic Wars, Western World 901, 13th Century Mongolian Empire, Speed Europa, Minor Power.

Post Reply

Who is online

Users browsing this forum: No registered users and 35 guests