Tag Archives: Magic Carpet 2

Hey, I'm Simon and I'm making a game!! :)
Support me: BUY & Demo on Steam


Forget history! The earth isn’t flat and neither it’s round! It is a repeating iteration of itself! … at least for todays topic: the repetitive worlds of Magic Carpet 2 and 1nsane.

(If you think this is blasphemy and wanna punish someone, please contact amassingham on reddit – he “discovered” the issue. I’m just the writer.)

In MC2 you fly on a magic carpet and shoot monsters. In 1nsane you do off-road races. The special detail: you’ll never reach a level border! You’re not slowed down. Not turned 180°. Not killed. The map just repeats and repeats and repeats…

The mini map of MC2. You can clearly see the repeating map:

Source: Magic Carpet 2 Youtube (Anthony Massingham)

The same issue can be seen in 1nsane (thx to bananaft for mentioning!) where you also have an endless repeating terrain (watch at the mini map!):

Source: 1nsane

Logically the terrain geometry has to be seamless at the border but besides of that it was (at least for me) really interesting to think about the programmers side of this whole thing a bit more. I’ll trust the comments of the reddit thread to “explain” it.

What do you see when you look across the border and what happens when you walk over it?temujin1234
re-coded something like this and “just” copied the terrain 8x around the map and re-positioned the player as soon as he “tried” to leave his map tile (see left image).This behavior can also be seen perfectly in 1nsane (white arrow in the image below).

Source: 1nsane

With NPCs it gets complicated. For the game logic, every object exists only 1x and only in the central map! If you look at an enemy within your map, all is fine. The enemy position for game logic and rendering is the same.But what’s when you look across the border? Then the position for the game logic and the actually rendered position is different.
Next point: If you only take the central map into account, an enemy
movement should look like this. Even if you don’t stare at the enemy.
But if you see this with a “multiple terrain” perspective look
across the border, it will look like the enemy runs away from you (to
attack you from behind).
When measuring the distance between enemy and player you have to take the
map borders into account! Then you’ll see, that’s shorter to just rotate
the enemy and walk across the border towards the player.

You want more? bananaft (he worked on games with this feature) mentioned much more technical difficulties:

  • “Physics and collision detection have to deal with fact, that object,
    that crossing the border can be in two (or even four) places
    simultaneously, and have to collide with other objects from other side.”
  • “Ai and pathfinding (Bots should see through the border).”
  • “Sounds should be properly positioned.”
  • “Effects and trails. Just imagine particle emitter crossing the
    border, and what you should do to make it properly visible from both
  • When there’s a background like in Insane 2, you shouldn’t use detail objects like trees because this would help the player to notice, that the background never gets nearer (watchable in this Youtube video)

Thx elecdog (he creates the game Arcane Worlds with endless terrain feature) for answering the following question:

  • The game logic only knows one instance of every object, but if you would increase the field of view or the view distance – could you actually
    see them several times?
    The answer: Yes. But since it makes no sense, it’s better to optimize it that way, that the FoV & view distance is limited.

Last thoughts

I’m sorry that it got a bit text- & tech-heavy. But i found the whole issue very interesting. Especially because my brain accepts the trick. It doesn’t say “That’s weird!” it just relaxes and is happy about this huge free world….even when i stumble about the same stuff again and again.
After some thinking it’s clear why the brain accepts this world-behavior: since our own world is round, the real world behaves exactly the same. The game world ist just a very small sphere. :)

I really like that you don’t have map boundaries. Imagine a Battlefield air to air dogfight without turning around all the time. In the case of Battlefield: if you leave the map…you die.

Last words

I hope you enjoyed this article and if you did, feel free to contact me via Mail, Twitter or Facebook. I would love to hear your opinions, topic-suggestions or just a “Hello!”.

Update 1
In the comments BmB mentioned that such repetitive worlds where planned for Battlefield 1942 “but they scrapped it because you were able to shoot yourself in the head with a sniper rifle.” – How cool and crazy at the same time is that? :D Thanks BmB!

I didn’t embed the video directly to avoid any tracking from Google and complications with the DSGVO.


Forget history! The earth isn’t flat and neither it’s round! It is a repeating iteration of itself! … at least for todays topic…