| Author |
Message |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 32 Registered: 10-2013
| | Posted on Wednesday, November 06, 2013 - 5:57 am: | |
how can i define a in-zone loss condition, like if youre on the give up zone you lose |
Sean Duggan (Dream)
New member Username: Dream
Post Number: 93 Registered: 9-2000
| | Posted on Wednesday, November 06, 2013 - 12:06 pm: | |
I think you'd be looking at loss-condition using the absolute-config option. You can find examples in either the Zillions Language Reference or the various ZRF files that come with the program. Or, if you can explain exactly what you want, I can make a suggestion. |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 33 Registered: 10-2013
| | Posted on Wednesday, November 06, 2013 - 3:57 pm: | |
I made a giveup zone, and added a move to the Kings, so if you place your King there you lose |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 34 Registered: 10-2013
| | Posted on Wednesday, November 06, 2013 - 4:21 pm: | |
And how can i forbid other pieces to entry there? |
Sean Duggan (Dream)
New member Username: Dream
Post Number: 94 Registered: 9-2000
| | Posted on Wednesday, November 06, 2013 - 7:39 pm: | |
There are two fairly simple ways I know of to do this. One is to add a check to all of the other piece's moves that checks for the forbidden zone before they add a spot. Probably an easier solution is to add the spot outside of the normal cardinal directions and only give the King that move. I guess the only qualm I'd have is that, at that point, what's the difference between forcing the King to move there and make them lose, and checkmating them? |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 35 Registered: 10-2013
| | Posted on Thursday, November 07, 2013 - 4:06 am: | |
Its complex, im thinking on a give up zone, but now different from 4 hours ago draft. I need to avoid lots of possible bugs, so it may not be so easy |
Sean Duggan (Dream)
New member Username: Dream
Post Number: 95 Registered: 9-2000
| | Posted on Thursday, November 07, 2013 - 2:26 pm: | |
Ah. I know how that is. Especially if you don't have someone in meatspace to bounce ideas off of, it's very tempting to just implement it in Zillions and then sic the AI on it. |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 36 Registered: 10-2013
| | Posted on Thursday, November 07, 2013 - 4:15 pm: | |
Now I want to put a command so a piece could only move if its King is not stalemated I try like this (verify not stalemated (King)) but marks errors How could I express that |
Sean Duggan (Dream)
New member Username: Dream
Post Number: 96 Registered: 9-2000
| | Posted on Thursday, November 07, 2013 - 4:23 pm: | |
Ah. That gets more complicated. stalemated exists as a goal condition for the entire board. I'm pretty sure that you'd have to find the King figure and then verify that it doesn't have any valid moves. There are some tricks you can do to keep track of where the King is, but you'd still need to do the various attacked? checks to verify that a given move wouldn't put the King in check, and that means move calculation is going to bog down tremendously. |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 37 Registered: 10-2013
| | Posted on Thursday, November 07, 2013 - 5:26 pm: | |
But these both Giveup and Draw pieces are outside the boardgame. I want to make sure that before moving outside you have legal moves inside. And also to be able to move outside at any moment of the game without losing your turn. Here an explanation how this works: (loss-condition (White Black)(absolute-config Giveup(V10))) ["WGiveup"-"Blank"-"BGiveup"] They move e or w (draw-condition (White)(relative-config Draw s (opponent Draw))) (draw-condition (Black)(relative-config Draw n (opponent Draw))) OUTSIDE ARRANGEMENT ["WD"-"Blank"-"KP"]KP=Killed Position ["KP"-"Blank"-"BD"] They move e or w too |
Sean Duggan (Dream)
New member Username: Dream
Post Number: 97 Registered: 9-2000
| | Posted on Friday, November 08, 2013 - 3:36 am: | |
Ah. So basically you just want a way for the computer or another player to be able to either concede or call for a draw? |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 38 Registered: 10-2013
| | Posted on Friday, November 08, 2013 - 4:49 am: | |
Yeah but without interfering with the game |
Sean Duggan (Dream)
New member Username: Dream
Post Number: 98 Registered: 9-2000
| | Posted on Friday, November 08, 2013 - 3:00 pm: | |
Hmm... I've seen games that offer this option as a piece off to one side, but I don't currently remember exactly which one and I never did it myself. If you look under <em>option</em>, "pass turn" will let you set a value of "forced" so that you can only pass if you have no moves, but I suppose that's the same as the draw. I think I'm actually going to have to ask you to further clarify what you mean because if you can only move these Draw/Concede counters when you have no other moves, how would you not lose your turn after moving them? I mean, there's no other piece you can move at that point. |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 39 Registered: 10-2013
| | Posted on Friday, November 08, 2013 - 3:16 pm: | |
Or maybe that If I, white, move outside a Draw the Black, my rival, is forced to move outside; and still if inside a(any owner) King is stalemated you can't move outside |
Mariano Moran Fougerat (Marianomf)
New member Username: Marianomf
Post Number: 40 Registered: 10-2013
| | Posted on Friday, November 08, 2013 - 3:17 pm: | |
But I don't know what easy this will be, these might be very complicated I think |