DS FPS Maker

Discussion in 'NDS - Emulation and Homebrew' started by smealum, Aug 22, 2012.

Aug 22, 2012

DS FPS Maker by smealum at 4:17 PM (14,960 Views / 9 Likes) 155 Comments

    • Member

    smealum growing up sucks.

    Member Since:
    May 1, 2006
    Message Count:
    510
    Location:
    Paris
    Country:
    France
    FPS Maker

    I think this deserves its own thread, so here's a copy of what I posted over at neoflash. I do plan on updating this in the coming days/weeks if people are interested in using it to make games, so let me know what you think ! :)
    Download link : http://smealum.net/FPSM/FPSMAKER_260812.zip
    (and for those who want to try a game made with this, here's ACOTSYE)
    [IMG] [IMG] [IMG]


    FPS Maker is in essence a first person shooter-type game engine for the DS accompanied by an embedded level editor. The idea is to allow people to make their own games on the go.
    The current version is functional but not quite complete as a few features are missing from the editor itself (the material editor mostly) and a whole lot of the engine's features are only partly implemented. Nevertheless, I was able to use the editor this morning to in only a few hours create ACOTSYE.

    I'll add a more in-depth documentation later, i need to get some sleep right now. But for eager learners, I've included lalala.map which is the basically source file for ACOTSYE's world, so you can try and learn from that in the meantime ! :)
    Also, here's an overview of the tools at your disposal (more will appear depending on what you've selected) :
    [IMG]

    Download : http://smealum.net/FPSM/FPSMAKER_260812.zip
    Last edited by smealum, Feb 20, 2013
    .Chris, Veho, jonthedit and 6 others like this.


    • Newcomer

    098v New Member

    Member Since:
    May 13, 2012
    Message Count:
    54
    Country:
    Canada
    This looks really nice gonna try it out now!
    • Member

    ferofax End of the World

    Member Since:
    Jan 26, 2009
    Message Count:
    2,371
    Location:
    Philippines
    Country:
    Philippines
    I see where all that lighting thingamajiggy you got working on in DScraft paid off... ^_^

    Very interested on this, but just a quick Q: What's your endgame here? Are you maybe aiming for quick and frantic (and hopefully smooth) shooting ala Metroid Prime Hunters, or something slow and steady like Call of Duty DS? I wouldn't mind anywhere between, but hopefully it's not too jittery.


    ALSO: It just occurred to me, but do you intend on implementing melee? Because I can totally see a first-person dungeon romp in the works, and you have to admit, that kinda sounds awesome, doesn't it?
    • Member

    smealum growing up sucks.

    Member Since:
    May 1, 2006
    Message Count:
    510
    Location:
    Paris
    Country:
    France
    And for everyone interested in trying this, here's the first tutorial on how to use the editor !

    Day 1 :

    Today we're going to go over the basics of using FPS maker, and by the end you'll have made the first room for your game !
    It'll look something like this :
    [IMG]

    I - Installing

    Installation is very straightforward. Both editor.nds and baregame.nds only use libfat and not nitroFS, which means you can place editor.nds and baregame.nds anywhere you want, but you have to place the /fpsm/ folder at the root of your card.
    So installation happens in just one step : copying all your files to your cartridge and making sure fpsm is in the root directory. Ideally it should look something like this :
    [IMG]

    II - Editor basics

    Now that you've installed the editor and the game engine, go on and launch editor.nds. You should be greeted by this screen :
    [IMG]
    If your screen doesn't quite look like that (most likely case would be the button icons not showing up), then you probably did not install everything correctly. Check the location of your fpsm directory and try again !

    Now to go over the editor's controls :

    - the D-PAD is used to move the grid around
    - R and L are used to zoom in and out of the grid
    - ABXY are also used, but we'll see what for later on, don't touch them for now !

    So just go ahead, move the grid around and see how that works... done ? Good. There are two tool windows open (we'll see about the material window later on), so let's take a look at them.

    - the first one is the file toolbar; it's very classic and straightforward :
    [IMG]

    - the second one is more interesting, and you'll be using it a lot :
    [IMG]

    So now that we've identified the basics of the editor, we can finally start making stuff !

    III - Your first room

    Now, the "create room" tool should be selected by default, but just in case, I'll say it : select the "create room" tool. Now point your stylus at the grid and drag it around. A rectangle appears ! This is your first room. Don't make it too big or too small, we'll keep things simple for now. (tip : to make your rooms bigger, don't forget you can pan the grid and zoom in/out; and know that you can do it while creating your room too !)
    Your screen should now look something like this :
    [IMG]
    You'll probably notice some ugly colored squares appeared on your top screen (not necessarily, depending on where you placed your room). Now I can tell you : the top screen is used to visualize your map as you create and modify it. What you're seeing right now is only a temporary rendering of your room before its geometry is processed; it'll look better later on, trust me.
    I can now also tell you what the ABXY buttons are for : they're used to navigate about the map preview. Go ahead, try it. Just try not to go too far.

    Anyways, now that we have our first room, we can actually try the tools we have at our disposal.

    - first, we'll try the most straightforward, the "move room" tool. All you have to do to use it is select it, then click on a room and drag it to where you want it to be.
    - second, the "resize room" tool. This one is a little harder to use as you have to drag one of your room's corners for it to work.
    - finally, the select room tool, which allows you to select a room for editing.

    So do that, select your room so we can edit it ! Once selected, you should see something like this :
    [IMG]

    You'll notice two new windows just appeared. We'll only worry about one for now, the tile edit
    [IMG]

    Obviously, you shouldn't press the "delete room" button unless you want to, you know, delete your room. Let's take a look at the "select tiles" tools. Press the button and then select an area within your room. Once your done, you should have a new window :
    [IMG]

    Now you can use these tools to modify your room ! If you press the "up" button, you'll notice your tiles will go up. And if you press the "down" button, I'm sure you can guess what happens. So do that, select areas and press up/down as you see fit. I'll make stairs as an example :
    [IMG]

    As you can see, only the floor changed height, which is a problem because my stairs now head straight into the ceiling. That's why you can also edit ceiling values by pressing the "edit floor or ceiling" button. By switching to the ceiling, you can now up its height :
    [IMG]

    I'll also tell you what the "cube" button is right under the "down" button; it's actually a "make wall" button; it sets all selected tiles to walls. Walls can be recognized in the editor grid as red tiles. For example :
    [IMG]

    Now the thing is though, the preview still looks terrible and like nothing anyone would ever want to play. So let's make it nicer ! In order to do that, simply press the "process materials and lighting" button. Wait a second, and you should now see something like this :
    [IMG]

    The preview disappeared ! That's because we forgot to put lights into our room, so we'll just put one in quickly and be done. For this, we'll need the entity toolbar :
    [IMG]

    Now, just select the "create light" tool and click somewhere in your room. You'll notice a lightbulb appeared in the editor and the preview ! That's your lightsource. We'll learn how to edit it later on (a tip though : just select it with the "select entity" tool, things should be clear from there).

    [IMG]

    Now that we have a lightsource, let's press the "process materials and lighting" button again. This time it'll take a bit longer, but since the scene is simple it shouldn't be too long. Be aware though that the more complex your room and the more light sources you have, the longer processing will be. In extreme cases, it can take several minutes ! So don't panick, a long wait does not mean the editor has crashed.
    Once it's done, you should have something like this :
    [IMG]

    And tadaa ! Your first room. This is all for now. In the next lesson we'll learn how to apply materials, edit lightsources, add enemies and maybe even create doors between rooms !

    Appendix :
    Now that you've created your room, you might want to try it. Doing so is very simple; just make sure it's been processed (unprocessed rooms aren't save, be very careful about that !), then press the "save map" button, and your map will be written to lalala.map in your fpsm folder.
    Now, just close the editor, start baregame.nds and enjoy your newly created room. :)

    Not sure where this is going yet, but I have to admit I hadn't thought about a first person melee game, and it could be really fun. :)
    3 people like this.
    • Member

    DS1 伝説の雀士

    Member Since:
    Feb 18, 2009
    Message Count:
    1,231
    Location:
    Yes!
    Country:
    United States
    That's what Sword of Moonlight was supposed to be, though it was only released in Japan :(
    In any case, this is a really cool project.
    • Member

    jerbear64 SO ZETTA SLOW!

    Member Since:
    Dec 10, 2011
    Message Count:
    143
    Location:
    Reaper's Game
    Country:
    United States
    I'm gonna try this out later tonight.

    All Hail Smealum, the God of 3D Homebrew! :bow:
    Willelmao and ferofax like this.
    • Newcomer

    vivi New Member

    Member Since:
    Mar 15, 2009
    Message Count:
    23
    Country:
    Poland
    Maybe do a "Slender" game.
    1 people like this.
    • Member

    jerbear64 SO ZETTA SLOW!

    Member Since:
    Dec 10, 2011
    Message Count:
    143
    Location:
    Reaper's Game
    Country:
    United States
    What am I doing wrong?
    I created the room, added enemies and lighting, then saved.
    When I start BAREGAME.NDS or Acotsye, it will skip straight to the "It was a cup of tea, wasn't it Nick?" screen.
    This editor seems to have potential. Now if only I could use it correctly. :blink:

    EDIT: Turns out I didn't put enemies in that map. :dry: Now I create the level, and all that comes up is the crosshair and the head on the bottom of the screen. Top screen is black.
    I managed to get it to work. ONCE.
    It works with ACOTSYE's default map, so I'm doing something wrong. :unsure:
    • Newcomer

    TheDan2430 New Member

    Member Since:
    Dec 22, 2011
    Message Count:
    46
    Location:
    burbank usa
    Country:
    United States
    I get that same thing with screen that says "cup of tea nick". whats that mean ?
    • Member

    jerbear64 SO ZETTA SLOW!

    Member Since:
    Dec 10, 2011
    Message Count:
    143
    Location:
    Reaper's Game
    Country:
    United States
    That's the screen you get when you beat ACOTSYE.
    ACOTSYE stands for A Cup Of Tea: Super Yeti Edition. That's why it says "A cup of tea, wasn't it Nick?"
    • Member

    smealum growing up sucks.

    Member Since:
    May 1, 2006
    Message Count:
    510
    Location:
    Paris
    Country:
    France
    Very sorry about that, there were a few bugs left over from me trying to finish ACOTSYE in time for the competition. :(
    Here's an updated version : http://smealum.net/FPSM/FPSMAKER_260812.zip (only baregame.nds has been updated)
    You no longer need enemies on your map for it to work, and the spawn point has been reset to (0,0,0) (that's what the 0 is for on the editor grid). Hope that helps ! Sorry for the delay. :unsure:
    • Member

    jerbear64 SO ZETTA SLOW!

    Member Since:
    Dec 10, 2011
    Message Count:
    143
    Location:
    Reaper's Game
    Country:
    United States
    I'll try that out and see if it works.
    Right now, I do not have access to my DSi. I'll get it back Saturday. I'll test it out then.

    EDIT: I just realized all I have to do is get sick. My sister's sick, so I'm next. And being sick= I GET MY DS BECAUSE I FEEL SO MISERABLE. :ha:
    • Member

    Dann Woolf Deadpan Snarker

    Member Since:
    Oct 12, 2010
    Message Count:
    356
    Location:
    Deventer
    Country:
    Netherlands
    Holy shit.

    I'm definitely keeping an eye on this.

    EDIT: I assume this is just a proof of concept? There's going to be more weapons, items, enemies and graphics and whatnot, right?
    • Member

    jerbear64 SO ZETTA SLOW!

    Member Since:
    Dec 10, 2011
    Message Count:
    143
    Location:
    Reaper's Game
    Country:
    United States
    Downloading the update now. (I got my DS back early.)
    • Member

    Vampire Lied Resident sociopath

    Member Since:
    May 27, 2011
    Message Count:
    628
    Location:
    somewhere
    Country:
    United States
    This is pretty badass! Work the portal gun into it somehow and this tool will be an even bigger hit!
    I've always wanted to have a portable portal game. Maybe it can now be done. :)
    smealum likes this.
    • Former Staff

    Another World Emulate the Planet!

    Member Since:
    Jan 3, 2008
    Message Count:
    10,351
    Location:
    From Where???
    Country:
    Colombia
    there is a great portal based portable, stillaliveds. =)

    -another world
    • Member

    relminator New Member

    Member Since:
    May 28, 2010
    Message Count:
    333
    Country:
    Philippines
    Cool stuff smea!

    Does your lighting model do this?

    1. Calculate angle of incidence(dot product)
    2. Do a gouraud shaded texture via glcolor value taken from dot product above?

    Anyways, does it use some spatial partitioning (then boxtest) to speed up rendering?


    Very cool!
    • Member

    smealum growing up sucks.

    Member Since:
    May 1, 2006
    Message Count:
    510
    Location:
    Paris
    Country:
    France
    That's actually a great idea that I think is very doable with the way things currently work. Of course I'd have to make a lot of changes and it would be more limited than the real portal, but I'll try to at least get a prototype running. And having this with an on-board level editor and hopefully a way to share testing chambers would make it even cooler.

    1/2. My lighting is done through lightmaps; it's terribly vram-hungry and not that great a fit for the DS, but it allows for lighting effects it couldn't ever dream of otherwise. So yes it does take the angle of incidence into account, but it also takes geometry into account, ie whether there's something in the light's way or not.

    Right now there is no real culling unfortunately, I didn't have time to get it ready in time for the competition, and I couldn't really think of a good system that wasn't complete overkill for the way my engine works (like quadtrees) anyway. That's one of the top things on my list though.
    • Member

    relminator New Member

    Member Since:
    May 28, 2010
    Message Count:
    333
    Country:
    Philippines
    Lightmaps like bunch of light textures? If so you might want to use this to save VRAM:

    http://blackpawn.com/texts/lightmaps/default.html

    I don't think a tree based system would work well on the DS (That bug where the arm9 gets really slow on non-sequential access).

    Well you can read my pseudo tute for quadtrees and octrees (FreeBasic though):

    http://rel.phatcode.net/index.php?action=contents&item=Tutorials


    But I'd rather use a grid system on a DS.
    • Member

    smealum growing up sucks.

    Member Since:
    May 1, 2006
    Message Count:
    510
    Location:
    Paris
    Country:
    France
    Well obviously I already pack my lightmaps, it wouldn't be anywhere even close to a viable system otherwise. :P
    As for quadtrees, I know how they work and have made implementations in the past, it's just that, as I said, they're not what I need for this project.

SPONSORED LINKS
 

Share This Page