Hacker News new | comments | show | ask | jobs | submit login
Show HN: Byte Arena – Code Your Fighter Bot (bytearena.com)
179 points by netgusto 11 months ago | hide | past | web | favorite | 40 comments

Back in the day I really enjoyed RoboWar on the macintosh: https://www.macintoshrepository.org/3842-robowar

I've seen other robot fighting games, but I always liked the low-level-programming aspect of Robowar. It used a stack-based machine language with IO via register accesses, and it had some instructions for complex functions like trigonometry, which still only took a single cycle, so it was easy to reason about performance. I guess what I liked about it was that you had to be clever, and it gave you the right tools to be clever.

Unfortunately, while RoboWar is a lot of fun, after many tournaments it is somewhat played out. Just about every paradigm and technique has been extensively tested, so it's hard to come up with a surprising or exciting new idea. A successor that stuck to the simple low level machine programming concept but introduced new concepts would help.

> A successor that stuck to the simple low level machine programming concept but introduced new concepts would help.

Byte Arena is structured in such a way that we can plug in entirely new Game Modes with gameplays (and vizualizations) radicaly different of deathmatch.

So I can totally see such a gamemode happen, not based on physical movements but for instance on resource management.

See also RoboCode: http://robowiki.net/wiki/Robocode/My_First_Robot

I like that ByteArena is language-independent. That's a pretty uncommon feature, in my limited understanding. Good luck, folks!

Robocode was my introduction to Java in highschool. I attribute a lot of what drove me to programming from trying to figure out how the wave surfers worked.

Yes, thanks!

I love projects like this, and I'm probably off to go code an agent after this comment.

I've also been thinking about building one of these based on killing the barrier of entry inherent in telling people "you can play, but you need to code a bot -- here's a tutorial". Perhaps it's just me itching for a fun little side project, but I've always wanted to code up a server and client as projects on github that could just be cloned, and use GitHub's API to e.g. automatically detect all repos forked from the client repo and run them in a persistent world -- and then also detect all servers forked from the server repo and run all clients across all worlds with some free hosting.

Obviously, there's a lot of security and stability concerns with hosting arbitrary code and effectively spinning up free instances for anyone who just clones a repo, but I think it'd be a super-simple entry for this kind of game that really benefits from having more players (especially when you bundle in some kind of skill-based matchmaking so newer players are often matched with players of their own skill and "move up" instead of just going against the top players all the time).

Is there any reason something like the above wouldn't work? I'm honestly surprised I haven't seen many "just clone this repo and it's automatically synced to your client hosted here" AI games.

Games like this one seems to be soo fun but when I'm back home after a whole day of coding I just can't find energy to write any more. I thought: why not create a game where you show examples of 'good' moves to your bot instead of coding them? So I've implemented my idea in https://top-tactic.com/en where you can teach bots to play soccer just by showing examples of good moves. Noone plays it, but it was fun to create :) and great way to gain some experience with neural networks.

OP here. The project is beta, we need feedback from the HN community to improve things and make it to public release!

The critical feature that turned me off theses games after crobots is the disconnect from real time.

There was some java version with distributed processing for battles so the results were the average over many battles on different machines. There was also the local graphical client which just ran on your own machine.

I coded up my own trig functions which were no more accurate than the arena could possibly use. Locally my bots consistently won, remotely they lost badly.

My machine was very very slow.

It boils down to interruptibility and actually counting time slices (accurately) if you do not get that right you reward the physical machines not the code.

Shouldn't this be in Show HN then?

It should, and now it is, thanks!

It's open-source here https://github.com/byteArena, if you guys want to look at the source code.

The two main repos are:

* [1] ba: The CLI

* [2] core: The lib containing the bulk of the implementation

To make Byte Arena, we made also made these projects:

* [3] Box2D for Go: Box2D 1:1 port to Go

* [4] ECS: An efficient and easy to use Entity Component System for Go

* [5] Schnapps: KVM tooling and API

[1]: https://github.com/ByteArena/ba

[2]: https://github.com/ByteArena/core

[3]: https://github.com/ByteArena/box2d

[4]: https://github.com/ByteArena/ecs

[5]: https://github.com/ByteArena/schnapps

I love the idea! Congratulations and good luck for the project.

It's cool that people are sharing other projects alike, there is some kind of curated list of this games/playgrounds?

Thanks, that's highly appreciated.

Currently we don't have enough material for such a list tho but we can create an awesome-bytearena list.

