# Air Combat - a classic shooter

**URL:** https://forum.makecode.com/t/air-combat-a-classic-shooter/1985
**Category:** Show & Tell
**Tags:** game, featured-game
**Created:** [May 6, 2020, 10:32pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985 "2020-05-06T22:32:00Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![ractive](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/ractive/32/928_2.png) [@ractive](https://forum.makecode.com/u/ractive)
#### Post date: [May 6, 2020, 10:32pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/1 "2020-05-06T22:32:01Z")

</div>

Air Combat: [https://ractive.github.io/air-combat/](https://ractive.github.io/air-combat/)  
Collect powerups, bombs and hearts to make it through the final battle against enemies in the air, on ground and on the sea.

 ![air-combat](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/1X/7942ac7f19f7b7b215c4c4a9eea6963af7a54a3d.png)

It’s also available on [itch.io](http://itch.io): [https://ractive.itch.io/air-combat](https://ractive.itch.io/air-combat)

**How to play:**  
Press and hold button B to shoot and drop bombs with A (if you collected any).  
Collect the green powerups to upgrade your weapon and to get points.  
The hearts will give you more lifes (max. 5). If you got shot or collide with an enemy, first the weapon upgrades are destroyed before you loose a life.

**Code**  
The code can be found on github: [https://github.com/ractive/air-combat](https://github.com/ractive/air-combat)  
Contributions are welcome. Some nicer artwork, some better tuned levels and more types of enemies would always be nice.

---

<div class="post-metadata">

### Author: ![peli](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/peli/32/12_2.png) [@peli](https://forum.makecode.com/u/peli)
#### Post date: [May 6, 2020, 11:18pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/2 "2020-05-06T23:18:49Z")

</div>

Very nice! I was a bit thrown out that A did not shoot. Would it make sense to swap A/B?

---

<div class="post-metadata">

### Author: ![peli](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/peli/32/12_2.png) [@peli](https://forum.makecode.com/u/peli)
#### Post date: [May 6, 2020, 11:21pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/3 "2020-05-06T23:21:58Z")

</div>

Looks like pi0 build is having issue. We’ll have to look into this.

---

<div class="post-metadata">

### Author: ![otorp2](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/otorp2/32/940_2.png) [@otorp2](https://forum.makecode.com/u/otorp2)
#### Post date: [May 7, 2020, 3:59am UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/4 "2020-05-07T03:59:23Z")

</div>

What is there not to love about this? Total Classic!

---

<div class="post-metadata">

### Author: ![ractive](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/ractive/32/928_2.png) [@ractive](https://forum.makecode.com/u/ractive)
#### Post date: [May 7, 2020, 7:29am UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/5 "2020-05-07T07:29:15Z")

</div>

> [@peli](#):
>
> Very nice! I was a bit thrown out that A did not shoot. Would it make sense to swap A/B?

I have choosen B to shoot because it’s much more convenient on the PyGamer.

---

<div class="post-metadata">

### Author: ![richard](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/richard/32/5417_2.png) [@richard](https://forum.makecode.com/u/richard)
#### Post date: [May 7, 2020, 4:48pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/6 "2020-05-07T16:48:30Z")

</div>

This is AMAZING! I love the sprites, the gameplay, the changing levels/enemies… great stuff! All of the environments and enemies look fantastic.

The shmup genre is very near and dear to my heart, so glad to see such a great example!

---

<div class="post-metadata">

### Author: ![richard](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/richard/32/5417_2.png) [@richard](https://forum.makecode.com/u/richard)
#### Post date: [May 7, 2020, 4:49pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/7 "2020-05-07T16:49:00Z")

</div>

The missiles completely destroyed me

---

<div class="post-metadata">

### Author: ![2ndClemens](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/2ndclemens/32/809_2.png) [@2ndClemens](https://forum.makecode.com/u/2ndClemens)
#### Post date: [May 7, 2020, 9:02pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/8 "2020-05-07T21:02:46Z")

</div>

Very cool Game!  
Unfortunately it doesn’t run on my Meowbit. ☹  
I noticed a lot of games posted here don’t run on Meowbit (it seems to be weaker than other boards) so maybe it would be smart to have tags for verified / tested hardware.

---

<div class="post-metadata">

### Author: ![ractive](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/ractive/32/928_2.png) [@ractive](https://forum.makecode.com/u/ractive)
#### Post date: [May 10, 2020, 7:59pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/9 "2020-05-10T19:59:40Z")

</div>

If it was too easy for you, there’s now also a “hardcore” mode… 😨

---

<div class="post-metadata">

### Author: ![peli](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/peli/32/12_2.png) [@peli](https://forum.makecode.com/u/peli)
#### Post date: [May 10, 2020, 8:43pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/10 "2020-05-10T20:43:54Z")

</div>

2 player mode?

---

<div class="post-metadata">

### Author: ![ractive](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/ractive/32/928_2.png) [@ractive](https://forum.makecode.com/u/ractive)
#### Post date: [May 10, 2020, 9:58pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/11 "2020-05-10T21:58:23Z")

</div>

Hmmm. That would be great. Let me think about it. 🙂

---

<div class="post-metadata">

### Author: ![ractive](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/ractive/32/928_2.png) [@ractive](https://forum.makecode.com/u/ractive)
#### Post date: [May 11, 2020, 4:07pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/12 "2020-05-11T16:07:52Z")

</div>

I didn’t even realize that’s so easy to add more players.  
Check it out and tell me if the two player mode is usable.

BTW: Does anyone know if you can detect at runtime if the game runs on a platform that supports multiple players? Are there even platform besides the browser that support this?

---

<div class="post-metadata">

### Author: ![richard](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/richard/32/5417_2.png) [@richard](https://forum.makecode.com/u/richard)
#### Post date: [May 11, 2020, 4:11pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/13 "2020-05-11T16:11:02Z")

</div>

Right now it’s browser only. There is a way to check, but I don’t remember off the top of my head… @jwunderl?

---

<div class="post-metadata">

### Author: ![jwunderl](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/jwunderl/32/5308_2.png) [@jwunderl](https://forum.makecode.com/u/jwunderl)
#### Post date: [May 11, 2020, 4:46pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/14 "2020-05-11T16:46:12Z")

</div>

Raspberry Pi 0 does support multiplayer too, not just browser. If we’re just checking browser & pi vs other devices, easiest is just checking against ram - e.g. here is where we limit the number of particle effects:

> <https://github.com/microsoft/pxt-common-packages/blob/master/libs/game/particles.ts#L9>

so something like

```typescript
const MULTIPLAYER_ENABLED = control.ramSize() > 1024 * 400;

```

---

<div class="post-metadata">

### Author: ![peli](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/peli/32/12_2.png) [@peli](https://forum.makecode.com/u/peli)
#### Post date: [May 11, 2020, 4:53pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/15 "2020-05-11T16:53:37Z")

</div>

The pyGamer supports it if you connect two pyGamer together with the special USB cable Adafruit sells. 🙂

---

<div class="post-metadata">

### Author: ![richard](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/richard/32/5417_2.png) [@richard](https://forum.makecode.com/u/richard)
#### Post date: [May 11, 2020, 4:58pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/16 "2020-05-11T16:58:12Z")

</div>

@peli we’re talking about the non-jacdac multiplayer

---

<div class="post-metadata">

### Author: ![ractive](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/ractive/32/928_2.png) [@ractive](https://forum.makecode.com/u/ractive)
#### Post date: [May 11, 2020, 6:32pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/17 "2020-05-11T18:32:49Z")

</div>

> [@jwunderl](#):
>
> const MULTIPLAYER\_ENABLED = control.ramSize() \> 1024 \* 400;

I’ll give it at try! 👍

---

<div class="post-metadata">

### Author: ![ractive](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/ractive/32/928_2.png) [@ractive](https://forum.makecode.com/u/ractive)
#### Post date: [May 11, 2020, 7:56pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/18 "2020-05-11T19:56:36Z")

</div>

It works as expected, thanks. You aren’t asked on the pyGamer now if you want to have multiplayer mode! 👍

---

<div class="post-metadata">

### Author: ![peli](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/peli/32/12_2.png) [@peli](https://forum.makecode.com/u/peli)
#### Post date: [May 11, 2020, 9:58pm UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/19 "2020-05-11T21:58:10Z")

</div>

We need something better 🙂

---

<div class="post-metadata">

### Author: ![NxNMatrixGL](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/nxnmatrixgl/32/2553_2.png) [@NxNMatrixGL](https://forum.makecode.com/u/NxNMatrixGL)
#### Post date: [December 2, 2020, 6:28am UTC](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985/20 "2020-12-02T06:28:02Z")

</div>

Very nice! I am happy to see this game made on MakeCode. I was a huge fan of this genre in the arcade.

[Next page](https://forum.makecode.com/t/air-combat-a-classic-shooter/1985.md?page=2)
