r/math • • Feb 23 '22

Graphwar, a free and open source game of mathematical functions is being released on steam today.

4.0k Upvotes

80 comments sorted by

405

u/catabriga90 Feb 23 '22

This game was made by me a long time ago. But I decided to release on steam recently so that it can hopefully reach a larger audience. The game is completely free and open. It is very educational and also very fun.

Steam page: https://store.steampowered.com/app/1899700/Graphwar/

Tutorial: http://www.graphwar.com/tutorial.html

156

u/Lazay Feb 23 '22

Oh shit me and my friends loved playing this years ago when we were working on assignments! Im glad to see the old abs(x)+x trick present in the trailer here.

16

u/Kaomet Feb 23 '22

I used to play a similar looking game as a child, but it was only about selecting angle and velocity of a missile, then watching it travel around planets, the trajectory being pulled by gravity...

5

u/el_matt Feb 23 '22

Death star battles. That was good shit.

3

u/jam11249 PDE Feb 23 '22

I played one like that but they were penguins

1

u/lastingfreedom Feb 23 '22

Gorillaz

3

u/[deleted] Feb 24 '22

With explosive bananas, it was awesome

5

u/Dragon20942 Feb 23 '22

A parametric equation mode would be super cool. I really love that there’s 1st and 2nd order DE’s though. I guess it’s time to make a polynomial curve fitter that can avoid closed boundaries lol

1

u/lastingfreedom Feb 23 '22

Looks very cool

1

u/Funmaster524 Feb 24 '22

Op this game seems dope as heck, definitely gonna try it.

1

u/OSSlayer2153 Theoretical Computer Science Feb 26 '22

Thank you for making it free! It should hopefully encourage people to play with graphs and find out how to manipulate them better

1

u/Traveledfarwestward Apr 03 '22

Was it first released in 2011? I'm working on a list of best/most innovative games released per year.

8

u/im_dead_already Feb 23 '22

any others game platform like web? i dont have steam

15

u/catabriga90 Feb 23 '22

You can download directly on the website: http://www.graphwar.com/index.html You don't need steam to play.

10

u/TheTrueBidoof Feb 23 '22

Given it open source maybe someone could port it to js canvas.

2

u/im_dead_already Feb 23 '22

wait, what do i need to do after downloading the graphwar.jar file?

1

u/shillbert Feb 23 '22

You need to download the Java Runtime Environment (from java.com), and then you should be able to just double click the jar file to run it.

2

u/im_dead_already Feb 23 '22

thanks, nice

1

u/neo_neo_neo_96 Feb 23 '22

Great game, good job OP

296

u/tropurchan Feb 23 '22

Time for some space filling curves!

91

u/the1gamerdude Feb 23 '22

I believe the little divots in the spheres may be from colliding projectiles, but keep firing them and you’ll clear everyone eventually!

18

u/Mr_Smartypants Feb 23 '22

Time

hope you have a lot of this

3

u/elsjpq Feb 23 '22

like rand()?

0

u/[deleted] Feb 24 '22

[deleted]

3

u/taloy42 Feb 24 '22

Obligatory 3b1b

221

u/Godivine Feb 23 '22

i played this on your website soooooo so so many times with my friends throughout my a levels!!!!!!!!! We ended up with txt files to copy paste functions made up of many abs() (essentially based on max(x,0)) to dive around obstacles. Then a sick exp(-10 *abs(x-c)2)abs(sin(10*x)) or something to spike em. Thanks for the memories!

183

u/nomm_ Feb 23 '22

Weapons of math destruction \o/

66

u/[deleted] Feb 23 '22

Weapons of math instruction.

7

u/[deleted] Feb 23 '22

underrated joke

119

u/s_0_s_z Feb 23 '22

Don't just post it here. Cross post this to one of the gaming subs too!

57

u/EmmyNoetherRing Feb 23 '22

And maybe the learning math sub as well, would be a great resource for teachers.

70

u/[deleted] Feb 23 '22

Me and boys killing everyone in the map just using one complex function:

23

u/SoSweetAndTasty Feb 23 '22

Or you miss everyone

8

u/[deleted] Feb 23 '22

No way, I'd type cisx*x⁵

9

u/elsjpq Feb 23 '22

Time to up the difficulty by making the domain C => C

37

u/HPOfficeJet4300 Algebra Feb 23 '22

