2002-11-15  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* world.cc (UnnameObject): Reset name attribute of object being
	unnamed.

	* items.cc (HillHollow): Fixed hills and hollows.

2002-11-07  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* configure.in: Change include path so make distcheck works again.

	* world.cc (get_accel): Use different friction models for high and
	low velocities.  

	* items.cc (Spade::activate): Drop if there is no item underneath.

2002-11-06  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* init.lua (fill_items): New function.

	* items.cc: Add Spade item.  Change Hill/Hollow implementation to
	handle "shovel" message.

2002-11-05  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* objects.cc (Bridge::change_state): Change model *before* setting
	the new state.

2002-11-04  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* items.cc: Finished magnets.

2002-11-02  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* enigma.cc (GameMenu::GameMenu): Change button texts.

	* display_impl.hh (AliasModel): New model.

	* enigma-lua.pkg, display.cc, display.hh (DefineAlias): New
	function; defines an alias for an existing model.

2002-11-01  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* player.hh (SetCurrentPlayer): New function.

	* items.cc (Init): Register YinYang item.

	* player.cc (SwapPlayers): New function.

	* objects.hh (Object::int_attrib): New overloaded version that
	checks for errors.

2002-10-31  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* world.cc (clear_world): Dispose all actors.

	* px/tools.hh (AutoSequence): New helper class.

	* px-lua.pkg: Declare Uint32, tolua leaks memory otherwise.

	* models-2d.lua (def_subimages): Fix memory leaks.

	* display.cc (update): Update shadow "cache".

	* actors.cc (Init): Register WhiteBall.

	* objects.hh (Actor::init): new method. Allocate sprite ID here.

	* object_mixins.hh (CLONEOBJ): call Object::init from clone().
	(SINGLETONOBJ): new macro.

	* objects.hh (Object::init): new method.

2002-10-30  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* actors.cc (Actor::Actor): Allocate sprite ID in constructor.
	(Actor::set_model): Do not call allocate a new sprite ID.

	* display_impl.hh (Sprite::visible): new attribute

	* actors.cc: Reorganized implementation of balls.  Added new actor
	`WhiteBall'.

2002-10-27  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* px/array2.hh (Array2::resize): Save new width and height.

	* px/video.cc (set_alpha): Activate RLE acceleration.

	* display.cc (Redraw): Always flush screen updates.
	(StatusBarImpl::tick): Redraw status bar every second when clock
	is active.
	(NewWorld): Ensure the current actor is centered when the level
	starts.

	* enigma.cc (game): Use video::BackBuffer instead of allocating a
	new surface.

	* display.cc, display.hh (DrawAll): new function.

	* display.hh (RedrawAll): draw to surface instead of
	screen, remove option for updating the screen.

	* video.cc, video.hh (GetBackBuffer): New function.

	* etc/mingw32-dist.sh: include gfx/enigma.pal in zipfile

	* lua.cc (Init): Do not create table "enigma" by hand; let tolua
	do this.  Otherwise tolua cannot define global variables in this table.

	* sound/Makefile.am (pkgdata_DATA): include boink.wav

	* gfx/Makefile.am (pkgdata_DATA): include enigma.pal

	* configure.in: Bump version number.

2002-10-23  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* init.lua (def_floor): Reduce friction for (almost) all floors.

	* models-2d.lua: Load different "st-glass" model when in 8bpp mode.

	* world.hh (world): Removed STONE_KILL enum.

	* objects.cc (PuzzleStone::maybe_move_cluster): Create a "bridge"
	when the puzzle stone is complete and only water/abyss is underneath.

	* world.cc (handle_stone_contact): Allow stones to destroy
	themselves in actor_hit() (Needed for puzzle stones).

2002-10-22  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* actors.cc (BlackBall): make ball a little smaller

	* options.hh, options.cc (UseAlpha): new option

	* enigma-lua.pkg (options): export options::UseAlpha to Lua.

	* options.cc (options): ShowFPS defaults to false

	* actors.cc (BlackBall::change_state): Play sound effect when
	jumping.

	* video.hh, video.cc, enigma-lua.pkg (GetColorDepth): New function.

	* video.cc (Video_SDL::init): Use 8 bits per pixel automatically
	if this is the native bit depth.

	* display_impl.hh (SurfaceAlloc): New surface allocator that works
	with 8bpp colorkeyed images.

	* display.cc: Rewrote large chunks to properly deal with 8bpp
	video modes.  

	Rewrote screen update implementation.  Should be a bit faster now.

	Messed up everything that has to do with shadows, both in 8bpp and
	16bppp.  Will fix it later.

	* models-2d.lua: Define more animations using subimages

2002-10-18  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* enigma.cc (Game::on_keydown): Toggle fps display with "f" when
	in wizard mode.

	* display.cc (Redraw): Display fps if options::ShowFPS is set.

	* options.cc, options.hh: new: options::ShowFPS.

2002-10-17  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* px/video.cc (Grab,Duplicate): Copy color palette when available.

	* enigma.hh,enigma.cc (FindDataFile): Added new variant of this function.

	* enigma.cc (usage,init): document and detect new option --8bpp.

	* options.cc,options.hh: new option BitsPerPixel.

2002-10-15  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* gui.cc (TextButton::draw): Do not create a surface containing
	the button's text every time the button is redrawn.   Draw
	directly into the GC.

	* px/font.hh, px/font.cc (Font::render) Draws int GC instead of Surface.

	* objects.hh: Use associative lists for object attributes instead
	of dictionaries.  The default Dict objects allocated roughly one
	kbyte per object.

	* objects.cc, laser.hh, laser.cc: Removed last cases of virtual
	inheritance.
	
	* items.cc (Seed): New class

	* objects.cc (WoodenStone_Growing): New class: growing wooden
	stone (graphics still missing).

	* objects.hh: Added TGridObject<> class that simplifies changing
	the model/the animation for derived classes.

	Simplified Floor, Item, Stone classes as a side effect.

2002-10-12  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* gui.hh: Added container widget, use it as base class for Menu.

	* video.cc (MouseCursor): Fix memory leak.

2002-10-07  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* enigma.cc: Moved documentation to doc/*.html.

2002-10-02  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* levels/level1d.lua: Change oxyd flavour.

	* levels/martin06.lua: Modify document text slightly.

	* levels/martin35.lua: Fix visual glitches.

	* objects.cc (ActorImpulseStone): Made stone work.

	* world.hh (ActorInfo): Added forceacc field.

	* world.cc (get_accel): Use force accumulator.

	* enigma.hh (GridPos::operator==): Fix typo; Triggers should work
	again.

	* objects.cc (PuzzleStone::maybe_move_cluster): PuzzleStones move
	again :-)

	* levels/welcome.lua: Removed force field.

	* px/geom.hh: Generic rectangle class, Rect as typedef, new
	type DRect for double-valued rectangles.

	* enigma.cc (MainMenu): Display version number in lower left
	corner.
	Added credits screen.

2002-09-25  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* display.cc (StatusBarImpl): Fixed a couple of minor bugs like
	the inventory not being displayed.

	* models-2d.lua (NewAnim): Removed debugging message.

2002-09-24  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* video.cc (FX_Push): Improved effect by decelerating the new
	screen.

	* ttf2bmf.cc: New option "-g".  
	Cleanup.

	* px/math.hh (Vector::normalize): New method.

	* enigma-lua.pkg: Added prototypes for DefineComposite,
	DefineAnim, AddFrame.

	* display.cc (StatusBarImpl): New class, replaces many of the
	local functions and variables that formerly displayed the status
	bar.
	
	Removed remaining Lua interface routines.

2002-09-23  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* enigma.cc (game): Show visual effect when switching to the level
	menu.

	* video.cc, video.hh (FX_Fly, FX_Push): New functions.
	(FX_Fade): Renamed from `Fade'.

	* display.cc: Limit number of effect sprites to 10.

	* enigma.cc (init): Load configuration file.
	(shutdown): Write configuration file.

	* options.cc (Load, Save): New functions.

