The Robot Competition - Programming game
What?
This is a project for GC’05.

This is a programming tournament, in which we will create robots that compete, individually and in groups, in various tournaments.
”GUN-TACTYX” is a CROBOTS-like game with QUAKE3-style graphics. The game is based on the Apocalypse 3D game engine – which helps visualize the fight.
Fighting is just one possible mode… How about playing soccer, hmmmm?
How?
We will be using this game as a framework in which our robots will compete. Robots are coded in the SMALL scripting language, which is a breeze to learn.

Hey you, don’t you aim that gun at my shiny metal ass!
Interested?
Think you can help? Feel free to join, pick up items from our TODO list!
You can email me at: shacharATaternity.com
More Info

For more info about the game, the SMALL scripting language visit http://gameprog.it/hosted/guntactyx/info.php
TODO
- Presentation of the game to fellow geeks
- Coding assitance for contestants
- Are you bringing a computer to GeekCon? Donate spare cycles to the RoboWars competition! We need to perform as many matches as possible, in a few hours, so every CPU is handy.
- Bring laptops, PCs - so you and other can debug their players!
Think you can help? Feel free to join, pick up items from our TODO list!
Here’s the code for Rookie… a teaser for y’all:
/* "rookie.sma" - simple control code for a team of warriors */
#include "core" // include core functions
#include "math" // include math functions
#include "bots" // include bot specific functions
main() { // the main entry point of the script
// defines a value to recognize enemy warriors
new const ENEMY_WARRIOR = ITEM_WARRIOR | ITEM_ENEMY;
// time limit to force a change in direction of the warrior
new const float:MAX_TIME = 10.0 // note the float r-value
new float:lastTime = getTime()
// loops forever (or better, until the bot dies)
while(true) {
new float:thisTime = getTime()
if(thisTime-lastTime > MAX_TIME) {
// changes direction at random every MAX_TIME seconds
lastTime = thisTime
new float:randAngle = float(random(21)-10)*1.5708
rotate(getDirection()+randAngle)
} else if(sight() < 5.0) {
// if the warrior is within 5 meters from a wall,
// change slightly its direction
rotate(getDirection()+0.31415);
} else {
// give a look for the nearest enemy
new item = ENEMY_WARRIOR;
new float:dist = 0.0
new float:yaw
watch(item,dist,yaw)
if(item ENEMY_WARRIOR) {
// Found one enemy!
// Do you walk? Stop!
if(isWalking()) stand();
// Do you run? Walk!
else if(isRunning()) walk();
// Rotate towards enemy direction adding
// the current direction (absolute) to the
// enemy direction (relative to the head)
rotate(getDirection()+yaw);
// aim and see what is in front of the gun.
new item
aim(item)
// It's an enemy, shoot!
if(item & ENEMY_WARRIOR ENEMY_WARRIOR)
shootBullet()
} else {
// Can’t find any enemy!
// Do you walk? Run!
if(isWalking())
run();
// Are you standing?
else if(isStanding()) {
// Maybe you collided into someone…
if(getTouched() & ITEM_WARRIOR != 0)
// if that is true, make a quarter turn…
rotate(getDirection()+1.5708);
else
// ... otherwise walk.
walk();
}
}
}
}
}
[Nitzan] Shachar, how cool is that. This'll be my main participation, hope to see a crowd.
Gidon: How about the kenesset? what better place to bring true feelingz to the surface and wage good unfair and filthy war? lets let politics take some action and kick ass. its also a good war zone - with all the corriodors and stairs
we already know who the teams and leaders are and who is on whos side
maybe we can even make the robowarriors to fit the phisycal and mental profiles of the starz How about RoboSharon Vs RoBoBibbi in a DEATHMATCH scene?..... Or orange teams vs blue teams we can have a great group netwar !! think of the possibilities!! ;-)
Ilan: i'm interested in the content creation side. Takes BSP (quake levels) and MD3 (also quake models). We need editors/or access to the textures. The website for the 3D engine download says: "back on sept 25" . Can we use the sourceforge nightly builds ?
Shachar: I'd appreciate any work on the creative side of the project! I sure would love to see other, more beatiful, arenas. The ID software tools are free (as in beer) according to the site. AFAICT the nightly build files are just fine.