Ratings & Comments
Thanks a lot, HG! I was not expecting this so quickly. I am very gratefull!
I see the script line but not the desired effect!
Well, this was the easy part, so I thought I might as well do it immediately. I just had to replace 'imi' by 'imiTable[imi]' in the move generator, and make sure an initialized imiTable would always be present. The harder part is how to make it possible to specify an imiTable in a Diagram-specific way, as a parameter. (Probably using piece IDs, perhaps comma-separated to allow multi-character IDs, etc.)
Oh, I have forgotten to say. There is a bug with the joker again. Now it imitates the latest of the last piece moved by the opponent or the last piece clicked. Now your plate is full!
I don't understand what you mean. This happens in the Diagram I posted? Cnan you give an example of what exactly I have to do to see something irregular?
Is JKn=Jörg Knappen?
Click a piece then click Joker.
North Reliquary
But with shuffle.
OK, I see. But this is only in the start position, right?
I suppose there is a more serious issue where "works as designed" does not cover "works as desired": when a Joker is moved the other Joker in the next (half) move still imitates what that Joker imitated. Instead of the mapping of what it imitated.
Regarding my previous comment. I was not talking about the current work on transferring powers, but at an older issue.
It seems that the imitated move changes when I click a piece and not just when the opponent moves. This is undesirable.
Nice idea about the recursivitty of the transferrer.
But can you give an example where it happens? Is this a betzaNew.js problem or did betza.js already suffer from it?
I have sent my diagrams in an email.
OK, I see. The piece you click should have moves that get highlighted, in order for the Joker to imitate it. This was a consequence of introducing legality testing on highlighted moves, which must make the move first. I now save the old value of the imitated type before starting the legality test, and restore it afterwards. That should fix it.
Thanks!
I now also made it such that after a Joker move the imitated type is mapped to a new type as well, rather than staying the same. So the rule is that a Joker imitates the defined 'successor type' of the last moved or imitated piece type. Where by default the successor of each type is the type itself.
Swedish Cannon would be pR,mR
.
Must-capture Chess960
I changed the highlighting a bit in case of mandatory moves. Rather than not showing any moves for other pieces when there is a piece that must make a prioritized moves, it now shows the grey cross. This is more in line with how it treats pieces that cannot legally move because you have to resolve a check elsewhere.
It also helps to ameliorate a small imperfection that still exists in variants that have prioritized moves in combination with the checking rule. If the latter makes all prioritized moves illegal, the AI is smart enough to know that it should enable all non-prioritized moves. But the highlighting isn't, so the user would then have to play a move highlighted by a cross. Which will now still be handled as the corresponding pseudo-legal move prescribes, i.e. including possible side effects such as promotion or locust capture. Before I just removes the non-prioritized moves from the move list during highlighting. So that they were not highlighted, and if the user would play one, a new move, which would just move the selected piece without any side effects, would be synthesized and performed.
This looked like a great chess variant and got excited about it until I reached the rule saying "Capture is mandatory", which changed this great idea into a different version of "Antichess".
EDIT ...... I can't seem to add all the pieces in 'Pieces' section, so it is ok with me that they go into 'rules' etc, so, this release is ready to go thanks. I did set it for 'piece' category and not a 'game' but it seems to have changed, just noting it, should be like 'Fairy Pieces Part 1' in 'Piece' category.
Alright, this is ready for release. I had trouble adding all pieces into the 'pieces' section, it didn't seem to want me to add anymore, maybe I needed to delete other revisions, not sure now, but I did add the rest of the pieces in 'rules'. Should I go back and try to add the ones in 'rules' back into 'pieces'? Sorry for bother.
I would like to nominate this game as the featured chess variant for the next month. There are some rules I disagree with, but nevertheless, this remains a great game.
I wouldn't say that every game that has manditory capture is an 'anti-game'. International Draughts (and I suppose also Checkers) has an anti form where you win by getting stalemated (usually because you lost all your pieces, so you have nothing to move). But both the anti form and normal Draughts have mandatory capture.
So it seems the winning condition is more important for defining the character of the game than whether capture is mandatory or not. Of course mandatory capture is essential for winning by getting stalemated, as it would otherwise be impossible for a player that is so weak that he can be stalemated at all to force the strong player to do that. The characteristic of anti-games is that the means defeat the purpose.
BTW, it might be counter-intuitive, but pieces in Suicide Chess do have positive values, albeit somewhat different from classical values (e.g. e Queen seems to be worth 6 Pawns). If one of the players would start with his Queen removed he would lose very much more often than not.
25 comments displayed
Permalink to the exact comments currently displayed.
To get you going I have now made the preliminary change in betzaNew.js that it uses a predefined array 'imiTable' to decide what is imitated. If no such array is defined, the I.D. creates one, and initializes it as imiTable[i] = i for standard imitator behavior. It can be defined by embeded JavaScript in the page. (Which would then affect all Diagrams on that page!) In this comment I embedded:
<script>var imiTable = [0, 2, 3, 4, 5, 7, 6, 1];</script>This causes a move of type 1 (Pawn) to make the Joker move as 2 (Knight), etc. View in isolation, flushing browser cache to make it work!