Author Topic: [MAP] Recursion (WIP)  (Read 40427 times)

dragoonreas

  • Seedling
  • **
  • Thank You
  • -Given: 2
  • -Receive: 1
  • Posts: 37
  • Eufloria: Yes
[MAP] Recursion (WIP)
« on: August 04, 2010, 04:11:09 AM »
This is the level I've been making over the past couple of days.

It's still a work in progress at the moment, but the current features of note are:
- A tree fractal algorithm to move asteroids in recursive orbits.
- Utility and feature functions for more modular code (not very neat at the moment).
- A debug mode for troubleshooting. This allows for things like the values of variables to be written out to a text file so you can check that they hold the expected value when the level is running.

Plans for future updates:
- Remove the "write debug info to file" thing and implement some live debugging tools instead for creating custom patterns (i.e. colour coded lines showing which asteroids are within range of each other and indicators showing which asteroids are colliding or too close to each other).
- Consolidating all of the fractal methods and attributes into a class.
- Add ability to pick from multiple fractal patterns at the start of the level, including one that uses the system clock to control asteroid positions (and also tweaking the send distances, distance between asteroids, asteroid movement speed and size differences in the original pattern).
- Integrating annikk's Infected AI (v2!).

History:
2010/08/05:
  • BUGFIX: Stopped crash on startup when failing to create debugging file while not in debug mode.
2010/08/04:
  • Initial beta release.
« Last Edit: January 04, 2011, 05:37:30 PM by dragoonreas »

w4tc

  • Achiever
  • Shrub
  • ****
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 170
Re: [MAP] Recursion (WIP)
« Reply #1 on: August 05, 2010, 12:38:59 AM »
one thing to tell : :o OMG!!!!!!!!!!!!!!!!!

AWS

  • Achiever
  • Arboreal Being
  • ****
  • Thank You
  • -Given: 0
  • -Receive: 2
  • Posts: 275
Re: [MAP] Recursion (WIP)
« Reply #2 on: August 05, 2010, 02:10:03 AM »
at the risk of sounding stupid, i didnt understand a word of your post and what this file does exatly, but it sounds great!
 ::)

annikk.exe

  • Achiever
  • Ent
  • ****
  • Thank You
  • -Given: 0
  • -Receive: 4
  • Posts: 1,809
Re: [MAP] Recursion (WIP)
« Reply #3 on: August 05, 2010, 03:20:03 AM »
To make this work, I had to comment out this line at the start of the file:

Code: [Select]
io.output("Output/Recursion Level Output.txt")

After that it worked good.  :>  Impressive stuff dude...  Looking forward to hearing how you get on with this :>

dragoonreas

  • Seedling
  • **
  • Thank You
  • -Given: 2
  • -Receive: 1
  • Posts: 37
  • Eufloria: Yes
Re: [MAP] Recursion (WIP)
« Reply #4 on: August 05, 2010, 03:20:53 AM »
I probably should try and word it better... I wasn't sure how to describe it myself really.

At least Alex should understand the first part about the tree fractal algorithm as the trees in Eufloria look to be generated using a similar algorithm, especially the ones from earlier in the games development like these two below.






I've just done a quick fix incase anyone was getting a particular error that would stop them from being able to play the level.
I'm planning on implementing some proper error handling for this soon, so if you were getting this error with the first version of the level then you still won't be able to run the level in debug mode unless you change the file path for the debugging file. I'm hoping the next fix will also stop the bug that seems to stop info from being written out to the debugging file half the time.

EDIT: @annikk.exe I realised that may happen so in the current version I've put it in an if case so that it's only run in debug mode now, but it seems you found out about it just minutes before I was able to post the new version with the temporary fix for it.
BTW, at some point I'd like to integrate your Infected AI to see how well it handles this scenario of having 39 of the 40 asteroids in a level in constant motion. :)
« Last Edit: August 13, 2010, 12:00:46 PM by dragoonreas »

annikk.exe

  • Achiever
  • Ent
  • ****
  • Thank You
  • -Given: 0
  • -Receive: 4
  • Posts: 1,809
Re: [MAP] Recursion (WIP)
« Reply #5 on: August 05, 2010, 04:37:59 AM »
Good luck with that - in its current form the Infected AI is hopelessly difficult to integrate, and requires indepth conceptual knowledge about what is going on.  I'll be overhauling it soon, hopefully then it will be easier.. :>

Maarten

  • Seed
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 7
Re: [MAP] Recursion (WIP)
« Reply #6 on: August 05, 2010, 05:09:38 AM »
I just downloaded your 'fixed' version, but this one still has a spurious 'if' on line 26. Otherwise, good stuff!

dragoonreas

  • Seedling
  • **
  • Thank You
  • -Given: 2
  • -Receive: 1
  • Posts: 37
  • Eufloria: Yes
Re: [MAP] Recursion (WIP)
« Reply #7 on: August 05, 2010, 08:52:34 AM »
Oops, you're right. That's VB syntax, not Lua Script, and I was booted into my Mac partition at the time of making that change so I didn't test it after putting that if case in. I've updated it again and actually booted into Windows and made sure it's working this time.

naschi

  • Seed
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 5
Re: [MAP] Recursion (WIP)
« Reply #8 on: August 15, 2010, 09:59:56 AM »
crazy map. a bit too much movement... but playable

