Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Developing a Robocode type game with .Net, for a School Assignment

I am currently in my final year at school, studying for a Higher National Diploma in Computer Studies, and basically in this final semester, we need to develop a Software Project, that basically incorporates a whole system.

Now, what I'm thinking of doing is something along the lines of Robocode, but instead of Java, I will be doing this with the .Net Framework.


What is Robocode ?

For those of you don't know what Robocode is, it's basically a sort of programming game in where people develop their own robots using methods from the class interfaces and downloadable classes that exist, and then they fight each other in an autonomous battle in an arena...like such:

alt text http://articles.techrepublic.com.com/i/tr/cms/contentPics/robocode.gif


So basically, as I said, I want to recreate this sort of scenario using the .Net Framework..and I am posting this question here on StackOverflow in hope that more experienced developers will be able to guide me in the right direction for this project.

What I have in mind up till now is basically to create:

  • An Offline application that will serve as the battle arena and the user-interface to create new battles with existing robots and such.
  • An Online interface that players will able to use to register new robots, view past tournament scores etc...
  • And obviously the Class Interfaces that players will need to use to create their robots.

Animation and Graphics (for the actual battles)

Now, of course there will be some sort of animation and movement when the battle occurs, and I haven't decided what yet to use as a medium for this.

The options I currently have in mind are:

  • Developing, as I said in the first above bullet points, an offline application that will serve as a battle grounds, and all animations will be done using mainly C# code
  • Or develop a Silverlight Application that will handle the animations (thus, changing the scenario from an offline applcation to now an online one
  • Or, maybe the least feasable of them, create the battle animations using JavaScript, with something like the Canvas

What do you think could be more suitable for this particular scenario ?


Developing Classes and Interfaces

For the players to develop the robots, I will provide certain Class Interfaces that they will be able to use like in Robocode.

Examples of such events and methods may include:

public void run () {}
public void onScannedRobot(ScannedRobotEvent e) {}

walk(/* ammount in pixels or w/e to walk to */);
turnRight(/* value in degrees for an angular turn */);
//etc...

Here is a snippet from code in Robocode (Java) :

public class MyFirstRobot extends Robot {
    public void run() {
        while (true) {
             ahead(100);
             turnGunRight(360);
             back(100);
             turnGunRight(360);
         }
    }
}

For then to actually make the battles happen, I am thinking of using Reflection to actually read what methods the user is actually making use of and implementing them to run and be invoked at particular moments of the battle and such.


Now, what I kindly and humbly ask of you experienced developers, is to guide me a bit through this project of mine and advise me on what needs to be done...for starters, is this project feasible at all ? And if it actually is, from where do I need to actually start with my project?


As regards technologies and software I intend to be using are :

  • .NET Framework 3.5, with C# 3.0
  • LINQ (Language Integrated Query)
  • SQL Server 2008
  • Microsoft Visual Studio 2008
  • jQuery Framework
  • Possibly Silverlight

I thank you all, even for managing to read up to this point in my question and I will need and appreciate greatly all the help I can get to finish this project.

Thank you for your time and effort.


Btw, up till now, apart from Robocode, I have found these games that are similar to what I am trying to create:

  • NRobot
  • Virii (thanks Marc)
like image 579
Andreas Grech Avatar asked Feb 02 '09 21:02

Andreas Grech


People also ask

What programming language is used for Robocode bot programming?

Beside being a programming game, Robocode is used for learning how to program primarily in the Java language, but other languages like Kotlin and Scala is possible as well.

Is Robocode or beginners?

world results in immediate benefits (they can build better robots and win) rather than some delayed gratification. Robocode is not just a beginner's tool, and since it's a game, students are motivated by wanting to participate in a game that is both simple and non-intimidating.

Does Robocode work on mac?

Installing Robocode from the command lineOn macOS, search for "Terminal" in Spotlight, and run it. On Linux, search "Terminal", "Konsole", or "xTerm" in your application launcher, and run it.


1 Answers

is this project feasible at all ?

It sounds big. I don't know how much time you have. Here's a rule of thumb:

  • When the drop-dead due-date happens, if 90% of the system delivering 90% of the functionality is 100% complete, then you might say that the project is at least 90% successful.

  • OTOH if 100% of the software delivering 100% of the functionality is only 90% finished (i.e., is not finished) then nothing is finished and the project is a failure.

A key to success, then, is "incremental development" and "continual delivery". Your project specification says:

We need to develop a Software Project, that basically incorporates a whole system.

To do this, I suggest:

  1. Create (i.e., design, develop, and test) a small whole system
  2. Repeat { backup or version control what you have; add a new, whole little bit to the system, and test it until it's satisfactory } until (you run out of time).
like image 155
ChrisW Avatar answered Oct 19 '22 12:10

ChrisW