Skip to content

Commit

Permalink
Bumped to 2.0.0, updating several documents
Browse files Browse the repository at this point in the history
  • Loading branch information
alexdantas committed Feb 14, 2014
1 parent dbdf937 commit b61a7c3
Show file tree
Hide file tree
Showing 9 changed files with 166 additions and 2,176 deletions.
4 changes: 3 additions & 1 deletion BUGS
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,13 @@ Known bugs and issues
---------------------

They're given a 5-star rating based on their importance.
If you ever find any bug on yetris, please message me! Contact info at README.
If you ever find any bug on yetris, please message me!
Contact info at README.

Current Bugs
------------

***** No actual High scores implemented! How can I do this?
*** If force the piece down, the falling time doubles.
** When the game ends, the animation leaves some blocks colored.
**** Cannot rotate pieces if it's way's blocked or on the corner.
Expand Down
21 changes: 21 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
All the changes are documented on the git history, so here's just the major ones

13-02-14 v2.0.0:
* Interface: Menus and Menu Items added. Now you can customize
settings in-game, along with the old way of editing
.ini files. Also, Pause Menu!
* Interface: The Main Menu has two nice Animations, with way
more to come. It's a nice display of animated
ASCII-art with colors.
* Gameplay: Game Profiles added! Now the settings are saved
to each user individually and one can change between
profiles easily.
* Development: Completely reprogrammed the code to C++.
The game's way more flexible now - some features
would be unfeasable in plain old C.
* Bugs: Fixed thousands of bugs introduced by myself when
converting to C++. So, in the end...
* Downgrade: No high score support for now. It'll take
quite some time to make it and save according to
game profiles.
* Downgrade: Scores are quite crippled, along with combos and
back-to-backs. They should be reimplemented soon.

26-01-14 v1.7.0:
* Gameplay: blocks on the board can be pushed on all 4 directions.
options on the config file.
Expand Down
2,003 changes: 4 additions & 1,999 deletions Doxyfile

Large diffs are not rendered by default.

13 changes: 6 additions & 7 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ Installing information for the game yetris.
This applies to GNU/Linux systems.
Microsoft Windows users have a precompiled executable.


# Installation

Briefly, the following shell commands should configure,
Expand All @@ -20,9 +19,9 @@ directories:

| Directory | What to store |
| ---------------------------- | -------------------------|
| `/usr/local/bin/` | Executable files |
| `/usr/games/` | Executable files |
| `/usr/local/share/man/man6/` | Man page |
| `~/yetris/` | User config and scores |
| `~/.local/share/yetris/` | User config and scores |

# Advanced Installation

Expand All @@ -39,9 +38,9 @@ This way, the file hierarchy will be:

| Directory | What to store |
| ------------------------------------ | -------------------------|
| `test/dir/usr/local/bin/` | Executable files |
| `test/dir/usr/games/` | Executable files |
| `test/dir/usr/local/share/man/man6/` | Man page |
| `~/yetris/` | User config and scores |
| `~/.local/share/yetris/` | User config and scores |

You can also specify an installation prefix other than `/usr/local`
by giving `make` the option `PREFIX=CUSTOM_PREFIX`, where
Expand All @@ -54,9 +53,9 @@ This way, the file hierarchy will be:

| Directory | What to store |
| -------------------------- | -------------------------|
| `test/dir/bin/` | Executable files |
| `test/dir/` | Executable files |
| `test/dir/share/man/man6/` | Man page |
| `~/yetris/` | User config and scores |
| `~/.local/share/yetris/` | User config and scores |

# Uninstallation

Expand Down
35 changes: 21 additions & 14 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

# General Info
PACKAGE = yetris
VERSION = 1.7.0
VERSION = 2.0.0
DATE = $(shell date "+%b%Y")

# Local source code information
Expand All @@ -59,9 +59,6 @@ MANDIR = $(MANROOT)/man$(MANNUMBER)
MANFILE = $(PACKAGE).$(MANNUMBER)
MANPAGE = doc/man/$(MANFILE)

SCORE_FILE = yetris.scores
CONFIG_FILE = config.ini

# Build info
EXE = $(PACKAGE)
CDEBUG = -O2
Expand All @@ -77,18 +74,21 @@ CXXFILES = $(shell find src -type f -name '*.cpp')
OBJECTS = $(CFILES:.c=.o) \
$(CXXFILES:.cpp=.o)

