Developers/ChangeLog

From FANG

(Redirected from ChangeLog)
Jump to: navigation, search

The version naming convention is to name the release by the date. For example, release 1.071231 was released on 2007 December 31.

March 9, 2008

GameLoop - updated restarting the game to start with the correct level.

OutlineTracker - enables a sprite to trace a shape.

CompositeSprite - MultiShapeSprite would have been better named CompositeSprite. MultiShapeSprite will eventually be phased out of the FANG Engine and replaced by CompositeSprite.

Client - this was changed to try to connect on port 80 first, then on the default port. This change was made to make sure connections can pass through firewalls. Game servers need to set up port forwarding on the web server to send information through. If a client is running a web server, the networking will not work. Send an email to bugs@fangengine.org if you experience this problem and need a fix.

July 17, 2007

ImageSprite - this class used ImageIcon and scaleImage, both of which are slow and the latter seems to have bugs in it. This class now uses ImageIO and BufferedImage, both of which are faster and work better.

MultiShapeSprite - two transforms were out of order. Since affine transforms are not commutative, this caused an error.

July 12, 2007

Client - an inadvertent change to the client in the last update disabled keyboard input. This has now been resolved.

June 28, 2007

GameConnection - in multiplayer games, it was kind of annoying when both players hit the start button at the same time because the first would start the game and the second would pause it. This could continue indefinitely. The GameConnections has been altered to disable pausing during the first second. Everyone can press the start button during the first second and the game will just start.

June 27, 2007

ImageSprite - when returning to a level in progress, the cache is emptied. This was not anticipated and caused a NullPointerException. Now, the cache is checked before it is used and the error has been eliminated.

June 25, 2007

Sound - panning is now supported. When you play a sound, you can set the sound to play on the left or right side or anywhere in between. In general, just pass in the x part of where a sound should play and it will balance appropriately left or right.

June 21, 2007

GameLoop, GameConnection - random numbers used to all be seeded by zero. Now they are seeded by the clock of the first player in a networked game

ImageSprite - setting the complex clipping shape created by transparent gifs caused some lag when drawing to the screen. Clipping is not really necessary when drawing a transparent gif anyhow. The ImageSprite was optimized by removing the complex clipping when it is unnecessary. Today's release contains some minor debugging and optimization of ImageSprite.

June 20, 2007

ImageSprite - a setImage method was added to enable changing the image that is displayed. Also, the shape of transparent gifs is now automatically detected and the actual shape of the image is used for intersecting with other sprites.

June 18, 2007

ProjectileTracker - added a constructor to take the doubles x and y. This is often more convenient than passing in a Point2D.Double.

June 16, 2007

GameLoop - setNextLevel for applets was causing the GameLevel.startLevel to be called twice. This has now been fixed.

ErrorConsole - this new class is a message system for displaying system errors. For each known error type, the message will contain a diagnosis, possible fixes, and the location of the error. The ErrorConsole does not add new functionality to the FANG Engine beyond improving the detail of the error messages. This class is currently under development and may be altered in future versions of the FANG Engine.

April 20, 2007

Sound - there was a concurrent modification error when using the LineListener to remove fully played sounds. In order to fix this problem, fully played sounds are now reclaimed every time a new sound plays.

SpriteFrame - a reference to the frame's location was returned. This error has been fixed by returning a new Point2D.Double instead of returning a reference to the frame's internal state.

November 30, 2006

AnimationCanvas - when adding a sprite to the canvas multiple times, it called update as many times as it was added. This had the effect of making trackers update at many times the speed they should. This has now be fixed. Thanks to Hobert for alerting me to this error.

November 29, 2006

ImageSprite - when given a bad image file, it threw an exception and did not allow the game to run. This has been changed to instead display an error image.

November 27, 2006

GameLevel - getResource did not function properly. This has now been fixed. Thanks to Julia for finding this bug. Also, the documentation for canvas, random, and gameLoop was improved by mentioning that they cannot be used before startLevel is called.

GameLoop - addLevel did not function properly when trying to access the number of players. This has now been fixed by altering the begin and advanceLevel methods. Also, the comments for addLevel and setNextLevel have been improved to document the different ways they are used. Thanks to Frederick and Nick for finding this bug.