dragoonreas

  • Seedling
  • **
  • Thank You
  • -Given: 2
  • -Receive: 1
  • Posts: 37
  • Eufloria: Yes
Re: [MAP] Recursion (WIP)
« Reply #9 on: August 15, 2010, 03:22:44 PM »
Similar to a lot of fractals, the map's meant to look quite crazy and chaotic when you first see it, but after watching it for a while you should be able to work out how the asteroids move, where they'll go and which asteroids they'll pass along the way.
The idea for map is to use the way the asteroids move to your advantage, and plan which asteroids to colonise and attack accordingly.

There's meant to be lots of movement, but at the moment it's too fast.

I haven't done any work on this since the last update as I've been a bit distracted modding the gravity engine annikk.exe made (you can find my mod here if you want to take a look).
I'll try and get some more work done on this soon though, as although it's playable in its current state there's still lots of stuff I need to finish and fix.

Some of the things that need to be changed / fixed include:
  • Fix the asteroids send distances from ending up too big (not sure why this is happening ???).
  • Increasing the distance between the asteroids.
  • Slowing down the asteroid movement.
  • Increasing the size difference between the asteroids between each depth level in the fractal.
« Last Edit: December 23, 2010, 02:19:24 PM by dragoonreas »

Ytaker

  • Tester
  • Seedling
  • ****
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 33
Re: [MAP] Recursion (WIP)
« Reply #10 on: August 15, 2010, 10:11:16 PM »
Aw. I liked the super send distances. You could use those planets to defend the core, or get those last annoying asteroids that almost never went near one of your asteroids.

Jazz Ad

  • Sapling
  • **
  • Thank You
  • -Given: 1
  • -Receive: 2
  • Posts: 53
Re: [MAP] Recursion (WIP)
« Reply #11 on: August 31, 2010, 08:39:21 AM »
Fantastic.
I'm not sure I understood half of what was going on.
I couldn't even say if the map is easy, difficult or if I just got lucky but it was super fun to play.
Thanks.

AWS

  • Achiever
  • Arboreal Being
  • ****
  • Thank You
  • -Given: 0
  • -Receive: 2
  • Posts: 275
Re: [MAP] Recursion (WIP)
« Reply #12 on: January 02, 2011, 07:45:01 AM »
any updates for this???
ill be including it in the cleaner release of the Custom Level's thread so any updated info would be great.

aws

dragoonreas

  • Seedling
  • **
  • Thank You
  • -Given: 2
  • -Receive: 1
  • Posts: 37
  • Eufloria: Yes
Re: [MAP] Recursion (WIP)
« Reply #13 on: January 04, 2011, 05:03:22 PM »
Nothing that's in a working state right now unfortunately. I was a lot busier than I thought I was going to be last semester, and although I have done quite a bit of work on this since then it's mainly been to the quartz composition prototype I've been doing most of my designing and testing in than the level itself.

I think I found out what was happening to the send distances... some of the asteroids won't within range of other asteroids when the level was setup, so the game increased the size of the send distances of some of the asteroids to make sure they were all accessible. At the moment I'm making it so that the send distance of the orbited asteroids are just big enough to reach the asteroids orbiting around them.

Other things I've been doing include:
  • Making the fractal engine into a class, similar to what I did with annikk's gravity engine here.
  • Designing a few more asteroid patterns (one of which will use the system clock).
  • Trying to make a function to do a brute-force search for pattern variables where the asteroids don't get too close or collide. I've probably been spending too much time on this though, so I likely won't be working on this anymore.
  • Porting a function I'd made in my prototype that draws colour coded lines between asteroids within sending distance (really only debugging purposes).

I'll need to make the fractal engine a bit more versatile so that the asteroids that control the fractal pattern can be moved more freely (rather than just in a circle as they are now) to make the pattern that relies the time given by the system clock to work.
I'll also probably be removing the code that writes out to the debug file considering how many problems that was causing.

mikesurovik

  • Seed
  • *
  • Thank You
  • -Given: 0
  • -Receive: 3
  • Posts: 4
  • Eufloria: Yes
Re: [MAP] Recursion (WIP)
« Reply #14 on: January 21, 2013, 11:32:45 AM »
Ok I know this is an old thread, but I just played your level and I want to tell you how much I loved it. I just played most of the levels posted on this site in fact, and this one is the best. I'm not saying its perfect, only that its the best I've ever seen. It took me a few tries to grasp the orbital patterns, and to develop a workable strategy. It was challenging enough at the beginning, but not impossible. Some of the other hard levels were so crazy I just had to retry them until I developed a specific strategy and got lucky. This one was more of a puzzle than a perfect execution/luck challenge. I valued the long-range asteroids the highest, and the medium range ones with high attributes second. Nice work throwing in some tempting asteroids that rarely come in range of any others. Just like every level for this game, my main complaint is that there is pretty much an inflection point, once you get a good enough foothold as long as you don't screw it up you've got the game won. I suppose the solution for this would be to make the AI spawn faster and faster as they become outnumbered. I've written AI's before for simple games and found that if you can write them with perfect logic they're too hard (and fast) and humans loose 90% of the time. I wrote a battleship game once and thought I had considered everything, but it was too easy. When playing against humans its best to cheat. Not too much, not too little, just the right amount.

Well I really went off on a tangent there, the point is that your level is badass and I wanted to commend you on it