Building game

Hey all, after getting my iPad back from repairs, I’ve embarked on a new journey of trying to create the most openly editable 2D game on the AppStore, it’s not much yet (because I started work on it 2 days ago) but its a start. My plans for this app is to add Lua or make a custom language later on so the user can create scenes purely from Lua.
At the moment you can spawn a box and a ball, change their size, angle relative to position and freeze it in place. The gun shown is what manipulates the physics bodies, but I’m going to add a constraint tool to weld,axis,rope,… physics objects together to create a game where anything (nearly anything, getting a life in it isn’t possible!) is possible. From buildings to cars to rockets and more. At this current moment in time, the play is represented by a white box, I will sprite sheet it later as I like to make my own graphics (that was a lie I’m terrible at it, someone offer :stuck_out_tongue: ). If anyone has ideas or suggestions as to what the game could do with then fire at will. Thanks! And before I forget:

Cool! You should turn it into a puzzle game of some sorts!

@Prynok I was thinking fantastic contraptions sort of game with a twist of being able to create things with no goal but to make it fun enough to enjoy.

Looks like an early draft of Little Big Planet. And I mean that in a good way.

I love this kind of thing.

Thinking along those lines, could you do something like LBP? Give people a dozen or so levels to complete as an example of the kind of thing that can be built with the tools, then open up the toolset for them to experiment and trade.

@Mark that is a great idea, I didn’t start off with a LBP idea it was gonna be a sandbox with a procedural level generator based on user input (an algorithm using for example sin and cos for tiny wings like level) for finished contraptions and such… or a few prebuilt levels. I’m considering which direction to go, LBP with a few fun games to start with (might mean I need to find someone to help with graphics or spend each day learning how to make good graphics!) which will obviously be half the game itself added on to the sandbox mode, or just the sandbox. So it’s a bit more effort than I had previously thought… But if I do that I can use all the models (physics objects) in the levels and easily have them generated in the sandbox, unlocking each one as you pass levels containing them. That’s some inspiration right there, thanks! I’m wondering how the tool set should be unlocked. I’m going to take full advantage of the box2d constraints then look at making some custom constraints.

I think I’ll finish the sandbox with full tool set then get started on the levels and level maker, I hate doing it manually. If you have any other ideas please keep them coming, I’ll post some progress soon.

Progress report, added 2d lighting for dark levels, I’m planning on making night and day time levels, maybe an evening level just to spice things up a bit.

Very cool. I can’t wait to play it.

@Luatee Looks awesome, I love these kinds of games. I look forward to seeing where you take this.

Progress report: added tool gun with 3 modes and decent (for me) graphics for tool gun and physgun. Tool gun needs some sort of shooting effect to show where it goes.

If anyone knows how, I would like to add an effect for the remover tool where the removed object splits in to fragments and falls off the screen. I have an idea of how to do it but it won’t be efficient enough, thanks!

Awesome looking forward to playing this :slight_smile:

@Luatee - Are you using meshes for all your objects? I assume not because you’re using only squares and circles. If you want to make and display polygons, try using meshes. So take all the points and use the triangulate function on it. That returns the mesh points for that polygon. Anyways, for a fragmentation effect, you can take each triangle of the mesh, put them in individual meshes, and make them fall. Hope that helps. Let me know if you want any more help. You can also do it the efficient way (like in my game) where you just draw a ton of triangles in a particle engine with gravity. I’m also sure you can do this somehow in a shader, but I have no idea how.

Don’t worry I’m aware of that @Zoyt, I’m using meshes for every object, I find rotating sprites a pain in the ass when I can do it with meshes in 1 line if using a quad. I haven’t added polygons because I’m thinking of going with Marks idea and just have objects from the levels in game once they’ve been made, and add more primitives. Is that fragment effect in stackit? I’ll have a look to see if it fits but ideally I would want a shader, it’s more efficient and easy to apply.

@Luatee - I just use particles. What I do, is I pass in an image of a triangle, enable gravity, and turn on the streak effect. I can give you the presets if you want. I’m using @John’s particle class. Anyways, I’m tempted to try and make this effect. I’ll see if I can do it on my plane ride.

@Zoyt thanks that’s great, I’ll resort to confetti particles if I can’t find how to do the fragment effect

This looks very nice! I think you should kinda make a puzzle game where you control a character that has the put objects at certain places to continue (like if you put a object at a butten a gate opens) something like portal but without the portals!

Looks great, and all in 3 days of coding! Very impressive.

@Luatee - I just got off the plane. It’s easy as pie to split a mesh up into triangles and convert them to physical triangles. It only took about 5-10 minutes. Here’s my example code:

Yeah thats what I had in my @Zoyt thats brilliant but a square mesh will always fragment in to two because its made from two triangles, so its only good on complex polygons

@Luatee - Easy to fix. Let’s see if I can fix it.

Here’s some progress, added effect for tool gun, seems slow due to video recording frame rate. Other various improvements and fixes. Also added a grid for alignment of joints and physics bodies. What else can I add, box2d joints are limited in codea. I’m going to add springs with use of offset force.