ImageSprite - the error message when passing an invalid file name was improved by mentioning the invalid file by name.

November 8, 2006

GameLoop - startOver didn't reset the cursor to its default. This has now been fixed. The method restoreCursor has been added to GameLoop and AnimationCanvas. AnimationCanvas - the method restoreCursor has been added to restore the cursor to its default.

ImageSprite - the error message for using a non-existant image has been improved. A setImage method has been added. Also, you can now get the maximum animation index in animated gifs, determine if the image is animating via the isAnimating method. The setFill and setSeamlessFill had bugs in them that caused the size of the tiling to be slightly off. This has now been fixed.

StringSprite - the error message for using a non-existant font has been improved.

Sprite - methods have been added to set and get the rotation in degrees or revolutions. The methods for getting and setting the rotation in radians are unchanged.

TrackerAdapter - methods have been added to set and get the rotation in degrees or revolutions. The methods for getting and setting the rotation in radians are unchanged.

AlternateTracker - sometimes it is more difficult to think about how a sprite should change from one frame to another than it is to tell how the sprite should appear at a given time. In this way, the getRotationAddition, getScaleFactor and getTranslations are somewhat difficult to use. In some cases, it would be simpler if one could simply call setRotation, setScale and setLocation instead. The AlternateTracker has been written to make this possible. When using an AlternateTracker, the advanceTime method can call setRotation, setScale and setLocation and the code for the class takes care of converting these absolute positions, scales, and rotations into relative positions, scales, and rotations respectively. There are two examples in the TrackerTest example which now use the AlternateTracker class. The classes which extend AlternateTracker are SpinTimes, and ExpandTracker.

Sound - the error file played repeated when the sound file was invalid. It also did not stop when the game stopped as an applet. Now it only plays the error message once and all sounds stop when the game stops.

RectangleSprite, OvalSprite, PolygonSprite - these methods have been added to make some common shaped sprites.

October 26, 2006

GameLoop - startOver and setGameOver had a bug in it that kept gameIsOver from functioning properly. This has now been fixed. Thanks Robert & Julia for helping me identify this error.

September 5, 2006

Several classes had warnings in them for not declaing a serialVersionID. These classes do not need such versioning, so the SuppressWarnings("serial") was added in order to remove the warnings.

August 4, 2006

GameLevel - startOverLevel had a bug in it that has now been fixed. Thanks for alerting me Farfel.

July 29, 2006

Server - there was an exception thrown when connections to the port did not follow the ObjectInputStream and ObjectOutputStream protocol. This exception had the effect of bringing down the server. This has now been fixed. Thanks Aaron and Jared for pointing out this very important error.

July 27, 2006

Client - there was an exception thrown when the games were listed because the socket was closed without warning. A quit message has now been added to the Server class which allows for closing the socket gracefully.

Server - a quit message has been added which allows the socket connection to close gracefully.

ImageSprite - getImageIndex has been made public.

Sprite - adding or removing sprites in the Sprite paint or update methods causes a ConcurrentModificationError. This is now documented in the method comments.

July 26, 2006

AnimationCanvas - there was a bug that threw an exception when null was removed, contrary to the comment on removeSprite. This has now been fixed such that no exception is thrown.

Mouse - negative mouse positions were allowed when the mouse was above the applet window. The mouse positions have now been clipped to be non-negative. ==July 24, 2006 AnimationCanvas - there was a bug that threw an exception when non-existent Sprites were removed, contrary to the comment on removeSprite. This has now been fixed such that no exception is thrown.

GameWindow - updated the game name field so that is now a JComboBox which displays the list of currently underway sessions. Inactive sessions are now reliably removed. Everytime the drop down list is displayed the list is updated. Also added a capability to hash the compiled source code in determining which games can join other games. Only games with the exact same hashed compiled bytecode can join each other. Originally, games with the same class name could join each other. This caused problems because any game named Pong could join any other game named Pong even if they were completely different games. This getHash function is also called from the GameLoop.

July 17, 2006

