New puzzle: `Inertia', originally written for Windows by Ben

Olmstead and reimplemented with the help of his source code which he
was kind enough to release into the public domain.

[originally from svn r6222]
This commit is contained in:
Simon Tatham
2005-08-27 09:21:22 +00:00
parent 067f06053c
commit 622a5ff678
4 changed files with 1381 additions and 2 deletions

6
Recipe
View File

@ -28,7 +28,7 @@ LOOPY = loopy tree234 dsf
ALL = list NET NETSLIDE cube fifteen sixteen rect pattern solo twiddle ALL = list NET NETSLIDE cube fifteen sixteen rect pattern solo twiddle
+ MINES samegame FLIP guess PEGS dominosa UNTANGLE blackbox SLANT + MINES samegame FLIP guess PEGS dominosa UNTANGLE blackbox SLANT
+ lightup MAP LOOPY + lightup MAP LOOPY inertia
GTK = gtk printing ps GTK = gtk printing ps
@ -53,6 +53,7 @@ slant : [X] GTK COMMON SLANT
lightup : [X] GTK COMMON lightup lightup : [X] GTK COMMON lightup
map : [X] GTK COMMON MAP map : [X] GTK COMMON MAP
loopy : [X] GTK COMMON LOOPY loopy : [X] GTK COMMON LOOPY
inertia : [X] GTK COMMON inertia
# Auxiliary command-line programs. # Auxiliary command-line programs.
solosolver : [U] solo[STANDALONE_SOLVER] malloc solosolver : [U] solo[STANDALONE_SOLVER] malloc
@ -88,6 +89,7 @@ slant : [G] WINDOWS COMMON SLANT
lightup : [G] WINDOWS COMMON lightup lightup : [G] WINDOWS COMMON lightup
map : [G] WINDOWS COMMON MAP map : [G] WINDOWS COMMON MAP
loopy : [G] WINDOWS COMMON LOOPY loopy : [G] WINDOWS COMMON LOOPY
inertia : [G] WINDOWS COMMON inertia
# Mac OS X unified application containing all the puzzles. # Mac OS X unified application containing all the puzzles.
Puzzles : [MX] osx osx.icns osx-info.plist COMMON ALL Puzzles : [MX] osx osx.icns osx-info.plist COMMON ALL
@ -180,7 +182,7 @@ install:
for i in cube net netslide fifteen sixteen twiddle \ for i in cube net netslide fifteen sixteen twiddle \
pattern rect solo mines samegame flip guess \ pattern rect solo mines samegame flip guess \
pegs dominosa untangle blackbox slant lightup \ pegs dominosa untangle blackbox slant lightup \
map loopy; do \ map loopy inertia; do \
$(INSTALL_PROGRAM) -m 755 $$i $(DESTDIR)$(gamesdir)/$$i; \ $(INSTALL_PROGRAM) -m 755 $$i $(DESTDIR)$(gamesdir)/$$i; \
done done
!end !end

1323
inertia.c Normal file

File diff suppressed because it is too large Load Diff

2
list.c
View File

@ -23,6 +23,7 @@ extern const game dominosa;
extern const game fifteen; extern const game fifteen;
extern const game flip; extern const game flip;
extern const game guess; extern const game guess;
extern const game inertia;
extern const game lightup; extern const game lightup;
extern const game loopy; extern const game loopy;
extern const game map; extern const game map;
@ -46,6 +47,7 @@ const game *gamelist[] = {
&fifteen, &fifteen,
&flip, &flip,
&guess, &guess,
&inertia,
&lightup, &lightup,
&loopy, &loopy,
&map, &map,

View File

@ -1715,6 +1715,58 @@ CPU time and memory. Be warned!
} }
\C{inertia} \i{Inertia}
\cfg{winhelp-topic}{games.inertia}
You are a small green ball sitting in a grid full of obstacles. Your
aim is to collect all the gems without running into any mines.
You can move the ball in any orthogonal \e{or diagonal} direction.
Once the ball starts moving, it will continue until something stops
it. A wall directly in its path will stop it (but if it is moving
diagonally, it will move through a diagonal gap between two other
walls without stopping). Also, some of the squares are \q{stops};
when the ball moves on to a stop, it will stop moving no matter what
direction it was going in. Gems do \e{not} stop the ball; it picks
them up and keeps on going.
Running into a mine is fatal. Even if you picked up the last gem in
the same move which then hit a mine, the game will count you as dead
rather than victorious.
This game was originally implemented for Windows by Ben Olmstead
\k{bem}, who was kind enough to release his source code on request
so that it could be re-implemented for this collection.
\B{bem} \W{http://xn13.com/}\cw{http://xn13.com/}
\H{inertia-controls} \i{Inertia controls}
\IM{Inertia controls} controls, for Inertia
\IM{Inertia controls} keys, for Inertia
\IM{Inertia controls} shortcuts (keyboard), for Inertia
You can move the ball in any of the eight directions using the
numeric keypad. Alternatively, if you click the left mouse button on
the grid, the ball will begin a move in the general direction of
where you clicked.
All the actions described in \k{common-actions} are also available.
In particular, if you do run into a mine and die, you can use the
Undo function and resume playing from before the fatal move. The
game will keep track of the number of times you have done this.
\H{inertia-parameters} \I{parameters, for Inertia}Inertia parameters
These parameters are available from the \q{Custom...} option on the
\q{Type} menu.
\dt \e{Width}, \e{Height}
\dd Size of grid in squares.
\A{licence} \I{MIT licence}\ii{Licence} \A{licence} \I{MIT licence}\ii{Licence}
This software is \i{copyright} 2004-2005 Simon Tatham. This software is \i{copyright} 2004-2005 Simon Tatham.