presented by lewis chen senior design cs491ab winter-spring 2009

15
Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Upload: ira-stevenson

Post on 19-Jan-2016

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Presented by Lewis ChenSenior Design

CS491ab Winter-Spring 2009

Page 2: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Concept

• LEGO-themed Real-Time Strategy Game– Command a fleet of ships and attack enemy fleets

in 3D.– Construct custom models for the game.

Page 3: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Background

• Inspired by Homeworld• Game plot developed years ago.• Models were already being built prior to

project.

Page 4: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Objective

• To create a plastic construction toy-themed 3D Real-Time Strategy Game based on the Homeworld series RTS game.– Implement an orbiting camera– User input to control player’s ships.– Convey an outer space environment for the player

to play in.– (Optionally) Implement special effects to make the

basic game enjoyable.

Page 5: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Demonstration

Page 6: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Implementation Issues

• Orbiting Camera– Difficult to write from scratch. Does not move

smoothly nor to correctly.– Solution: Utilized Dhpoware.com demo source

code

Page 7: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Implementation Issues (cont)

• Model conversion– Multiple ways of converting an ldr file to an fbx file.– Given: Ldraw models are converted to .3ds format via

LeoCAD and imported to Blender.• Exported directly to .fbx or .x.• All the meshes joined as one object, export to .3ds, imported

to Carrara, exported to .fbx• Export to .obj, converted by FBX converter to .fbx

– Solution: Use Ldraw importer plugin for Blender to import Ldraw models directly w/o conversion, export to .obj, converted by FBX converter to .fbx

Page 8: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Implementation Issues (cont)

• Selection Pick ray– How to project a ray from near plane to far plane

of a perspective camera view.– Solution found from tutorials and examples– Was not able to implement Selection box

Page 9: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Implementation Issues (cont)

• Floating Health bar– Health bar is to appear floating above a ships

relative to the camera’s perspective.– Had a completely implemented health bar that

would update when attacked and not attacked.• Code lost when doing system restore.

– Most of original implementation recovered, but does not update as originally desired.

Page 10: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Implementation Issues (cont)

• Particle Systems– Immediately decided to use off-the-shelf code.– Studied user manual to understand how to modify

particle system parameters.

Page 11: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Implementation Issues (cont)

• Matrix Decomposition– Extracting the position and rotation of a ship is

very important• Be able to compare positions of two units and their

orientation.

Page 12: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Implementation Issues (cont)• Ship class

– Creating a class containing ship parameters• Model• Allegiance (boolean)• Selected (boolean)• Modelworld (Matrix)• Maximum Health (float)• Current Health (float)• Shield (float)• Attack points(float)• Maximum Velocity (float)• Angular Velocity (float)• Alive (boolean)• Ship name (String)

– Ships added to the game via a Generic List.

Page 13: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Implementation Issues (cont)

• Collision Detection– Collision detection came from tutorials.– Creating event handlers for Collision detection was

difficult

Page 14: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

Future Plans

• Abandon XNA and explore other game engines, perhaps commercial level.– It is a huge disadvantage to work on a game project

alone.• May end up just creating an animation series with

the game plot.– I have created test animations

• Develop other game ideas and see where it goes.– I have gained experience from using XNA and many

lessons have been learned.

Page 15: Presented by Lewis Chen Senior Design CS491ab Winter-Spring 2009

THE END