~ubuntu-branches/ubuntu/natty/freecell-solver/natty

« back to all changes in this revision

Viewing changes to devel_docs/devel_docs/devel_docs/strategies.txt

  • Committer: Bazaar Package Importer
  • Author(s): RISKO Gergely
  • Date: 2005-03-30 20:12:47 UTC
  • mfrom: (1.1.1 upstream) (2.1.1 warty)
  • Revision ID: james.westby@ubuntu.com-20050330201247-8qdt6jhg7kxr3gjy
Tags: 2.8.10-1
* New upstream release
* fixed override disparity

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
Built by Suit/Built by Alternate Colour:
2
 
=============================================
3
 
 
4
 
Define a fcs_is_parent_card(child, parent) macro, accordingly, and use it 
5
 
wherever appropriate:
6
 
 
7
 
move_freecell_cards_on_top_of_stacks: 671.
8
 
 
9
 
Also make sure that the stuff with the foundations returning 
10
 
PARENT_STATE_IS_NOT_SOLVEABLE is set.
11
 
 
12
 
Multiple Decks:
13
 
===============
14
 
 
15
 
Define a MAX_DECKS macro, and implement storage for multiple decks in 
16
 
fcs_state_t. Then, make sure all the decks checks are made with loops.
17
 
(search for fcs_deck).
18
 
 
19
 
 
20
 
Empty Stacks:
21
 
=============
22
 
 
23
 
If by any card: 
24
 
---------------
25
 
 
26
 
keep the algorithm as it is.
27
 
 
28
 
If cannot at all: 
29
 
----------
30
 
 
31
 
calc_max_sequence_move = (num_freecells+1)
32
 
 
33
 
In move_non_top_stack_cards_to_founds: 
34
 
Check only if the freecells can be filled
35
 
 
36
 
In move_stack_card_to_parent_on_the_same_stack:
37
 
Ditto.
38
 
 
39
 
In move_stack_cards_to_different_stacks:
40
 
Ditto.
41
 
 
42
 
In move_cards_to_a_different_parent:
43
 
Ditto.
44
 
 
45
 
move_sequences_to_free_stacks:
46
 
Eliminate completely
47
 
 
48
 
move_freecell_cards_to_empty_stack:
49
 
Eliminate completely
50
 
 
51
 
empty_stack_into_freecells:
52
 
Elminate completely.
53
 
 
54
 
 
55
 
If Kings Only:
56
 
--------------
57
 
 
58
 
calc_max_sequence_move = 
59
 
(num_freecells+1) + 
60
 
(((top_card==KING)&&(num_freestacks>0)) ? 1 : 0)
61
 
 
62
 
In move_non_top_stack_cards_to_founds: 
63
 
Check only if the freecells can be filled
64
 
 
65
 
In move_stack_card_to_parent_on_the_same_stack:
66
 
Ditto.
67
 
 
68
 
In move_stack_cards_to_different_stacks:
69
 
Ditto.
70
 
 
71
 
In move_cards_to_a_different_parent:
72
 
Ditto.
73
 
 
74
 
move_sequences_to_free_stacks:
75
 
Kings Only
76
 
 
77
 
move_freecell_cards_to_empty_stack:
78
 
Kings Only
79
 
 
80
 
empty_stack_into_freecells:
81
 
Move to last place.
82
 
 
83
 
 
84
 
 
85
 
(Un/)Limited Sequence Move
86
 
==========================
87
 
 
88
 
Unlimited sequence move:
89
 
------------------------
90
 
 
91
 
calc_max_sequence_move == MAX_INT
92