DEFINES = -DVERSION=\""$(VERSION)"\" \
-DPACKAGE=\""$(PACKAGE)"\" \
-DDATE=\""$(DATE)"\" \
-DSCORE_FILE=\""$(SCORE_FILE)"\" \
-DCONFIG_FILE=\""$(CONFIG_FILE)"\"
DEFINES = -DVERSION=\""$(VERSION)"\" \
-DPACKAGE=\""$(PACKAGE)"\" \
-DDATE=\""$(DATE)"\"

# iniparser stuff
INIDIR = deps/iniparser
INI_CFLAGS = -O2 -fPIC -Wall -ansi -pedantic -Wextra $(PLATFORM)
INI_OBJS = $(INIDIR)/dictionary.o \
$(INIDIR)/iniparser.o

# commander stuff
COMMANDERDIR = deps/commander
COMMANDER_CFLAGS = -O2 -Wall -Wextra $(PLATFORM)
COMMANDER_OBJS = $(COMMANDERDIR)/commander.o

# Distribution tarball
TARNAME = $(PACKAGE)
DISTDIR = $(TARNAME)-$(VERSION)
Expand Down Expand Up @@ -136,9 +136,9 @@ purge: uninstall
# Purging configuration files...
$(MUTE)rm -f $(MANDIR)/$(MANFILE)

$(EXE): $(OBJECTS) $(INI_OBJS)
$(EXE): $(OBJECTS) $(INI_OBJS) $(COMMANDER_OBJS)
# Linking...
$(MUTE)$(CXX) $(OBJECTS) $(INI_OBJS) -o bin/$(EXE) $(LIBSDIR) $(LDFLAGS)
$(MUTE)$(CXX) $(OBJECTS) $(INI_OBJS) $(COMMANDER_OBJS) -o bin/$(EXE) $(LIBSDIR) $(LDFLAGS)

src/%.o: src/%.cpp
# Compiling $<...
Expand All @@ -164,7 +164,7 @@ run: all

clean:
# Cleaning files...
$(MUTE)rm $(VTAG) -f $(OBJECTS) $(INI_OBJS)
$(MUTE)rm $(VTAG) -f $(OBJECTS) $(INI_OBJS) $(COMMANDER_OBJS)
$(MUTE)rm $(VTAG) -f bin/$(EXE)

doc:
Expand All @@ -180,10 +180,17 @@ docclean:
# iniparser stuff

$(INIDIR)/dictionary.o: $(INIDIR)/dictionary.c
# Compiling $@...
# Compiling $<...
$(MUTE)$(CC) $(INI_CFLAGS) $< -c -o $@

$(INIDIR)/iniparser.o: $(INIDIR)/iniparser.c
# Compiling $@...
# Compiling $<...
$(MUTE)$(CC) $(INI_CFLAGS) $< -c -o $@

# commander stuf

$(COMMANDERDIR)/commander.o: $(COMMANDERDIR)/commander.c
# Compiling $<...
$(MUTE)$(CC) $(COMMANDER_CFLAGS) $< -c -o $@


124 changes: 76 additions & 48 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,50 @@
# yetris README
# yetris

Customizable Tetris(tm) on the console.
Customizable Tetris(tm) with textual interface.

