This site requires JavaScript, please enable it in your browser!
Greenfoot back

Comments for Insect War

Return to Insect War

A new version of this scenario was uploaded on Tue Mar 05 17:10:20 UTC 2013 Fixed a bug
Game/maniacGame/maniac

2013/6/4

I won!
Super_HippoSuper_Hippo

2013/6/4

Great :D
JetLennitJetLennit

2013/6/4

Ditto!
MaxAlbertMaxAlbert

2013/6/5

Great game! Just a couple more features and better graphics and it could be an app!
landrylandry

2013/6/5

i won hooray !!!
Super_HippoSuper_Hippo

2013/6/5

I am not able to improve the graphics. These are the normal Greenfoot images (except the ant on the button in the bottom left corner). I only changed the size and color of some of them. If there are rotated by 0, 90, 180 or 270 degrees, they look like they should, but otherwise you seem to see every single pixel. I don't know how to solve that. I just noticed i forgot to upload the version in which the blue bug is actually blue...
A new version of this scenario was uploaded on Wed Jun 05 13:19:00 UTC 2013 - changed the color of opponent's bug - more enemies - slower life regeneration - it is harder to win now, but still possible Good Luck!
GreenGooGreenGoo

2013/6/5

Is there any way to control the bugs?
Super_HippoSuper_Hippo

2013/6/5

No, you can only recruit them in your building.
RUMMAKERRUMMAKER

2014/1/13

pretty good, obstacles and objectives will make the game even better. and if u can place a way point or a rally point so ur bugs will know where to go it would be even more awesome
Super_HippoSuper_Hippo

2014/1/13

Maybe I will try to make a version where you can control them. Won't be easy through. By the way, I just found the four player version here. I don't know what was wrong with it, because I never published it. Maybe I will upload it later.
A new version of this scenario was uploaded on Fri Jan 17 18:09:01 UTC 2014 Added a menu. (Well, actually only a start button, but without it, it took much longer to load the actual game.) Added fog of war. In Greenfoot, this does not create any lag for me when starting with the menu world. I hope that it will also work on the website! Changed the position of the buttons because of the fog. Changed the buttons itself to reduce code. Extremely improved the ability to help friendly soldiers! I saw a bug once, but could not figure out what was wrong. Cleaned up code a lot!
A new version of this scenario was uploaded on Sun Jan 26 12:00:12 UTC 2014 Added new soldier, the special bug. Added possibility to turn on/off fog and this special bug. You can also choose between 2-6 players now. All vs. all. It seems to very easy with many players, but try yourself. Changed the AI a bit again.
A new version of this scenario was uploaded on Sun Jan 26 14:45:59 UTC 2014 Forgot to change costs of the special bug.
RUMMAKERRUMMAKER

2014/4/15

hey do you think i can look at the code for how you did the fog? The way im doing it drops the frames alot :|
Super_HippoSuper_Hippo

2014/4/16

Every "pixel" is an own actor, 10x10 in size. The creation of it takes a while, but if you start with another world and then change to it (like my menu), it does not take so much time. The frame rate... Well, you should try to have not much code in the fog class since there are many objects on the screen. For me, the fog is actually behind everything else in the paint order. The own team changes a boolean of the fog, if it is in a specific range. If this boolean is true, then the shadow is invisible. If not, it will get darker again after a while. Other team members get the same transparency as the fog on which they are. The reason because I have the fog behind the others is that I wanted to have the buildings visible if they were spotted once. I don't know if this is a nice way to do it, but at least it works. Hope it helps! If not, create a discussion thread and maybe I and/or someone else can help you there.
RUMMAKERRUMMAKER

2014/4/19

oh i get it ty.
A new version of this scenario was uploaded on Thu May 08 17:41:00 UTC 2014 Added a new insect, the butterfly. Support unit that increases the damage of nearby friendly units. Costs 100. Maybe I will try to make it try avoiding fights in a next update.
sengstsengst

2014/8/22

I think the butterfly and the special bug should try to avoid fights, as you said. That would be better.
Super_HippoSuper_Hippo

2014/8/22

I am not sure how I will do it. At least the butterfly doesn't see enough to avoid enemies. Of course I could just make the butterfly not stop if it is attacked, but that is not what I want. Maybe I need to tell the ants to escort them or so. Or do you have an idea how to improve it?
sengstsengst

2014/8/22

Well you could do the opposite of finding the fight... so if you say, for instance, if ( getObjectInRange() ) goToward( object ); you could have: if ( getObjectInRange() ) turn( 5 ); or something like that... telling the ants to escort them would certainly be interesting.
Super_HippoSuper_Hippo

2014/8/22

Yeah, it won't be that easy though :D
sengstsengst

2014/8/23

