summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--Makefile.am2
-rw-r--r--hslist.cpp2
2 files changed, 3 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am index c08852f..f0b1082 100644 --- a/Makefile.am +++ b/Makefile.am
@@ -2,7 +2,7 @@ AUTOMAKE_OPTIONS = subdir-objects
2ACLOCAL_AMFLAGS = ${ACLOCAL_FLAGS} 2ACLOCAL_AMFLAGS = ${ACLOCAL_FLAGS}
3 3
4bin_PROGRAMS = mazeoflife 4bin_PROGRAMS = mazeoflife
5mazeoflife_SOURCES = highscore.cpp hslist.cpp mazeoflife.cpp util.cpp titlestate.cpp gamestate.cpp 5mazeoflife_SOURCES = highscore.cpp highscore.h hslist.cpp hslist.h mazeoflife.cpp mazeoflife.h util.cpp util.h titlestate.cpp titlestate.h gamestate.cpp gamestate.h
6AM_CXXFLAGS = $(SDLTTF_CXXFLAGS) $(SDLNET_CXXFLAGS) 6AM_CXXFLAGS = $(SDLTTF_CXXFLAGS) $(SDLNET_CXXFLAGS)
7mazeoflife_LDADD = $(SDLTTF_LIBS) $(SDLNET_LIBS) 7mazeoflife_LDADD = $(SDLTTF_LIBS) $(SDLNET_LIBS)
8EXTRA_DIST = resources/chl.bmp resources/hlo_paartm.bmp resources/hlo_passartm.bmp resources/hlo_rtm.bmp resources/htp1.bmp resources/htp2.bmp resources/icon.bmp resources/mono.ttf resources/pointer.bmp resources/title.bmp 8EXTRA_DIST = resources/chl.bmp resources/hlo_paartm.bmp resources/hlo_passartm.bmp resources/hlo_rtm.bmp resources/htp1.bmp resources/htp2.bmp resources/icon.bmp resources/mono.ttf resources/pointer.bmp resources/title.bmp
diff --git a/hslist.cpp b/hslist.cpp index 9a12dac..ed7f3ca 100644 --- a/hslist.cpp +++ b/hslist.cpp
@@ -8,6 +8,7 @@
8#include "titlestate.h" 8#include "titlestate.h"
9#include "gamestate.h" 9#include "gamestate.h"
10 10
11// We want to be able to sort Highscore objects in descending score order
11struct hslist_comp { 12struct hslist_comp {
12 bool operator() (Highscore* lhs, Highscore* rhs) const 13 bool operator() (Highscore* lhs, Highscore* rhs) const
13 { 14 {
@@ -15,6 +16,7 @@ struct hslist_comp {
15 } 16 }
16} hslist_comp_i; 17} hslist_comp_i;
17 18
19// resetRanks : sets the rank of all Highscore objects in a hslist_t to their (one-based) index in the list
18void resetRanks(hslist_t in) 20void resetRanks(hslist_t in)
19{ 21{
20 int i=1; 22 int i=1;