AnimationCanvas - up to this time, the order of the sprites on the screen was not very flexible. The last added was on top, and also there was an addBottom method, but there was no easy way to insert sprites into the middle. The concept of layers has now been added. The sprites are now drawn in the order of increasing layer number, so the highest layer appears on top. The old way of the last added is on top still works the same way. In addition, you can now add or remove as many sprites as you want in a single method call because these now take a variable number of arguments. The layering of sprites is currently being tested.

July 14, 2006

MultiShapeSprite - there was a bug in getting the shape. It had two transforms out of order. This has now been fixed.

July 9, 2006

MultiShapeSprite - for quite some time students have wanted to make sprites where each of the shapes is a different color. This is now possible with the MultiShapeSprite. See the example MultiShapeTest. This class has not received adequate testing yet and may still have some bugs. If any are found, check this change log to see if the problem has been fixed. If not, email bugs@fangengine.org.

SpriteFrame - this new class allows Sprites to be grouped together and rotated, scaled, and translated. An example will be developed soon. This class has not received adequate testing yet and may still have some bugs. If any are found, check this change log to see if the problem has been fixed. If not, email bugs@fangengine.org.

July 5, 2006

GameLoop - there was an error which caused the number of players not to be set properly. This has now been fixed.

June 30, 2006

Client - there was some unneccessary waiting during the game startup. This has now been removed.

Keyboard - there was a bug which did not allow keyboard input after pausing the game. This has now been fixed.

June 29, 2006

ImageSprite - rotating and setting the shape had some bugs which are now fixed.

June 28, 2006

GameLoop - players were still able to click and use the keyboard when the game was paused. Input is now disabled once the game is paused and is re-enabled when the game resumes.

Game Over - setting to game over had some bugs in GameLevel and GameLoop. These are now fixed.

FrameAdvancer - the getAlarms method did not work. This has now been fixed.

AnimationCanvas - two convenience methods were added: getMaxX and getMaxY. When the canvas is square, these just return 1. When the canvas is rectangular, the shorter side goes from 0 to 1 and the longer side goes from 0 to greater than 1. Calling the getMaxX and getMaxY is a convenient way to see how the coordinate system is arranged for non-square canvases.

GameLevel - a setNextLevel method was added to the GameLevel and GameLoop class in order to make dynamically switching between levels easier. Now there are three ways to traverse the levels. In order of most to least easy to implement, the ways to go through the levels are:

  1. Add all the levels at the beginning and go through them in series. Use only the addLevel of GameLoop.
  2. At the end of each level, call the setNextLevel method in order to decide which level is next. Use only the setNextLevel method of GameLoop or GameLevel.
  3. Override the getNextLevel method of GameLoop. Don't use addLevel or setNextLevel.

You need to select one of the above three methods if you are going to add levels

June 26, 2006

Sound - midi files still had some trouble looping. This problem is now fixed. Also, sound did not stop properly when transitioning between levels. This too has been fixed.

GameLevel was missing the getID method, which has now been added.

June 24, 2006

GameLevel - a random generator was added to match the random in GameLoop.

GameWindow - a static variable called displayControlButtons was added which can be changed to false in order to remove the buttons from the bottom of the game.

StringSprite - custom fonts didn't work. This was an error due to changing around the package names. This has now been fixed. Note that the name of the font file must match the name of the font and have the extension ttf.

June 23, 2006

Level Advancing - there was a bug in advancing levels that caused them to repeatedly advance due to a boolean value that was not reset properly. This bug has now been fixed. Also, the caching of images for advancing levels also had a bug which is now fixed.

AnimationCanvas - a method was added to remove the cursor and also to set the cursor to a given image.

Sound - looping didn't actually work. This is now fixed.

StringSprite - when adding text to an empty StringSprite, it sometimes came out upside down. This is now fixed.

June 22, 2006

The scheduling of alarms did not work properly when calling the startOver method. This is now fixed. Thanks to Jared for pointing out this errror. Also, PathBlur was removed because it was no longer used in the game engine.

June 19, 2006

BlurSprite was removed from the gaming engine and a new method was added to the Sprite Class to replace it. The Sprite method

setBlurLength now tells how many shapes should be drawn in the direction of the previous shape in reducing intensity.

