A thread to track progress in the tool I'm making
  • 47 posts
  • Page 1 of 4
alunturner wrote:
https://art-visualiser.netlify.app/

Hi all,

Please use the above link to watch back any games you've played. It's still a work in progress that I work on from time to time. If you find anything that you think is an error, please let me know what the error is, which game it occurred in, and what sort of device and browser you were using.

Feel free to post responses here or message me directly.

Next on the list for things to add is a way to control the playback speed.

Alun
GriffinUcos wrote:
Well done Alun, excellent and just what I wanted. Runs on Chrome without problem. If you can slow it down a bit then a great tool for analysing play. Shows FOG games in clear.

"Gentlemen, when the enemy is committed to a mistake we must not interrupt him too soon."
The_Bishop wrote:
Woh great! Nice job.
Unfortunately in Capitals FOG games it shows negative numbers of troops.
And a go-back-one-step button is necessary.
«God doesn't play dice with the World» ~ Albert Einstein
jr502 wrote:
this looks really cool. some feedback. I replayed my game 1048939 and it showed all 4 territories in S. America as neutral but in the game they were not. There was no action in SA in the game. But red and blue each had a territory there and 2 neutrals. Hope this helps.
The_Bishop wrote:
I assume that it rebuilds the game from the game log, so if there was no moves done in South America it cannot know to which players belong each territory. Therefore they are in grey in alunturner's program: not really neutral, just not-known-colour. The more the game progress the more the greys disappear.
«God doesn't play dice with the World» ~ Albert Einstein
GriffinUcos wrote:
GriffinUcos
Well done Alun, excellent and just what I wanted. Runs on Chrome without problem. If you can slow it down a bit then a great tool for analysing play. Shows FOG games in clear.

I found the single step button, thanks. Intriguing, watching someone else's game and wondering why they did what they did. And, how they won!
"Gentlemen, when the enemy is committed to a mistake we must not interrupt him too soon."
alunturner wrote:
The_Bishop
I assume that it rebuilds the game from the game log, so if there was no moves done in South America it cannot know to which players belong each territory. Therefore they are in grey in alunturner's program: not really neutral, just not-known-colour. The more the game progress the more the greys disappear.

Quite right @The_Bishop. If the territory isn't fortified, attacked, or reinforced (as recorded in the log), the tool has no way of telling who owned it. Also, the cause of the issue with negative numbers in the capitals game will recur in all capitals games. It's because it assumes an initial distribution of 3 troops per territory which isn't the case in capitals. I'll figure out a way to fix that.

Current list of things to do/fix:

  • Way to adjust playback speed
  • Way to be able to step back through the events
  • Fix the initial troop distributions in capitals games
  • Way to be able to skip to specific rounds/players
  • A stats page that is visible after the game finishes

Please tell other players you play with about it - the more testing there is, the better it'll get for everybody.

Thanks,

Alun
Cireon wrote:
Hi Alan.

Maybe this will help with your capitals problem. This is the calculation we do to determine how many troops start on a capital:

10 + floor($numTerritoriesPerUser / 3)

$numTerritoriesPerUser is the number of territories every player starts with. This is generally

floor($numTerritoriesInMap / max($numPlayers, 3))
“This is how humans are: We question all our beliefs, except for the ones that we really believe in, and those we never think to question.”
- Speaker for the Dead, O.S. Card
Matty wrote:
alunturner
Quite right @The_Bishop. If the territory isn't fortified, attacked, or reinforced (as recorded in the log), the tool has no way of telling who owned it.
We expose the initial state of a game here - https://dominating12.com/game/100000/debug/first-state
Can your tool access that? Probably not.

Alternatively, you can use the latest state to view the territories that do not occur in the log by working your way backwards rather then forwards. We do expose the last state in the update state call (POST to https://dominating12.com/game/100000/play/update-state)
The body requres a last_update (unix timestamp, aka 1596125302) and the csrf token - hmmm, that's going to pose a problem as well.


@Cireon: I think it currently doesn't allow non-admins to view that api, do we want to expose something like this?
"Strength doesn't lie in numbers, strength doesn't lie in wealth. Strength lies in nights of peaceful slumbers." ~Maria
Cireon wrote:
I am happy to expose that API if we can spend some time building rate limiting to make sure requests to that API don't bring down our server (and we may even want to shut down the API entirely if the site is busy to prioritise users over external tools). I can look into this and report back.
“This is how humans are: We question all our beliefs, except for the ones that we really believe in, and those we never think to question.”
- Speaker for the Dead, O.S. Card
alunturner wrote:
I think exposing the API could be hugely useful in the future. For the time being though I'm happy to work on implementing the adjustments I highlighted using my current method (ie scraping the html from the /game/:game_number path, which I can access just fine).

I can get on with that without causing you any work. If a way for me to access the API was subsequently worked out I could them just replumb the way the data gets into my app which wouldn't be a huge task.

Alun



Dima wrote:
I love u thanks! ! !
"vorple: the real strategy comes when you cant just win cuz you got lucky and got the big card stack"
jr502 wrote:
what happens if you run the visualizer on an active game that is in play and not ended? does it work? does it interfere with the game?
alunturner wrote:
Hi jr502.

It won't interfere with anything on this website. It may not work particularly well though, as it needs a territory to have been mentioned in the log for it to know who initially owned each territory at the beginning of the game.

Have a go - the worst that will happen is that any territories that have not seen any action will be grey (unknown owner).

Alun