Reminds me of crobots (http://tpoindex.github.io/crobots/) a great little game I played many years ago. In it you program your robot in a C like language and watch them compete in a curses based command line arena.

Came to mention the same. However, Wikipedia[0] says crobots borrowed the concept from RobotWar[1] on the Apple ][, but "originally developed in the TUTOR programming language on the PLATO system in the 1970s". It's a whole genre... the young'uns just haven't seen it yet! Everything old is new again!

I'd like to see a twist where you could actually engineer your own weaponry using simplified physics, sort of like a cross between Kerbal Space Program and crobots, but with WebGL. I once coded a two player button bashing QBasic[2] snake version something like that, where you had competitive weaponry like flamethrowers and manually future-operable mine deployment. It was popular in our school for a few weeks.

[0] https://en.wikipedia.org/wiki/Crobots

[1] https://en.wikipedia.org/wiki/RobotWar

[2] https://en.wikipedia.org/wiki/QBasic

Wow did not know about this one. I'm continually amazed by how fruitful comments on HN can be. Thanks!!

Cool project. As noticed by somebody I think visualization side would need some polishing too. Maybe pair with Airmash[1] creator - merged together would be the killer app! ;)

[1] https://news.ycombinator.com/item?id=15892066

Hey thanks for the match making!

Major improvement is on the way as we've worked with game artists to make up colorful worlds and agents specificaly for Byte Arena.

It's gonna look like this: [1] (actual rendering of the visualization)

[1]: https://www.facebook.com/jerome.schneider.officiel/videos/19...

Thanks, our project is still very beta and the visualization need indeed some polishing.

Airmash is looking really cool, we'll definitely take a look at it.

I played it and it's awesome. Loads instantly, gameplay is a no-brainer, and action is fast :)

Why is the visualization of the battle so boring? Unless I'm missing something, it looks like the projectiles look the same as the agents.

Yes, design sucks a bit right now.

Major improvement is on the way as we've worked with game artists to make up colorful worlds and agents specificaly for Byte Arena.

It's gonna look like this: [1] (actual rendering of the visualization)

[1]: https://www.facebook.com/jerome.schneider.officiel/videos/19...

Like a 3D version of Core Wars


Have you heard of Screeps[1]? It's kind of similar in that you have to program your units to play the game. Can you tell us if it's comparable in any way?

[1] https://screeps.com (I'm not affiliated with it)

Yes we know Screeps, it's awesome :)

Byte Arena is similar in that you're expected to code agent behaviours to get it in the game.

What's different though:

* we support every programming language that has networking features

* in BA, you define behaviour for a single agent and not for a swarm

* we will support multiple game modes (deathmatch, CTF, speed racing) for agents that'll specialize in these game modes

* the perceptions in BA are very low level, and thus if your actions are within physical contraints, you may do things we have never imagined possible (it's sugarcoated by SDKs wrapping things for you if you don't want/care to make sense of the perceptions yourself)

> we support every programming language that has networking features

If that's the case it should be highlighted in the docs, a short guide would help as well I guess. Just by quickly looking at the docs I assumed it's javascript only.

Having example bots in other popular languages would be perfect. People could focus on what's important and don't worry about integration details.

Thanks for the suggestions!

> it should be highlighted in the docs, a short guide would help as well I guess

I had the feeling these points were adressed already in [1]; are you thinking about something more prominent in the documentation ?

> having example bots in other popular languages would be perfect

You're right; we're definitely going to focus on this

[1] https://doc.bytearena.com/#getting-started-guides-getting-st...

You are right, I missed that, sorry about that. After quickly skimming through the main page I went to getting started, skipped first paragraph where it's written AGAIN and red just this https://doc.bytearena.com/guides/getting-started/#prerequisi... :)

These things always remind me of brains and borgs for Bolo, and the AI competitions people would have between brains.

Wish I'd gotten in on that, but Bolo still exists, so I suppose I still can.

Seems like Robocode (http://robocode.sourceforge.net/) but is language independent.

Wasn't this kind of game in ICFPC[1]?

[1]: https://icfpcontest2017.github.io/

This kind of game is old. I remember I saw something very similar called "red code", about twenty years ago.

Yes, Corewar! A programming game going back to ancient times [1]. Corewar had as inspiration the apocryphal story of the Creeper and the Reaper. The Creeper was a real program that would copy itself to other computers. It was probably the first computer worm [2]. The Reaper was then created to also move across computers and delete the Creeper when it was found [3].

[1] https://en.wikipedia.org/wiki/Core_War

[2] https://en.wikipedia.org/wiki/Creeper_(program)

[3] http://corewar.co.uk/creeper.htm

Talking about [1] right (corewar) ?

I remember reading about it on HN a couple of monthes ago, and it was definitely an inspiration yes.

[1] http://vyznev.net/corewar/guide.html

Yes, it's that kind of game (competitive programming applied to gaming).

But although competition is definitely a part of Byte Arena (and will be in the future), it is also about having fun making stuff, and self improvement while doing so.

Robocode meets Halite? I love this!

However, more dramatic camera angles and close-ups of the action would be awesome!

Thanks, we'll add more drama to the game soon-ish :)

This brought back memories of Omega for the commodore Amiga I had way back in the day.

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact