Log In  

Cart #55896 | 2018-08-30 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Menu: Z to start game.

Game: Z to create ant (costs 3 food), left-click to drop scent (guides ants), right-click to remove scent.

Extremely basic cat-herding strategy game - you have to keep your ants going towards the food (using scent, or waiting for them to find it for themselves). Once they spot food they will grab it and return it to the anthill.

This started after I wanted to make something that had entities just doing their own thing in the game world. I remembered a section of Will McGugan's Pygame book (https://www.apress.com/gp/book/9781590598726) where he builds a little ant/insect simulation using simple checks for behaviour. I decided to give that a try, without actually referencing his book to see how it worked! But I managed to get the ants moving easily enough, finding food and returning it to the hill, and eventually picking random goal points so that they were not jittering around when not 'on mission'.​ Then I wanted to add more stuff, at the same time being frustrated waiting for the ants to find food sometimes, so I put in a thing where the player could use the mouse to drop a scent trail and thereby guide the ants in the right direction. Finally I wanted a threat to the ants, and I figured a bird would be appropriate, but didn't want it to be too punishing. I settled on a bird that would only prowl the edges of the play field. The only loss condition is when you have no ants left, and not enough food to make another ant. But it's not really a game you're 'supposed' to lose at. It's just a fun thing to play around with. Amusingly, you can 'micro' or 'macro' the ants if you are used to that kind of play from actual RTS games - leave a scent trail sitting near some food and wait for the ants to find it, or click quickly near an ant, dropping one scent after another and slowly dragging it in the right direction.
I'm really happy with how neatly this came together! Hope you enjoy!
Lexaloffle BBS thread: here.

#1GAM August 2018

P#55897 2018-08-30 18:55 ( Edited 2018-09-03 20:16)

:: dw817

Wow, this is really neat ! Reminds me quite a bit of SIMANT but on an easier scale.

Found a video without an annoying announcer.

Thumbs up, nice job !

P#55901 2018-08-30 20:01 ( Edited 2018-09-01 01:13)

@dw817 Thanks so much! I had a lot of fun making it! Never heard of SIMANT, I'll check that out.

Edit: wow, SIMANT is...a hell of a thing.

P#55982 2018-08-31 19:29 ( Edited 2018-08-31 23:31)

Yeah simant is crazy, I love it.

Also, probably not intended behavior but the way scent makers work, i just ended up holding down the mouse button and dragging it the whole time to sort of corral the ants. I was able to get 10 on the screen at once that way.

P#55983 2018-08-31 20:24 ( Edited 2018-09-01 00:24)

@Cabledragon Yeah that's fine too! You still have to be careful how you use it, but it's not exactly a bug. I put in two frames between 'clicks', maybe I should have used more, but I also noticed that. Problem is I get distracted easily if I'm not clicking rapidly, so that was the easier way for me to play it.

P#56131 2018-09-03 16:16 ( Edited 2018-09-03 20:16)

[Please log in to post a comment]

Follow Lexaloffle:        
Generated 2020-08-11 09:58 | 0.026s | 2097k | Q:32