2002-09-18  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* px/cache.hh (Cache::size): New method.

	* px/dict.hh (Dict::size): New method.

	* px/Makefile.am (EXTRA_DIST): Removed array2test.cc and
	dicttest.cc.

	* objects.cc: Fixed a few typos in CLONEOBJ() calls.

	Removed virtual inheritance from MovableStone class.

2002-09-16  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* lua.cc, lua.hh: Removed set_num, set_str and companions.  All
	this is now handled by tolua.
	
	* *.cc, *.hh: Countless small changes, mostly cosmetic.  

	Replaced many instances of virtual inheritance with normal
	inheritance--tolua chokes on the former.
	
	Replaced std::map with px::Dict.  This noticeably reduces compile
	times.

	Removed use of exceptions.  Funny observations: Executable shrinks
	to half its size, and error handling improves in some places
	(e.g., getting attribute values in items and stones).

	* configure.in: By default, compile with -fno-exceptions.
	
	* models-2d.lua, init.lua: Added ice_001 floor (SF).

	* px/dict.cc, px/dict.hh: Added STL-workalike hash tables. Not
	quite finished yet, but they do the job.

	* tools.cc, tools.hh: Removed classes `Scope' and `Itor'.
	
2002-09-05  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* world.cc (YieldStone, SetStone): Don't tell floors and items
	about new stones immediately.  Defer this until the end of the
	current tick.

	* objects.cc (maybe_move_cluster, find_cluster): Fixed calculation
	and movement of PuzzleStone clusters.

2002-09-04  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* editor.lua: New file.

2002-09-03  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* Makefile.am: Use TOLUA variable.

	* configure.in: Search for tolua, both in PATH and current
	directory.

	* enigma.6, enigma.cc: Document --window switch.

	* levels/martin36.lua, levels/natmaze1.lua, levels/test.lua: Use
	soft scrolling.
	
	* world.cc (advance_actor): Reduce MAXVEL to keep actors (as well
	as possible) inside the screen while softscrolling.

	* init.lua (create_world): Set FollowMode to FOLLOW_SCREEN by
	default.

	* enigma-lua.pkg: Added binding for display::SetFollowMode.

	* display.cc: Implemented soft scrolling.