CompositeTracker could experience problems if Trackers were also used outside of the CompositeTracker. Changes in the AnimationCanvas eliminated these potential problems. In order to make the change, the CompositeTracker had to be made final.

More of the code has been commented.

June 17, 2006

There was an error in BlurSprite that is now fixed. BlurSprite still needs some improvement, but it is now functional.

June 13, 2006

There was a bug that caused a NullPointerException when restarting games without levels. This bug is now fixed.

Added a Reversible interface for Trackers. Reversible Trackers can advance the time backwards. This can be useful for tweaking collision detection.

Enabled Trackers to be added to multiple sprites.

Calling startOver had some bugs in it that are now fixed. It also restarts the time when the game restarts.

June 1, 2006

The Freely Available Networked Gaming Engine, FANG is a major update from the original tipgame engine. Unfortunately, the updates in this version are not compatible with prior tipgame versions.

Here are the improvements in this version:

  • Coordinate System
In the tipgame engine, screen coordinates were in pixels. This made resizing difficult because the coordinates always had to be scaled by the screen width and height. Now, the screen coordinates have been normalized to (0, 0) to (1, 1) for square screens. Essentially the x and y coordinates are the fraction to move right and down respectively. When the screen is not square, the shorter axis goes from 0 to 1 and the longer axis goes from 0 to N. For example, if you want a screen twice as wide as it is tall, the coordinates would go from (0, 0) to (2, 1).
  • Setting the size of the AnimationCanvas sets the aspect ratio and preferred size in pixels
  • The AnimationCanvas resizes automatically to fill the screen.
  • Player
The keyboard, mouse and messages used to be accessible directly through an array in the GameLoop. Now they are bundled together in a Player class which is accessible withing the GameLoop class via the getPlayer methods.
  • GameLevel
Making game levels in the tipgame engine used to be extraordinarily difficult. The introduction of the GameLevel class makes this much easier. The startGameLevel class is called when the level starts and the finishLevel or finishGame method can be called within the GameLevel to indicate the end of the level. At the end of the level, the sprites, sounds, and alarms are all cancelled. If any of these need to persist across multiple levels, the persist method of GameLevel can be called which will prevent the removal of said object at the end of the level. The class which extends GameLoop can add and control the progression of GameLevels. The Splash example demonstrates a simple example of games with levels.
  • Starting Over
Starting a game over was another difficult thing to do, but commonly desired. Now there is a method which can be called in GameLoop which causes the game to begin again. In networked games care should be taken to insure all games start over at the same time in order to insure consistency.
  • URL
The gaming engine used to use URL's for ImageSprite, Sound, and Help. Now you can simply pass in the filename relative to the location of the current class. Examples of this are given in many of the sample games.
  • Help
Help used to be required in making all games. This is no longer required. Instead a default help screen is given. To set the help screen just call the setHelp method.
  • Tracker
The two methods getRotationAdditon and getScalingFactor in the Tracker changed the Sprite relative to it's current state and the getLocation method was not relative to the Sprite's current state. This caused some problems in the tipgame engine. First, setting the location of a Sprite which had a Tracker attached had no effect. Secondly, it made composing Trackers no really possible because the getLocation methods would conflict. For this reason, the getLocation method was changed to getTranslation which now tells how far to move the sprite from it's current location. This has two effects. Changing the location of a sprite will have the intended effect whether a Tracker is attached or not since the Tracker only affects the change in location. Secondly, Trackers can now be composed since they will not conflict. A CompositeTracker has been made to which different Trackers can be added.

Known issues in this version

  • ImageSprite
Setting the fill is less clear with the changed coordinate systems. This part of the gaming engine may be changed in future versions. The positioning and sizing of the images when using a fill still need some work.
  • The new parts of the code still need commenting.

Special thanks to Robert Duvall (instructor of CPS4: Java for Video Games at Duke) for suggesting many of these improvements to the tipgame engine which made fang possible.





Views
Personal tools
Add to 
del.icio.usAdd to 
diggAdd to 
FacebookAdd to 
favoritesAdd to 
GoogleAdd to 
MySpaceAdd to 
PrintAdd to 
SlashdotAdd to 
StumbleUponAdd to 
Twitter

Games
Games