About | Rules and Guide | Sign In/Create Account | Write a Post
Construction1990’s Internet Montage? No!
Please excuse the site weirdness. Mike is fixing and making things.
Ludum Dare 31 — Coming December 5th-8th 2014!

  • ??? Begins: in 7 days, 23 hours, 23 minutes, 38 seconds
  • October Ends: in 8 days, 23 hours, 35 minutes, 38 seconds
  • Ludum Dare 31 begins: in 44 days, 0 hours, 23 minutes, 38 seconds
  • (FYI: Clock might be off) | Ludum Dare 31: Real World Gatherings (Now Open!)

    [ October Challenge 2014 | Resources | Submit/Edit | View All ]

    How Run Away maps work?

    Posted by (twitter: @Dax0u)
    December 20th, 2011 8:37 am

    Hello everyone!


    A little post to explain how I create levels in Run Away.

    All the system is based on pixels.

    First I got my set, here is my Hell set.

    Then I create on my paint editor a new image where 1 pixel is one tile in the game (classic).

    To choose which tile to use, I work on the Red color, Grass will be 0, Water will be 100 …

    Then I add foes, bonus, checkpoints  and tuto points with Green color

    And to conclude, the Blue allows me to select a specific one. For exemple I can chose the foeI want to spawn.

    Here are my maps


    For the last one, that’s what we have in game:

    In the game, the loading is really static, I could have added information on the Alpha of the first pixel to store data on the level for exemple the set (if it’s forest or lava) and the id (to know the order).

    My local values for each colors.

    int GrassRed = 0;
    int WaterRed = 100;
    int PanelRed = 130;
    int EndRed = 150;
    int SpikeRed = 160;
    int BossWallRed = 170;
    int DefaultRed = 255;

    int SpawnGreen = 100;
    int CheckPointGreen = 200;
    int FoeGreen = 150;
    int BonusGreen = 160;
    int TextGreen = 170;
    int ShadowGreen = 180;

    int FishBlue = 100;
    int BirdBlue = 101;
    int SawBlue = 102;
    int HalfSawBlue = 103;
    int HalfSawLeftBlue = 104;
    int BirdNoCollideLeftBlue = 105;
    int BirdNoCollideRightBlue = 106;
    int SawNoCollideTopBlue = 107;
    int BossBlue = 120;
    int BossDamageBlue = 121;

    //int SpawnSideRightBlue = 255;
    int SpawnSideLeftBlue = 254;
    int SpikeRightBlue = 254;
    int SpikeBottomBlue = 253;
    int SpikeLeftBlue = 252;


    Thanks for reading, if you want some other little post on how my game works, please comment :)

    2 Responses to “How Run Away maps work?”

    1. Deza says:

      Why not store them in three dimensional vectors? Seems much easier.

    2. Dax says:

      I prefer to have a graphical vision of the map, especially when we don’t have much time and I don’t have an external tool to visualise it.
      Besides I can use my image map in XNA like a ressource in my content while text files are not managed.
      And if I want something smaller then my pictures, I need to have binary files that I can’t edit easily.

    Leave a Reply

    You must be logged in to post a comment.

    All posts, images, and comments are owned by their creators.

    [cache: storing page]