2002-09-02  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* world.cc (WarpActor): New function.
	(YieldActor): New function, but does not work at the moment.  Do
	not use.

	* items.cc: Added implementations for Magnets and Wormholes.  They
	still need a little work though. 

	* laser.cc (MirrorStone::emit_light): Do not emit light in the
	same direction more than once.  This fixes a bug reported by Ingo
	van Lil.

	* video.cc (Video_SDL::init): Do not enter fullscreen mode unless
	options::FullScreen flag is set.

	* options.cc, options.hh: New files.

	* px/video.hh: Rewrote classes Surface and Screen.  Still not
	perfect, but a lot cleaner than the old design.

	* models-2d.lua (progress): Display logo and graphical progress
	indicator.
	
	* models-2d.lua: Use new functions in namespace "display".

	* init.lua: Use new functions in namespace "enigma"/"world".

	* video.cc (DisplayTextCentered): Removed.

	* display_impl.hh: New file: Contains the type declarations from
	the late display-2d.cc.

	* display.cc: Renamed from display-2d.cc.

	* enigma-lua.pkg, px-lua.pkg: New files: Interfaces exported to
	Lua.

	* world.cc (tick_actor): Use fixed rather than adaptive step
	size.  Since the velocity of all objects is bounded, this works
	just as well (it seems to, at least).

2002-08-21  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* world.cc (RemoveForceField): Added implementation for this
	function.

	* tools.cc (Timer::tick): Fixed bug that causes timers to be
	deactivated even though they should run forever.  Alarm::timeleft
	should *never* be negative at the end of tick() when repeatp is
	set.

2002-08-15  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* configure.in: Check for Mingw32.

	* Makefile.am (enigma_ico.o): Include program icon if compiling
	with Wingw32.

	* items.cc (Trigger): Applied a patch by Andrzej Szombierski that
	fixes the behaviour of triggers when activated by stones.

2002-08-14  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* levels/martin19.lua,levels/martin26.lua: Adapted to work with
	the modified doors.

	* world.cc (handle_stone_contact): Call Stone::actor_contact if
	necessary.

	* objects.hh (Stone::actor_contact): New method.  Called when an
	actor is inside a stone but not moving towards is (so it's not
	really a collision, for which actor_hit is called).  Used mainly
	to fix the behaviour of doors.

	* objects.cc (Door::actor_inside): New method. Kill actors that
	stand inside a closing door.

	* sound.cc (Init): Changed size of soundbuffer to 1024 byte.  This
	should fixed lagging sound on Win32 systems.

	* enigma.cc (Game): Added new state: PLAYERDEAD.
	(tick): Do not restart level immediately when the player's marble
	is dead; enter state PLAYERDEAD instead.

	* models-2d.lua: Added animation for active death's head.

	* objects.cc (TimerStone::alarm): Do not play sound when the
	timer emits a signal.

	* enigma.cc (Game::tick): Wait a little before changing to the
	next level.

	* actors.cc (Whiteball_small::change_state): Play shattering
	animation.

2002-08-13  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* gui.cc: Play sound when button is pressed.

	* sound/Makefile.am (pkgdata_DATA): Added missing sound effects.

	* actors.cc (Actor::move): Removed debugging message.

	* Makefile.am (pkgdata_DATA): Include init.lua.

	* init.lua: Moved here from the levels directory.

	* enigma.cc (Game::run): Fadeout music before stopping it.

	* sound.cc (FadoutMusic): New function.
	(StopMusic): Forgot to reset current_music_name.

	* enigma.cc (DataPathList): New class for maintaining the list of
	data directories.
	(SetDataPath, GetDataPath): New public functions.

	* levels/index.lua: Added names for a few levels.

	* models-2d.lua: Use different models for sloped floors when in
	WizardMode.

2002-08-12  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* enigma.cc (LevelMenu::scroll_up,scroll_down): New functions. 
	(LevelMenu::manage): Fix mousewheel scrolling.

2002-08-11  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* enigma.cc (Game): Removed unused level_finished_p().

	* world.cc (handle_contacts): Fixed bug in collision detection.

	* items.cc (Hollow): Finish the level when all hollows contain a
	small white marble.

2002-08-10  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* px/font.cc (render): new method.

	* models-2d.lua: added progress indicator

	* lua.cc (display_text_centered): new function.

	* video.cc (DisplayTextCentered): new function.

	* px/array2.hh (Array2::resize): new method.
	(Array2::Array2): constructor can be called without arguments.

2002-07-09  Daniel Heck  <dheck@ix.urz.uni-heidelberg.de>

	* enigma.cc (game): Load level list only once at the beginning of
	the game.
	(LevelMenu::paint): Mark levels that have already been completed.

	* objects.cc (OneWayStone::actor_hit): Use contact_faces() instead
	of contact_face().  This fixes a bug where you could move through
	two adjacent oneway stones.

	* world.cc (contact_faces): New function.