true. that's why your going to do it. :P
A new version of this scenario was uploaded on Mon Sep 08 13:02:15 UTC 2014 -Special bugs and Butterflies avoid fights now. (The game is much harder now! At least against one enemy it seems to be almost impossible. Maybe I need to make it a bit easier, but try it yourself and tell me what you think!) They will check the position of every enemy in a specific range (butterfly sees twice as far as the shadow is disappearing). The nearer the enemy is, the higher is the influence on the resulting rotation. If there is only one enemy in range, he will turn to the other side. And because this is too hard to explain with more than one enemy, here is a picture how it works for two - qualitative. http://oi58.tinypic.com/33w5rp3.jpg The problem about this is, that if there are enemies for example left and right, he won't escape up- or downwards. (Castles are handled as an enemy.) -Fixed bug which made it impossible to spawn units when the mouse wasn't on the screen Not so important, more like for testing purposes: ;) -Fixed bug with a cheat -Added a new cheat (Somehow my money was negative once and a special bug walked on the red/green border, couldn't reproduce it though.)
Super_HippoSuper_Hippo

2014/9/8

And like every time: If you find bugs (not the insect :D) or have suggestions, please let me know! :)
sengstsengst

2014/9/9

Nice job!
Super_HippoSuper_Hippo

2014/9/9

Thank you! :)
sengstsengst

2014/9/9

Your welcome! Whats the cheat? Haha
sengstsengst

2014/9/9

I had about 13 ants and 6 beatles attacking me and I ran out of money, so I died. And all the ants and beatles were all blue! I think the enemy can become to powerful!
Super_HippoSuper_Hippo

2014/9/9

One cheat is to remove the fog and the other one gives you 1000 credits. The bug in the first one was that it didn't make the enemies actually visible ^^ The special bugs and butterflies are moving at distance from your castle now, so he spawns even more enemies. Maybe it needs some luck to get some special bugs in range to kill them since they give a nice award when killed.
sengstsengst

2014/9/17

Cool! That's true. Ok, so now I know why I was crushed! I really like your game, by the way.
A new version of this scenario was uploaded on Mon Sep 22 13:20:13 UTC 2014 added some kind of marker, so you can check whether or not an insect is affected by a butterfly
Sn3aKyGuYSn3aKyGuY

2014/9/22

I had the negative money glitch happen to me just now. Not sure what triggered it. I think it was that I was holding down 2 and it generated the bug, but not sure why. Also, on 2 players, this game is impossible. On 4 players I at least stand a chance, but I still have not managed to win. The enemies spawn rate is to high in my opinion.
Super_HippoSuper_Hippo

2014/9/22

I am not sure how to balance it. Maybe I will add a maximum possible number of special bugs and butterflies for each player, because after a while, there are plenty of them and produce tons of insects. What do you think? I still can't reproduce the money glitch. It is possible to create more than one insect in one act cycle (mouse and keyboard), but before every creation, it checks if enough money is available. I just noticed that the Counter isn't updating its image if an insect was created, but that couldn't be the problem actually. (Only visible at very low speed.)
A new version of this scenario was uploaded on Mon Sep 22 17:52:58 UTC 2014 Just some small bug fixes, nothing special.
Sn3aKyGuYSn3aKyGuY

2014/9/22

This is just off the top of my head, but I'd think implementing a timer then setting each bug type to only spawn so many within so many seconds. To keep it interesting, I'd try to have that number increase with the total amount of time that has passed in the game or make it relative to the total number of bugs the player has spawned into the world. For example: Ant can only spawn 5 every 3 seconds. Lady Bug can only spawn 1 every 5 seconds. Special Bug can only spawn 1 every 60 seconds, but only after 20 Lady Bugs have spawned. Butterfly can only spawn 3 every 60 seconds, but only after 50 Ants have spawned. Then every 120 seconds (or whatever) increase how many can spawn within those time frames.
Super_HippoSuper_Hippo

2014/9/23

This is an interesting idea, thank you!
A new version of this scenario was uploaded on Wed Sep 24 13:47:26 UTC 2014 - added Sn3aKyGuY's suggestions I just won on the 2-player-map, so it is possible again :D I didn't implement that the number of enemies will increase after a certain time. I will do it when it will get too easy some day ^^ - increased the money which you get for a kill: butterfly: was 10, now 30 (I think I forgot to change it after copying from the ant :S) special bug: was 100, now 120 - I think I know what the negative money bug caused... Should be fixed now!
A new version of this scenario was uploaded on Wed Sep 24 13:56:32 UTC 2014 Fixed a bug which I created in the last update...
A new version of this scenario was uploaded on Sun Nov 02 08:52:38 UTC 2014 Bug: - costs reduced by 20%. (Price now 40) Special Bug: - costs reduced by 14%. (Price now 300) - life increased by 67% - speed decreased by 50% Butterfly: - costs reduced by 20%. (Price now 80) - life increased by 20%
A new version of this scenario was uploaded on 2015-07-15 17:53:14 UTC Found and fixed a bug with the cheat input.
hmphrydmphyhmphrydmphy

2016/8/9

Can i copy your codes on this game?
Super_HippoSuper_Hippo

2016/8/9

I don't like it being copied, but if you want to create a game like this and have problems with any part, feel free to ask.
A new version of this scenario was uploaded on 2017-12-19 21:30:05 UTC Update for HTML 5