1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Hey Guest, is it this your first time on the forums?

    Visit the Beginner's Box

    Introduce yourself, read some of the ins and outs of the community, access to useful links and information.

    Dismiss Notice

KAG Map Editor Developement

Discussion in 'Maps' started by Verrazano, Aug 10, 2012.

Thread Status:
Not open for further replies.
  1. Verrazano

    Verrazano Flat Chested Haggy Old Souless Witchy Witch Witch THD Team Global Moderator Forum Moderator Tester
    1. Practitioners of War Extreme Revolution - POWER

    Messages:
    477
    This thread is just to show off the ongoing development of the KAG Map editor I've been making for the past 4 days. I've gotten a lot of encouragement and help from many people, A few of them I would like to mention.
    Special Mentions:
    Rayne
    Contrary
    SirSalami
    Anyways the map editor was written in c++ using the standard library, sfml 1.6, and lodepng. My IDE of choice was Eclipse CDT. It's taken me an accumulative of about 30 some odd hours thus far (and it's not even finished yet!)
    Just for everyone to see how it's been going I've been constantly taking screen shots and time lapses of me working on it the long time lapses haven't been put together yet. But the major demo videos have been made for you too view.
    [​IMG]The first GUI with plenty of my custom debug consoles. [​IMG]The original name of the editor was "Mythstone" and the logo was dumb. [​IMG]A better GUI for a better KAG. [​IMG]The first blocks correctly rendered in the map editor. [​IMG]Oh look it's duel, from swordfight... in a map editor. [​IMG]The first implementation of the graphical editing, no saving. [​IMG]The first implementation of the palette system this one has blocks & some items.
    Being able to view maps was a good start it was a little buggy though. The editor was graphically editable but it didn't actually do anything.. this is the current version not everything is implemented, but it is a working version you can build and play maps.
    --
    THE LONG AWAITED KAG MAP EDITOR..
    IS HERE!

    First off thank you all for the support and such! This has been a great learning experience for me and a lot of work, effort and time. I'm glad I've finished it though and I have delivered what we've all wanted!
    Second it isn't finished yet so please report bugs and things you would like added or changed(this doesn't mean they will be changed or added necessarily, more of a suggestion) However fear not I spent many hours creating working on an launcher/updater that will display changelogs and splash screens whatever and all that fancy stuff as well as download the necessary resources. So before you download it I have a few instructions:

    1) Download Kag Map Editor.zip to the desired location and unzip it.
    a) download it where ever (this will download everything to that folder for the editor to run.
    b) put the contents of the kag map editor folder into the kag root folder including the KMEResources.
    Do this if you don't want the updater to spend time downloading resources that can be found in the kag folder.

    2) Run launcher.exe this may take a second or 2 display (it has to download updatesplash.txt in order to show you the news a cool pictures whatever)

    3) click forceupdate or start either one may take upwards of 30 seconds depending on your internet speed to download all the resources and binaries for the editor.

    4) when it finishes downloading it will start the editor click "edit map" the new map function hasn't been implemented yet.

    5) type the exact path of your map starting from the root directory of wherever the editor.exe is. e.g) "Base/Maps/duel.png"

    6) edit the hell out of your map

    7) save - or saveas that's kind of self explanatory!

    8) have fun!

    Here is the download link for the launcher: launcher

    In the case that you guys like my editor so much that you download it 3 trillion times and break my bandwidth limit on dropbox then you will all need to redownload a launcher that will be set to a static address opposed to dropbox.

    IF YOU HAVE A MONITOR THAT CAN'T SUPPORT 1024X768
    Open the file in the root directory called "settings.txt" put a "|" through "wsize(width[1024] height[768])" then make your own wsize with the proper width and height or a un comment one of the existing ones.
     
    Porti, TealFish, MadDog and 46 others like this.
  2. SirSammy

    SirSammy Shark Slayer

    Messages:
    202
    Get it done, Verra :thumbs_up:
    Also nice work :)
     
    Porti, LordUA and Beepo like this.
  3. Antman

    Antman Base Burner

    Messages:
    344
    The map editor in the game already is premium only.. So, is this being released to everyone or just premium? (Could get the KAG team to organise that)
    And have any 'officials' had a word on this? :)

    But yes, this does look great, keep it up and I'll be sure to use it :D
     
  4. Rayne

    Rayne ༼ つ ◕_◕ ༽つ Administrator Global Moderator Forum Moderator Tester

    Messages:
    1,916
    It is not premium only, the premium only editor is ingame only, there is nothing against the rules about making your own Map editor.

    And for the second question, I've actually been sneaking Geti screen shots and videos occasionally and he supports it 100%.

    Btw if you didn't know, SirSalami is one of those "officials", and he's mentioned in special thanks, lol.
     
    Porti, SkiPzZ_ and Antman like this.
  5. miniu

    miniu Haxor

    Messages:
    765
    I wanna this :p
     
  6. Brilly

    Brilly Haxor

    Messages:
    222
    Now all we need is a bot AI editor, and then we can finally play god.
     
    Porti, SkiPzZ_, Gofio and 4 others like this.
  7. Dropping in to watch this magnificent thread, and it's creator. :)

    Go Verra! Support all the way!
     
    Porti, Froghead48 and bluefire212 like this.
  8. Verrazano

    Verrazano Flat Chested Haggy Old Souless Witchy Witch Witch THD Team Global Moderator Forum Moderator Tester
    1. Practitioners of War Extreme Revolution - POWER

    Messages:
    477
    Today I fixed the issue with spikes and ladders always appearing as their back ground less counter parts. Here are some pictures showing off the fix.

    [​IMG]
    When a default map is put into the editor.

    [​IMG]
    My in editor build to show of the fix, it's kind of hard to see that they have a background. soo..

    [​IMG]
    Nice zoom in.

    [​IMG]
    In game, the wood doesn't show up in sword fight game mode for me so don't worry it's still there.
     
    Ghozt, Antman and FlamingDragon96 like this.
  9. FlamingDragon96

    FlamingDragon96 Shark Slayer

    Messages:
    407
    I really need to download this!
     
  10. Verrazano

    Verrazano Flat Chested Haggy Old Souless Witchy Witch Witch THD Team Global Moderator Forum Moderator Tester
    1. Practitioners of War Extreme Revolution - POWER

    Messages:
    477
    Erm I wont be releasing it for a while, sorry to say. I'm reworking the way I load all of the images in. I'm going to be using a text file with all the data so when kag updates, if there are any new blocks or a change of colors it will be easy. Also adding stuff at this point is impossible, because my code is to ridiculous.. My main file is 700 lines and cluttered to all hell.
     
    Ghozt and delankski like this.
  11. Asu

    Asu THD Team THD Team Forum Moderator

    Messages:
    1,580
    Good! But please add Text, lines, squares!
     
  12. The_Khan

    The_Khan Bison Rider

    Messages:
    757
    THIS IS FRIGGING AWESOME!!! This will make map making much much easier. Does it save the map as a .png or a .kag? I think you should be able to choose which one.
     
    Froghead48 likes this.
  13. Froghead48

    Froghead48 Haxor

    Messages:
    703
    Me Gusta.

    Im Going to check this out, as it looks really sexy :rollseyes:
     
  14. Verrazano

    Verrazano Flat Chested Haggy Old Souless Witchy Witch Witch THD Team Global Moderator Forum Moderator Tester
    1. Practitioners of War Extreme Revolution - POWER

    Messages:
    477
    I'm not sure what you mean by this?

    I chose to not work on the .kag format until kag updates some more because of the likely hood that it would change. The same problem goes for the .png format, but I'm working on a setup to fix all that as I mentioned above. The other problem is that only the developers know what the text part of the .kag is supposed to look like. Supposedly I've been told it's a .png with an extra layer of text thrown in or something. But I have no idea so it would take lots of time is what I'm trying to say.

    Oh, I get what you mean now, dude be more clear with what your typing it's hard to understand. And if I do add that I probably wont add it for a while, because it isn't very important to having a working map editor. I'm currently working on making it functional and easy to update since that will be a big problem for me during the school year.
     
    Ghozt likes this.
  15. Asu

    Asu THD Team THD Team Forum Moderator

    Messages:
    1,580
    Add possibility of create lines, text and squares like paint.
     
  16. Verrazano

    Verrazano Flat Chested Haggy Old Souless Witchy Witch Witch THD Team Global Moderator Forum Moderator Tester
    1. Practitioners of War Extreme Revolution - POWER

    Messages:
    477
    Time for the sometimes daily progress update. No pretty pictures today, instead a stupid joke: "YO DAWG I HEARD YOU LIKED SCRIPTING IN YOUR KAG, SO I PUT SCRIPTING IN YOUR EDITOR. SO YOU CAN SCRIPT WHILE YOU SCRIPT!"
    --
    So yea as I talked about above in a few replies I want to make this as easily update-able and flexible as possible so when I have school and other important things it wont take much to maintain the editor as kag updates come along. But if I put scripting into the editor that also means that you can add things from your mods and such into the editor so that it's even easier!

    The current name of the scripting language is called fittingly blockScript. What is it used for right now? Well it's used for making blockTypes so instead of hard coding each color value every single image like I was it's all now dependent on a text file called blocks.txt (file extension may change) I made this scripting language as flexible as possible in terms of what it can accept as valid. all you need to remember is {([])}.

    Classes are designated by curly brackets there is only one class right now it's called "block" meaning a type of block such as dirt, blueDoor, gold. Then there are functions which are designated by parenthesis. All current functions are for the class block. Finally argument values are in square brackets and they are preceded by the name of the argument(this is only used if a functions has multiple arguments, other wise the argument is nameless and inside the parenthesis).

    The scripting language is designed this way so that nothing out side of those brackets, braces, or parenthesis matters except the preceding name. So anything else is taken as comment essentially and thrown into the trash. the order of the arguments for functions does not matter, white spaces or random characters don't matter they can be every where. (I suggest you don't)

    All of what I'm saying is that I designed the scripting language so you can't screw it up easily. The only thing that would kill it would be putting a space in numerical argument.

    Time for some examples:
    This file though it looks like it should explode is read perfectly. Now here is an example of a file that I will actually be using:

    Here's a link to the current functions and classes in block script: https://forum.kag2d.com/threads/blockscript.7904/
    blockScript will be expanded in the future to make macros, buttons, menus, tools and such.
     
  17. Rayne

    Rayne ༼ つ ◕_◕ ༽つ Administrator Global Moderator Forum Moderator Tester

    Messages:
    1,916
    where more updates??!!!?!
     
  18. LucasTT

    LucasTT Haxor Tester

    Messages:
    455
    I love it!
    I really was thinking about make a KAG Map Editor one month ago,but I quit =/
    I wanna more screens and download it :P
     
  19. Freddex

    Freddex Haxor

    Messages:
    173
    Nice work so far, I remember the time when you taught me some C++, seems you made your way. That's a decent project, good work, Veranda man.
     
  20. Verrazano

    Verrazano Flat Chested Haggy Old Souless Witchy Witch Witch THD Team Global Moderator Forum Moderator Tester
    1. Practitioners of War Extreme Revolution - POWER

    Messages:
    477
    Haha thanks all. I've been slacking off slightly playing around with some new libraries specifically box2d and a lighting engine to boot. I can post some screen shots of that, but I haven't worked on the kag editor for the past week. I'm going to be finishing that up this coming week and weekend. On my To-Do list are update the editor to sfml2 (it was sfml 1.6) finish implementing the default tools fix bugs in odd sized blocks. finish implementing functions in blockScript. I will have my hands full, but I will make sure to post pictures for you guys.

    Anyways as consolation here is what I've been working on for the past few days:
    [​IMG][​IMG][​IMG][​IMG][​IMG]
     
Thread Status:
Not open for further replies.