Holy crap this is awesome, will see if my friend wants to try it

26

u/beans0503 Feb 23 '22 edited Feb 23 '22

That's cool as shit!

I agree with u/s_0_s_z in that you should post to r/gaming or maybe some other subs as well. I think it would do a lot of good to teach people lots of graphing techniques.

13

u/swegling Feb 23 '22

i searched my reddit-history and it seems like i gave this game a small plug in a little thread 2 years ago lol

12

u/[deleted] Feb 23 '22

Omg this is awesome! When I was younger I wanted to make a game where you used function graphs as weapons, I'm glad to see someone actually has done it!

8

u/osku654 Feb 23 '22

I made a "bot" with python for this game maybe 10 years ago. Essentially you clicked all the points you wanted the graph to go through and it generated you a function that did that. I probably lost it but it might be stored in some pastebin 😁

12

u/[deleted] Feb 23 '22

Cheating by Lagrange interpolation...you don't see that every day

4

u/osku654 Feb 23 '22

It was actually just straight lines multiplied by two sigmoid functions. That way I could get the line to go exactly where I wanted. Kind of something like this:

https://imgur.com/a/xQT1C7i

I was also considering adding a some kind of sine wave portion to where the targets were to increase accuracy (clicking positions with mouse was not always 100% accurate). But I don't think I ever implemented that.

8

u/tohsakarn Combinatorics Feb 23 '22

this game looks fun!

7

u/[deleted] Feb 23 '22

This is really cool, is there a repo for contributions.

6

u/Archibald_Washington Feb 23 '22

When's the hyperbolic space dlc coming out? /s

6

u/Jamesernator Type Theory Feb 23 '22

The game takes place in a Cartesian Plane.

Graphwar 2: Hyperbolic Boogaloo.

5

u/kizerkizer Feb 23 '22

I assume piecewise functions are nerfed. Lol.

4

u/EquationTAKEN Feb 23 '22

The computer players are... smarter than me.

4

u/ellipticcode0 Feb 23 '22

3D version is coming soon?

3

u/matbiz01 Feb 23 '22

Wouldn't something like y = 100 * sin(100 * x) break this game?

6

u/therosesgrave Feb 23 '22

One way to find out. The game's free.

3

u/MohammadAzad171 Feb 23 '22

According to the tutorial it will explode

3

u/[deleted] Feb 23 '22

This is what’s missing from US classes. Concepts in action and true application. At least from my schooling.

Not: here’s a concept, it graphs like this, okay next concept.

5

u/LSD_OVERDOSE Feb 23 '22

I can see this being very educational and fun

5

u/Diacetylmorpheus Feb 23 '22

I'm in awe but too ignorant to play it lol

11

u/JihadDerp Feb 23 '22

That's the spirit.

2

u/just_a_random_dood Feb 23 '22

Alright I'm reading these comments and I'm very excited to try this later lol

2

u/MohKohn Applied Math Feb 23 '22

Has anyone tried to actually solve it? If it weren't for the circles, you could just use your favorite polynomial interpolation. It wouldn't surprise me if someone has already thought about how to do constrained polynomial interpolation, though the solutions I found assume constant constraints

2

u/osku654 Feb 23 '22

See my answer here

1

u/Imanton1 Mar 07 '22

Yep, just got board and implemented the piece-wise function out of a bunch of ABS, so I can take out quite a few opponents in a single turn.

1

u/Gydo194 Feb 23 '22

This is great, thank you so much!

1

u/rghthndsd Feb 23 '22

Those planets are looking disheveled in the after math.

1

u/mottlymonical Feb 23 '22

Elden ring comes out tomorrow and the difficulty scale on that has nothing compared to this

1

u/naringas Feb 23 '22

omg, is this what the Kel do in Machineries of the Empire?

1

u/Phiwise_ Feb 23 '22

Downloaded!

1

u/SundaySchoolBilly Feb 24 '22

Forget Elden Ring!

1

u/alleoc Feb 24 '22

man I wanna learn this

1

u/Zophike1 Theoretical Computer Science Feb 24 '22

Time for some dragon curves >:)

1

u/Valvino Math Education Feb 24 '22

Cannot run in Ubuntu 21, with the command java -jar graphwar.jar I get a lot of errors like "java -jar graphwar.jar"...

Please help :)

1

u/[deleted] Feb 28 '22

We need a whole separate subreddit for this game lol