Platform-Level Editor(P-LED)

This forum is currently in read-only mode.
From the Asset Store
A pack of 76 platform designs for a platformer game with a mushroom/jungle theme
  • I am making a platform game level editor for..ahem..no reason and the basic stuff is pretty much done but still I have many problems. Here is the .cap

    Please refer to the in game help or the readme file before testing it.

    http://www.box.net/shared/rbtzq89jia

    (used construct v0.99.84)

    <img src="http://i841.photobucket.com/albums/zz339/abhilash2863/P-led.jpg">

    Now, about the problems :

    How to make the screen scrollable?, not like that it follows player but when he user is editing the level and he wants to scroll the layout using arrow keys but when he starts the level(to play) the level scrolls with the player, i know it's kind of confusing

    one way is to make a invisible sprite with 8 direction behaviour that can help in scrolling but when the level is stopped for editing then the timeScale is set 0 so the behaviour will not respond

    How to save the level?, I tried using the save/load function and saving the level and next time the player opens the editor it loads automatically from the saved file. But here the problem is when there is not saved file(i.e the user starts the editor for the first time) the editor works but when the user starts the editor for the second time(i.e there is a saved file from previous time) the temp.exe crashes.

    Hope you understand what I want to say.

    Right now everything is messed up because everything is controlled by shortcut keys and many times I am also confused while making a level(you don't know how much time I spent making that level in sreenshot)

    If you make something nice with the editor, feel free to post the screenshot(please!!)

  • I made a level editor once, for a game project that has been halted for a bit...

    The editor saves a 8 x 10 level made from a tile set.

    The interface is very crappy, there's no feedback

    It basically stores different types of rooms, so you design the room by clicking the tiles and dragging the level. Then, you type the number of the room you want to save and press "save"... You can repeat this to every other room. When you want to save your levels, you just have to press "Publish" - it will save a text file on the same folder of your .cap. To load the levels again, restart the level and press open. Then, type the numbers you want to load and press "load".

    Well, since this was a prototype, I wasn't trying to make it functional yet. But the whole saving/loading works very well!

    If you need any additional advice, keep on asking! I don't know how familiar you are with Construct, but these events should be hard to understand.

    EDIT**

    Oops I forgot about the scrolling thing.

    The System events have a "Scroll to X" and "Scroll to Y", and you have the ScrollX and ScrollY values too. So you can easily do a:

    * "X" key is down ---> System: Scroll to X - ScrollX + 10

    Voil�!

  • thanks for your help , like you said I couldn't understand a thing since I am a beginner and don't know much about stuff like array, ini files etc.

    I think I will have to remake the whole thing and use tiles instead of just duplicating a sprite and dragging it and should probably change the name to something else P-LED sounds ugly...

    And one more question - is there any way to load an external image as the sprite at RUNTIME?

  • And one more question - is there any way to load an external image as the sprite at RUNTIME?

    <img src="http://i39.tinypic.com/11uz574.png">

  • hehe nice way to reply... but i tried it and it didn't work, it may sound a little dumb but i did the following -

    save the external file which is of same size of the sprite and and saved it in .gif format(i suppose it is the only format which can have animation) and used the condition you circled in pic and the path as

    apppath & "pic.gif" but it didn't work

  • Construct doesn't use .gifs. You should use .png.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • save the external file which is of same size of the sprite and and saved it in .gif format(i suppose it is the only format which can have animation) and used the condition you circled in pic and the path as

    apppath & "pic.gif" but it didn't work

    It didn't work because this is not the way to import animations. Look closely at the action. It says: Load animation frame from file. What you have to do is split your animation to as many images as needed and then load them one by one. Also, you are using the wrong image format. Supported format are listed here

    EDIT: Damn, too slow again

  • yay! it worked

  • hi

    Thank you for this exemple, it's interesting.

    I would like to create a level-map editor for the game I work on, so I will study your example, and the example of gammabeam for the save\load technics, even if I prefer to have map separated (not in a big file).

    Have you plain to add other things, like color change ?Can we change the RGB value of a sprite ? I have don't find that.

    Another thing : I would like to know what is the "string" saved when we save a map made with your editor ?

    Thank you

  • i'm sorry to tell but i stopped working on this experiment a while ago but i do have a another version in which is more simplified and usable and a save/load function can be implemented easily in it. But in this example save/load is almost impossible. Colour change can be done i think, there are events for that(maybe). You can even have sprites frames loaded at runtime giving the user ability to use his own sprites. My other example has this feature.

    I'll upload it later maybe after an hour or two...going for classes

  • here is the file

    http://dl.dropbox.com/u/5811650/PLed/PLed.rar

    the rar has 2 folders with one having exe and other having the cap , to use a custom sprite refer to the readme

  • Thank you very much .

    I will study your file.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)