The Planet Jumper

Hello all,

We have a 5yo son at home and as most children at that age he is pretty curious about everything, and one topic we recurringly get into is how the universe is organized. He gets the idea of planets, but one thing that gets his attention is being upside down on the other side, as everybody is actually upside down, but not. Gravity and perspective.

So last week we got together a few times in design sessions to create a game exploring it, and this last weekend we coded it. The initial result ended up being quite fun:

I think we both agree that the most interesting part of the project was actually the design sessions, though.

This is the whiteboard of one of our sessions:

By the end of the weekend we had worm holes. Definitely not black holes, according to him, so no need to be afraid. :slight_smile:

I don’t know where we’ll take this next – if anywhere – but if you want to play with the concept as well I’ve published this as a snap:

$ snap install planet-jumper

I hope it works for you. :slight_smile:

Some due credits:

  • Character by Daniel Hapiel, Open Pixel Project.
  • Planet and moon by Dan Gerhards, Open Clip Art.
  • Milky Way by European Southern Observatory.
  • Game Engine by Godot Engine.
7 Likes

something, something OpenGL not making me play.

@attache Yeah, it needs OpenGL 3.3 or OpenGL ES 3.0. They just released a major version of the game engine days ago, so I suppose they were trying to put their foot into the future for the next couple of years.

Could that be an error, or is your graphics board indeed somewhat old? I wonder if we could try a software-based solution. Will research about it later. I’d like to try building a skeleton setup for games from that engine to be released as snaps.

Per https://twitter.com/_myitcv/status/960924977426989062 I’m getting an issue after an apparently successful install:

$ sudo snap install planet-jumper
2018-02-06T16:36:38Z INFO Waiting for restart…
planet-jumper 2018.02.05 from ‘niemeyer’ installed
$ planet-jumper
internal error, please report: running “planet-jumper” failed: cannot find installed snap “planet-jumper” at revision 1
$ snap changes
ID Status Spawn Ready Summary
2 Done 2018-02-06T16:34:13Z 2018-02-06T16:38:27Z Install “planet-jumper” snap
3 Done 2018-02-06T16:34:13Z 2018-02-06T16:34:14Z Initialise device

Thanks for reporting it. That’s indeed very curious. It looks like the content never got mounted, although the mount operation did not fail. A couple more command outputs so we can try to understand what’s going on there, if you don’t mind:

  1. $ snap version
  2. $ journalctl -u snapd
  3. $ journalctl -u snap-planet\x2djumper-1.mount

Although interestingly having just re-tried, it loaded! Output from the
various commands you requested (prior to the successful launch) below.

$ snap version
snap 2.30
snapd 2.30
series 16
ubuntu 17.10
kernel 4.13.0-32-generic

$ journalctl -u snapd
– Logs begin at Tue 2018-02-06 15:00:29 GMT, end at Tue 2018-02-06
17:45:01 GMT. –
Feb 06 15:00:32 myitcv-virtual-machine systemd[1]: Starting Snappy daemon…
Feb 06 15:00:33 myitcv-virtual-machine snapd[860]: AppArmor status:
apparmor is enabled and all features are available
Feb 06 15:00:33 myitcv-virtual-machine snapd[860]: 2018/02/06
15:00:33.012871 daemon.go:306: started snapd/2.29.4.2+17.10 (series 16;
classic) ubuntu/17.10 (amd64) linux/4.13.0-32-generic.
Feb 06 15:00:33 myitcv-virtual-machine systemd[1]: Started Snappy daemon.
Feb 06 15:00:33 myitcv-virtual-machine snapd[860]: 2018/02/06
15:00:33.092074 stateengine.go:98: state ensure error: Get
https://api.snapcraft.io/api/v1/snaps/sections: dial tcp: lookup
api.snapcraft.io on [::1]:53: read udp [::1]:60419->[::1]:53: read:
connection refused
Feb 06 16:34:12 myitcv-virtual-machine snapd[860]: 2018/02/06
16:34:12.648821 api.go:957: Installing snap “planet-jumper” revision unset
Feb 06 16:36:37 myitcv-virtual-machine snapd[860]: 2018/02/06
16:36:37.375979 snapmgr.go:415: No snaps to auto-refresh found
Feb 06 16:36:38 myitcv-virtual-machine snapd[860]: 2018/02/06
16:36:38.402851 backend.go:152: cannot create host snap-confine apparmor
configuration: cannot replace snap-confine apparmor profile: AppArmor
parser error for /etc/apparmor.d/snap.core.3887.usr.lib.snapd.snap-confine
in /etc/apparmor.d/snap.core.3887.usr.l
Feb 06 16:36:39 myitcv-virtual-machine systemd[1]: snapd.service: Service
hold-off time over, scheduling restart.
Feb 06 16:36:39 myitcv-virtual-machine systemd[1]: Stopped Snappy daemon.
Feb 06 16:36:39 myitcv-virtual-machine systemd[1]: Starting Snappy daemon…
Feb 06 16:36:39 myitcv-virtual-machine snapd[9369]: AppArmor status:
apparmor is enabled and all features are available
Feb 06 16:36:39 myitcv-virtual-machine snapd[9369]: AppArmor status:
apparmor is enabled and all features are available
Feb 06 16:36:39 myitcv-virtual-machine snapd[9369]: 2018/02/06
16:36:39.721441 daemon.go:306: started snapd/2.30 (series 16; classic)
ubuntu/17.10 (amd64) linux/4.13.0-32-generic.
Feb 06 16:36:39 myitcv-virtual-machine systemd[1]: Started Snappy daemon.

$ journalctl -u snap-planet\x2djumper-1.mount
– Logs begin at Tue 2018-02-06 15:00:29 GMT, end at Tue 2018-02-06
17:45:01 GMT. –
– No entries –

Ah, glad it’s working now!

I suspect that what might have happened is this: you were using an old release of snapd, and it got updated at the same time that the new snap got installed, once you used and started snapd itself.

This is the hint:

15:00:33.012871 daemon.go:306: started snapd/2.29.4.2+17.10 (series 16;
classic) ubuntu/17.10 (amd64) linux/4.13.0-32-generic.

and then:

16:36:39.721441 daemon.go:306: started snapd/2.30 (series 16; classic)
ubuntu/17.10 (amd64) linux/4.13.0-32-generic.

The old release of snapd seems to have failed to parse the AppArmor profile:

16:36:38.402851 backend.go:152: cannot create host snap-confine apparmor
configuration: cannot replace snap-confine apparmor profile: AppArmor
parser error for /etc/apparmor.d/snap.core.3887.usr.lib.snapd.snap-confine
in /etc/apparmor.d/snap.core.3887.usr.l

@zyga-snapd @mvo Interesting case here. Anything worth looking into in more detail?

The log there looks truncated but since this is 2.29 material perhaps the issue is in the #include vs include syntax that got broken in apparmor userspace tools.

We did a small improvement yesterday…

1 Like