tag:blogger.com,1999:blog-7523569453469773247.post7899203228296537503..comments2015-02-11T12:13:10.578+01:00Comments on Laterna Magica: MtG programming: UndoUnknownnoreply@blogger.comBlogger3125tag:blogger.com,1999:blog-7523569453469773247.post-62051274352894540582010-05-15T10:09:00.830+02:002010-05-15T10:09:00.830+02:00implementing undo and enabling the user to undo ar...implementing undo and enabling the user to undo are two different things ;)<br />for example, I use undo to rollback the state if a plaer fails to play a spell. say, he can't pay the mana cost. undo is also very helpful for AI searching.<br /><br />Nonetheless, I think undo is a feature that could be enabled for the user, at least in single-player games, and depending on how good and fault-proof the UI is ;)<br /><br />replaying is a feature that comes easily from undo, and only recording actions or also how they are reversed doesn't make that much of a difference<br /><br />I have still problems figuring out networking. Edits depend on the object they edit, but there is a separate one on the remote side...Silly Freakhttps://www.blogger.com/profile/09963238585847993157noreply@blogger.comtag:blogger.com,1999:blog-7523569453469773247.post-54117250853791226372010-05-14T16:14:28.647+02:002010-05-14T16:14:28.647+02:00Is it really necessary to undo everything?
One of...Is it really necessary to undo everything?<br /><br />One of the skillful aspect of MTG is the fact that you don't do mistake. If you play at a tournament, your opponent won't let you undo anything you do and even while playtesting, undoing influenciates the flow of the game. I played MTGO for a while and I never missed an undo feature. <br /><br />The only undo action I think it's acceptable is the mana tapping but even that, if the rules says you can't untapped, then you can't.<br /><br />About replays, i would probably only record the actions that were peformed. In the same way you have the GUI, Player and Network that interacts with the rules engine API, you will also have a 4th actor called Replay that will do the same thing. <br /><br />Well, it just my view on things...<br /><br />So... in the end I think the "undo" feature is really questionable.Bruno Cardosohttps://www.blogger.com/profile/14130237535875418661noreply@blogger.comtag:blogger.com,1999:blog-7523569453469773247.post-91583199811471009202009-12-18T09:35:41.126+01:002009-12-18T09:35:41.126+01:00yep, I'm starting to realize that I have to fi...yep, I'm starting to realize that I have to find all such small pieces that changes game state and make undo only for them.<br />it is more or less easy for game actions as all handled now by GameManager. but this is not true for permanent states, as they can be changed directly from card implementation. so I have<br />GameManager.dealDamage(target, 2, source) instead of card.addDamage(2) - that is good<br /><br />but still have card.addAttack(3) or card.addKeyword(KEYWORD_HASTE)<br /><br />now I think whether I should add methods to GameManager and restrict changing attributes directlynantuko84https://www.blogger.com/profile/15891352523600843744noreply@blogger.com