![screenshot](http://yetris.alexdantas.net/images/1gameplay.png)
![screenshot](http://yetris.alexdantas.net/images/classic-tetris.png)

## Introduction

yetris is a customizable Tetris(tm) clone for the console.
It aims to follow modern implementations with lots of features
and please both casual players and Tetris(tm) enthusiasts.
yetris is a customizable Tetris(tm) clone for the terminal.
It has some features found on modern adaptations and aims
to please both casual players and Tetris(tm) enthusiasts.

It has full textual interface, with colors and many features:
It has full textual interface, check out these features:

* Customizable by commandline arguments and config file.
* High score.
* Up to 6 next pieces.
* Hold, Combo and back-to-back sequences.
* Scoring system compliant to the (conjectured)
*Tetris(tm) Guideline*.
* _Colors_ and animated interface;
* _Customizable gameplay_, with several game mode
possibilities: ghost piece, hold piece, slide left/right,
_invisible_ and custom initial level and noise (like
the old B-mode).
* _Customizable interface_: up to 7 next pieces, toggle
game borders, center screen, modify game _random algorithm_...
* You can change settings on _in-game menus_ and options;
* _Game profiles_: settings are automatically saved and
restored at startup. _Multple profiles_ supported.
* _Game statistics_: cleared lines, individual and total pieces...

yetris is developed on C and ncurses, running on (most) Linux
terminals.
It currently lacks some expected features but is on active
development.
yetris was originally developed in C, now reprogrammed in C++
with ncurses. It runs on pretty much every terminal around here,
but it's limited to POSIX systems.

Also, the source code is clean and commented, allowing much better
understanding and easing feature-implementation.
## Screenshots

![main-menu](http://yetris.alexdantas.net/images/main-menu-without-borders.png)

![profile-menu](http://yetris.alexdantas.net/images/profile-menu.png)

![single-player-menu](http://yetris.alexdantas.net/images/single-player-menu.png)

![options-menu](http://yetris.alexdantas.net/images/options-menu.png)

![b-mode](http://yetris.alexdantas.net/images/b-mode.png)

![help](http://yetris.alexdantas.net/images/help.png)

![pause-menu](http://yetris.alexdantas.net/images/pause-menu.png)

![game-statistics](http://yetris.alexdantas.net/images/statistics.png)

## Controls

Expand All @@ -40,26 +59,26 @@ understanding and easing feature-implementation.
| q | Quits the game at any time |
| r | Restart game |
| h | Show help window |
| F2 | Switch statistics |
| F3 | Show high scores |
| F5 | Refresh game based on config file |

To see more info, run `yetris --help` and `yetris --usage`.

## Installation
## Usage

Briefly, the following shell commands should configure,
build and install this package on the default directories:
build and install this package:

$ make
$ [sudo] make install
$ man yetris

By default yetris is installed at `/usr/games`, with the
settings and scores at `~/.local/share/yetris`. To
see how to change those, go to the file `INSTALL.md`.

If you want to test the game before installing, do:

$ make run

To see how things end up being installed on your system,
see file `INSTALL.md`.
The `Makefile` has lots of toggles and switches, check out
it's first lines.

## Dependencies

Expand All @@ -74,27 +93,23 @@ An example on apt-based systems:

$ apt-get install ncurses-dev

## Main Directory Structure

| File | What it is |
| -------- | ---------------------------------------------------------------- |
| README | General game information |
| INSTALL | Installation instructions |
| COPYING | Copyright and warranty info |
| Doxyfile | Doxygen file for generating the source documentation |
| Makefile | Instructions to the `make` program (build and install the game) |
| TODO | Work that needs to be done or ideas for future versions |
| BUGS | Known and solved bugs on the game |
| bin/ | Location of the executable generated after compilation |
| doc/ | The documentation files (explaining the source code) and manpage |
| obj/ | Location of resulting object files after compilation |
| src/ | All of the source code files |
| doc/index.html | Complete source code documentation |
| doc/yetris.6.gz | The manpage |

## Hacking

I'll add more info about development here soon, so stay tuned.
There's another `README.md` on the `src/` directory.
In there I try to explain the source and how could you play
with it.

If you want to contribute,
[there's a lot we could do together](https://github.com/alexdantas/yetris/issues)!
Don't hesitate to contact me, any addition is welcome.

The `BUGS` and `TODO` files are nice points to check out
what we could do.

Also, if you're like me and *love* ncurses games, with textual
interface and stuff, the `src/Inteface/*` files could be of
great use. I tried to make them very flexible so you could
just insert them into a project without too much change.

## Contact

Expand Down Expand Up @@ -130,10 +145,23 @@ Huge thanks for all the people that contributed to the project
on the building process. Thanks to him *yetris can be installed
on BSD*!

Also, some miscellaneous credits:

* Yetris' logo uses the *Crawford2* _Figlet Font_.
* Thanks, *Nicolas Devillard*! Your
[_iniParser_](http://ndevilla.free.fr/iniparser/) helped me
a lot!
* I'm also using
[clibs/commander](https://github.com/clibs/commander),
simples CLI argument parser I've ever seen.
* _Emacs_, _Awesome_ and _Arch Linux_, the Ultimate Triforce.
* [The OneUps](https://theoneups.bandcamp.com/) kept me awake
on several nights. Their music is great, specially _Volume 2_!

## License

yetris - Customizable Tetris(tm) on the console.
Copyright (C) 2013 Alexandre Dantas (kure)
Copyright (C) 2013-2014 Alexandre Dantas (kure)

yetris is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
Expand Down
2 changes: 1 addition & 1 deletion TODO
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Things I must do later
======================
----------------------

* Save and restore game state
(binary file with info on all major game data structures)
Expand Down
Loading

0 comments on commit b61a7c3

Please sign in to comment.