Torque Script IDE plugin for the Eclipse Platform

  • Slides: 28
Download presentation
Torque Script IDE plug-in for the Eclipse Platform Team: Matt Cummings and Steven Defriese

Torque Script IDE plug-in for the Eclipse Platform Team: Matt Cummings and Steven Defriese Mentor: Dr. William Harrison

What is Torque Script? n n n The scripting language the controls the Torque

What is Torque Script? n n n The scripting language the controls the Torque Game Engine. The Torque Game Engine is a general purpose game engine developed by Garage Games. Cheap licensing fees, $100 for all the source code, non-commercial

Types of games that can be made… n n n First Person Shooters Racing

Types of games that can be made… n n n First Person Shooters Racing Simulation RPG Action And others

Structure of Torque Script n n n A procedural, script language with C-like syntax.

Structure of Torque Script n n n A procedural, script language with C-like syntax. Emphasis on simplicity, aimed towards game engines. All the expensive graphics, audio, physics, etc. calculations are handled by the game engine (written in C++)

Some of the things Torque Script controls in the engine n n n scoring

Some of the things Torque Script controls in the engine n n n scoring managing players defining player and vehicle behavior controlling GUI interfaces control physics settings

In-Game Screenshot

In-Game Screenshot

In-Game Screenshot

In-Game Screenshot

In-Game Screenshot

In-Game Screenshot

An example of a player code block with physics settings n n n datablock

An example of a player code block with physics settings n n n datablock Player. Data(Human. Male. Avatar) { … class. Name = Avatar; shape. File = "~/player. dts"; camera. Max. Dist = 4; n n n mass = 100; drag = 0. 1; maxdrag = 0. 5; density = 10; max. Damage = 100; max. Energy = 100; n n n n run. Force = 4000; // 50 * 90; … n jump. Force = 1000; // 10 * 90; n n n }; …

More Code… n n n n function Parse. Args() //--------------------------------------// handle the command line

More Code… n n n n function Parse. Args() //--------------------------------------// handle the command line arguments // // This is called from common code. //--------------------------------------{ for($i = 1; $i < $Game: : argc ; $i++) { $currentarg = $Game: : argv[$i]; $next. Argument = $Game: : argv[$i+1]; $next. Arg. Exists = $Game: : argc-$i > 1; $log. Mode. Enabled = false; n switch$($currentarg) { case "-? ": $usage. Flag = true; $argument. Flag[$i] = true; n n n } } } case "-h": $usage. Flag = true; $argument. Flag[$i] = true;

Which platform to develop our Torque Script IDE on? n n n Developing an

Which platform to develop our Torque Script IDE on? n n n Developing an IDE from scratch takes alot of time just developing the UI components. Answer: develop an IDE on top of a robust platform to allow us to focus on the IDE layout and functionality. We chose the Eclipse platform

Information about the Eclipse Platform n n An open-source IDE with various development tools

Information about the Eclipse Platform n n An open-source IDE with various development tools integrated within Universal IDE Supports development of plug-ins Free!

Eclipse Platform

Eclipse Platform

Eclipse Interface

Eclipse Interface

Structure of Eclipse Interface

Structure of Eclipse Interface

Java Features in Eclipse n n n Syntax highlighting Code collapsing Code auto-completion Code

Java Features in Eclipse n n n Syntax highlighting Code collapsing Code auto-completion Code hints Code generating tools Debugging

Syntax highlighting • Keywords • Comments • Etc.

Syntax highlighting • Keywords • Comments • Etc.

Code collapsing main is collapsed Hover mouse over main

Code collapsing main is collapsed Hover mouse over main

Code Auto-Completion With system calls:

Code Auto-Completion With system calls:

Code Auto-Completion With user defined variables and methods:

Code Auto-Completion With user defined variables and methods:

Wizard to Generate Code Java class wizard:

Wizard to Generate Code Java class wizard:

The Generated Code stubs:

The Generated Code stubs:

Debugging

Debugging

Debugging cont.

Debugging cont.

Our objective n n Build a plug-in for the Eclipse platform that enables a

Our objective n n Build a plug-in for the Eclipse platform that enables a programmer to code, run, test, and debug their code. One complete package that is easy to install, given to us for free by being able to distribute a plug-in file as one binary file.

Important Features n n n n Syntax highlighting Code collapse Function lists Intelli. Sense-like

Important Features n n n n Syntax highlighting Code collapse Function lists Intelli. Sense-like code assistance Test runs Module testing Debugging

Questions? ?

Questions? ?