獲得高級隱藏所有廣告
發表: 62   誰瀏覽過: 551 users
13.05.2020 - 13:53
I wanted to write this down somewhere, so here it goes: as Ivan stated back in 2015, there's really no %. There's no concept of "priority" in the code, just "order and random rolls".

We manage a list of Turn Actions for every player, and they're processed as follows. Let's assume player A attacked player B, while player B tried to run away:

1. Pick a random player.
2. Pick his next action (if any, if no more moves just pick another player). Let's assume player A's action is selected.
3. See where the stack wants to go (e.g attacking another city or unit, or just moving away). If he's not being attacked, complete the move successfully. Mark his target as "attacked".
4. Finish the action, and go again from step 1. Let's assume we now pick player B's Turn Action. He wants to move his units away.
5. Now, we check that this stack is being attacked and it is in defense position. We will calculate the chances of this stack being intercepted: we will roll a random number between 0 and 1. If the number is higher than (AttackerArmyCount / (DefenderArmyCount * 2)) [EDIT: the actual formula is AttackerArmyCount / DefenderArmyCount * 2, which is processed as (AttackerArmyCount / DefenderArmyCount) * 2. then the stack escapes.

This system has been in place for more than 3 years. Updates like this one from 2012 are either outdated or weren't implemented as-is. This explanation reveals lots of unintended behaviors, especially when you consider what a Turn Action really is. I hope it sheds some light for those interested in this system.

EDIT: please also check Dave's explanation for more details about this mechanic.
載入中...
載入中...
13.05.2020 - 13:57
作者: clovis1122, 13.05.2020 at 13:53

There's no concept of "priority" in the code


作者: clovis1122, 13.05.2020 at 13:53

2. Pick his next action

This is priority.

作者: clovis1122, 13.05.2020 at 13:53

AttackerArmyCount / DefenderArmyCount * 2

(AttackerArmyCount / DefenderArmyCount) * 2
or
AttackerArmyCount / (DefenderArmyCount * 2)
載入中...
載入中...
13.05.2020 - 14:04
作者: SuperiorCacaocow, 13.05.2020 at 13:57

作者: clovis1122, 13.05.2020 at 13:53

There's no concept of "priority" in the code


作者: clovis1122, 13.05.2020 at 13:53

2. Pick his next action

This is priority.


Sorry, we coders don't understand this userland jargon . All we know is that we receive a list of actions and we process them in order.
載入中...
載入中...
13.05.2020 - 14:04
So it's a lot about just getting lucky?
----
"You're aren't " - epic backflip
載入中...
載入中...
13.05.2020 - 14:05
I can feel all my past frustration of trying to explain turn blocking to players finally being at ease. Trying to tell people there isn't a set percentages and priority has been one of the most painful experiences in my life. The answer of it being down to luck was just never good enough for all these smart kids.
----
Lest we forget
Moja Bosna Ponosna
載入中...
載入中...
13.05.2020 - 14:05
If player A attacks B on move #1 and player B moves the stack on move #27 we get the same interaction?
載入中...
載入中...
13.05.2020 - 14:06
According to this AttackerArmyCount / (DefenderArmyCount * 2)
If the attacker has two times the size of the defender = attack is inescapable? Is that true tho?
載入中...
載入中...
13.05.2020 - 14:09
作者: blargh, 13.05.2020 at 14:05

If player A attacks B on move #1 and player B moves the stack on move #27 we get the same interaction?

So does the 1st move actually matter?
----
"You're aren't " - epic backflip
載入中...
載入中...
13.05.2020 - 14:21
作者: blargh, 13.05.2020 at 14:05

If player A attacks B on move #1 and player B moves the stack on move #27 we get the same interaction?


Yep. In this case, player A's attack is likely to be processed first, so player B will most likely reach step #5.

作者: NegTheEskimo, 13.05.2020 at 14:06

According to this AttackerArmyCount / (DefenderArmyCount * 2)
If the attacker has two times the size of the defender = attack is inescapable? Is that true tho?


Yes, this is true for step #5. Assuming Player A with 20 units attack Player B with 10 units, the only chance for B escape is by having his move processed first and skip step #5 (both 1st move and with 2 players only, this is about 50%).

作者: Muellertyme., 13.05.2020 at 14:09

作者: blargh, 13.05.2020 at 14:05

If player A attacks B on move #1 and player B moves the stack on move #27 we get the same interaction?

So does the 1st move actually matter?


Yes, this allows 5 units to escape against 100 units just by being processed first.
載入中...
載入中...
13.05.2020 - 14:33
 4nic
What
----
''Everywhere where i am absent, they commit nothing but follies''
~Napoleon


載入中...
載入中...
13.05.2020 - 14:36
Message deleted by clovis1122. Reason: Off-topic
載入中...
載入中...
13.05.2020 - 14:42
作者: clovis1122, 13.05.2020 at 13:53

I wanted to write this down somewhere, so here it goes: as Ivan stated back in 2015, there's really no %. There's no concept of "priority" in the code, just "order and random rolls".

We manage a list of Turn Actions for every player, and they're processed as follows. Let's assume player A attacked player B, while player B tried to run away:

1. Pick a random player.
2. Pick his next action (if any, if no more moves just pick another player). Let's assume player A's action is selected.
3. See where the stack wants to go (e.g attacking another city or unit, or just moving away). If he's not being attacked, complete the move successfully. Mark his target as "attacked".
4. Finish the action, and go again from step 1. Let's assume we now pick player B's Turn Action. He wants to move his units away.
5. Now, we check that this stack is being attacked and it is in defense position. We will calculate the chances of this stack being intercepted: we will roll a random number between 0 and 1. If the number is higher than (AttackerArmyCount / (DefenderArmyCount * 2)), then the stack escapes.

This system has been in place for more than 3 years. Updates like this one from 2012 are either outdated or weren't implemented as-is. This explanation reveals lots of unintended behaviors, especially when you consider what a Turn Action really is. I hope it sheds some light for those interested in this system.

are you sure?
i assumed any move a player makes is put on a queue
then the queue is dequeued for every player in the game in random order

for everyplayer
if queue length > 0
dequeue pick action
else
skip

this is why priority exists without being explicitly stated no?
載入中...
載入中...
13.05.2020 - 14:53
It would be easier if the turn block function was removed, I understand the reliance we've developed over the years on this element of the game, but it is time to cut loose and try new things... if we keep the turn blocks then they will confusing
----
Happiness = reality - expectations
載入中...
載入中...
13.05.2020 - 15:54
作者: gothboy, 13.05.2020 at 14:42

-
this is why priority exists without being explicitly stated no?


You're right in the sense that you could say the 'priority' is the moment in which you make your moves. I don't really mind the terminology if it helps people understand TBs, I just wanted to make it clear that this is not explicit in the code (e.g, there's no code that says "if this player move was done before the other, double his TBs chances").

It's not a queue btw. That could be a more efficient way to implement it. What we have right now is a sorted array.
載入中...
載入中...
13.05.2020 - 18:09
I am in no way an expert in programming and program languages... however, what I do understand here is that the game simply picks movements in whatever order luck wants it to be. Therefor, "priority" is just a matter of whichever code is first processed and not dependant on the player's movement priority decision?

Fk sake, I gotta go back to programming classes...

Could this mean that the biggest illustrative chance of tb you can ever get is 50%?
----
Don't ever look down on someone unless you're helping him up. Don't ever treat someone else the way you wouldn't want others to treat you.
We're all people.

載入中...
載入中...
13.05.2020 - 18:38
West pls
----
''People ask for criticism, but they only want praise.''
載入中...
載入中...
13.05.2020 - 23:32
作者: clovis1122, 13.05.2020 at 15:54

作者: gothboy, 13.05.2020 at 14:42

-
this is why priority exists without being explicitly stated no?


You're right in the sense that you could say the 'priority' is the moment in which you make your moves. I don't really mind the terminology if it helps people understand TBs, I just wanted to make it clear that this is not explicit in the code (e.g, there's no code that says "if this player move was done before the other, double his TBs chances").

It's not a queue btw. That could be a more efficient way to implement it. What we have right now is a sorted array.

how does the game determine which player's turn action is processed
載入中...
載入中...
14.05.2020 - 03:07
作者: gothboy, 13.05.2020 at 23:32

作者: clovis1122, 13.05.2020 at 15:54

作者: gothboy, 13.05.2020 at 14:42

-
this is why priority exists without being explicitly stated no?


You're right in the sense that you could say the 'priority' is the moment in which you make your moves. I don't really mind the terminology if it helps people understand TBs, I just wanted to make it clear that this is not explicit in the code (e.g, there's no code that says "if this player move was done before the other, double his TBs chances").

It's not a queue btw. That could be a more efficient way to implement it. What we have right now is a sorted array.

how does the game determine which player's turn action is processed



Here, with comments
載入中...
載入中...
14.05.2020 - 04:20
I have a question. Assuming that player moved troops from Izmair to Istanbul and from Istanbul to Kiev. Assuming that his opponent attacked Izmair how is it determined whether the battle would take placr in Izmair Istanbul or Kiev?

I assume it is determined by the location of the troops at the step of the battle player B ordained an attack. If so the priorities of order does matter to the location of the battle and chances of success. Because turnblocking 8 troops in Izmair at early stage of the turn is way more probable than turnblocking 80 troops in Istanbul at later stage. I am sure 99% of the players will swear that priorities so make a diffrence.
----


載入中...
載入中...
15.05.2020 - 08:00
I always thought it was something more like this.

If [player1 attack with 1 unit] = correct
If [player2 has 20+ units] = correct
tb = yes
載入中...
載入中...
11.12.2020 - 08:33
作者: clovis1122, 14.05.2020 at 03:07

Programming RNJESUS game

Bro, I know I'm late to the party, but this system is retarded, can we perhaps just remove the entire concept of tb vodoo and replace it with a systemwhere all moves just go through before any combat starts?

Alternatively make it less randomized and have more to do with the amount of troops attacking. like only 1/4th of the troops to be tb'ed can tb
----

載入中...
載入中...
11.12.2020 - 11:10
 Witch-Doctor (版主)
作者: Tirpitz406, 11.12.2020 at 08:33

作者: clovis1122, 14.05.2020 at 03:07

Programming RNJESUS game

Bro, I know I'm late to the party, but this system is retarded, can we perhaps just remove the entire concept of tb vodoo and replace it with a systemwhere all moves just go through before any combat starts?

Terrible, there's no longer any disadvantage to spamming pure offensive units because you can never be tbbed and punished for it.
載入中...
載入中...
11.12.2020 - 12:06
作者: Witch-Doctor, 11.12.2020 at 11:10

Terrible, there's no longer any disadvantage to spamming pure offensive units because you can never be tbbed and punished for it.

Then make offensive units weaker, should be anyways.
----

載入中...
載入中...
12.12.2020 - 11:16
So, here's my practicum for those of you who are totally confused by all this theory (like me):

1. Do all your attack moves first and yes, size does matter. And remember if you attack a city or resource, it doesn't really matter whether the unit you are attacking defends or runs. You still get the city.
2. Do all your non-attack moves second. Obviously you want to move large stacks before moving smaller or single unit stacks.
3. Build new units. Yes, there will be cases where you need to build the units so that they are available for an attack (step #1) or move (step #2).
4. Fortify (wall if you prefer) cities and resources.

Commodus
----
https://atwar-game.com/user/539231/signature.png
載入中...
載入中...
13.01.2021 - 08:12
作者: clovis1122, 13.05.2020 at 13:53

I wanted to write this down somewhere, so here it goes: as Ivan stated back in 2015, there's really no %. There's no concept of "priority" in the code, just "order and random rolls".

We manage a list of Turn Actions for every player, and they're processed as follows. Let's assume player A attacked player B, while player B tried to run away:

1. Pick a random player.
2. Pick his next action (if any, if no more moves just pick another player). Let's assume player A's action is selected.
3. See where the stack wants to go (e.g attacking another city or unit, or just moving away). If he's not being attacked, complete the move successfully. Mark his target as "attacked".
4. Finish the action, and go again from step 1. Let's assume we now pick player B's Turn Action. He wants to move his units away.
5. Now, we check that this stack is being attacked and it is in defense position. We will calculate the chances of this stack being intercepted: we will roll a random number between 0 and 1. If the number is higher than (AttackerArmyCount / (DefenderArmyCount * 2)), then the stack escapes.

This system has been in place for more than 3 years. Updates like this one from 2012 are either outdated or weren't implemented as-is. This explanation reveals lots of unintended behaviors, especially when you consider what a Turn Action really is. I hope it sheds some light for those interested in this system.


Sooo basically the more troops u have the higher the chance to turnblock?
載入中...
載入中...
13.01.2021 - 20:57
 Dave (管理員)
作者: taomerde, 13.01.2021 at 08:12

Sooo basically the more troops u have the higher the chance to turnblock?


Basically, yes.
----
All men can see these tactics whereby I conquer,
but what none can see is the strategy out of which victory is evolved.
--Sun Tzu

載入中...
載入中...
13.01.2021 - 21:03
作者: Dave, 13.01.2021 at 20:57

作者: taomerde, 13.01.2021 at 08:12

Sooo basically the more troops u have the higher the chance to turnblock?


Basically, yes.

i thought it capped out at 50% though?
----
載入中...
載入中...
13.01.2021 - 21:05
 Dave (管理員)
作者: PleaseMe, 13.01.2021 at 21:03

作者: Dave, 13.01.2021 at 20:57

作者: taomerde, 13.01.2021 at 08:12

Sooo basically the more troops u have the higher the chance to turnblock?


Basically, yes.

i thought it capped out at 50% though?


Yes that's true. The more troops you have the higher the chance to turnblock... upto a max chance of 50%.
----
All men can see these tactics whereby I conquer,
but what none can see is the strategy out of which victory is evolved.
--Sun Tzu

載入中...
載入中...
13.01.2021 - 21:10
作者: Dave, 13.01.2021 at 21:05

作者: PleaseMe, 13.01.2021 at 21:03

作者: Dave, 13.01.2021 at 20:57

作者: taomerde, 13.01.2021 at 08:12

Sooo basically the more troops u have the higher the chance to turnblock?


Basically, yes.

i thought it capped out at 50% though?


Yes that's true. The more troops you have the higher the chance to turnblock... upto a max chance of 50%.

can we delete turn blocks. no more luck all skill now
----
載入中...
載入中...
13.01.2021 - 21:15
 Dave (管理員)
作者: PleaseMe, 13.01.2021 at 21:10

can we delete turn blocks. no more luck all skill now


Tempting.... I'm afraid to touch it at the moment tho
----
All men can see these tactics whereby I conquer,
but what none can see is the strategy out of which victory is evolved.
--Sun Tzu

載入中...
載入中...
atWar

About Us
Contact

隱私條例 | 服務條例 | 橫額 | Partners

Copyright © 2024 atWar. All rights reserved.

加入我們在

將遊戲傳播出去!