PDA

View Full Version : g2mp cross platform pascal engine



Dan
16-12-2015, 03:46 AM
Hi everyone, this is not a public release announcement (the engine is still in development), but more of a work in progress tracker.

here is a small demonstration of the engine. creating a simple 2d platformer (3 parts):
https://www.youtube.com/watch?v=_qbLWyoUhR8&ab_channel=DanSoftStudio
https://www.youtube.com/watch?v=qSd0TJADFJo&ab_channel=DanSoftStudio
https://www.youtube.com/watch?v=GahpaWKIQYg&ab_channel=DanSoftStudio

if anyone wants to take a look at the engine: https://github.com/MrDan2345/g2mp

SilverWarior
16-12-2015, 05:22 PM
Interesting indeed. While I'm not much interested in platformer games I must admit this still looks quite interesting. Maybe some day I might even give it a try.

phibermon
16-12-2015, 07:05 PM
Not just for platformers - a monumental achievement! brilliant WYSIWYG editor, intergrated physics - the works - I love it! I note the use of a GUID for each object so... perhaps you're planning on synchronizing across a network / offering multi-player functions?

Fantastic! although I'm biased as this is more or less what I've been working on but in 2D and more production ready :)

Since we face many of the same design challenges perhaps we can exchange ideas one of the days? might make both our systems better for it?

Keep up the excellent work! there's a lot of great engines but having a workflow tool like this to create content and debug game-play makes your engine the best choice by default - even if another had more features it wouldn't matter as your system clearly shaves off a bomb load of development time

Dan
17-12-2015, 07:39 AM
thanks for the comments guys! the engine is indeed capable of much more than just platformers. you can very easily prototype almost any type of 2d game. like this for example: https://www.youtube.com/watch?v=xlSdLmGGU7Q&ab_channel=DanSoftStudio

the toolkit currently only has desiging tools for 2d games, but the engine itself can be used to make 3d graphics as well. I am planning to create similar tools for making 3d games in the future.

phibermon, I have seen your very impressive work and would love to share some ideas. but as far as I remember you decided not to release the source yet, is that correct?
as for GUIDs, from my experience in the gamedev industry it is impossible to overestimate the importance of being able to uniquely identify objects in the game, whether it is for serialization, multiplayer syncing, gameplay recording or a number of other applications. I am not entirely convinced that the GUIDs are the best approach though, mainly because they are not inexpensive to generate (might need to do some testing and profiling). I would love to know your opinion on this.

Vinzvega
17-12-2015, 05:20 PM
Hi Dan,

Congrat for this work ! Amazing ! Game WorkFlow is definetly a real challenge, outside the item creation, in a game creation process (Or other type of program !)
--> I will take a look quicly.

Hey, Your soccer game is nice : you should spread it on mobile shops :)

Regards,

Dan
21-12-2015, 05:46 AM
phibermon, sorry I could not answer sooner, I noticed you deleted your message so I will try to answer to it as best as I can from memory. pregenerating a large number of GUIDs and storing them in a file is an interesting idea, but it will create several other complications. first of all, no matter how many GUIDs you pregenerate there will still be finite number of them, and you can, in some cases, run out of GUIDs very quickly (imagine a shooter game, where multiple characters are shooting bullets with each bullet receiving a GUID). assuming that you would load the entire file into memory (since reading the file every time you want to pull a GUID would make the process even slower), you will have to allocate a large chunk of it, which is not optimal and on some platforms even not acceptable (with 32 bytes per GUID, thousands of them will leave a noticeable footprint on memory). finally it is not multi-thread friendly since you would either have to sync multiple threads trying to pull GUIDs or create some sort of mechanic to pull GUIDs from different parts of the array.

regarding scripting I actually did integrate pascal script into the toolkit only to realize that there is no advantage to do that. fpc can compile sources in seconds, it has more language features than most scripting languages and the performance is on a completely different level. so if I decide to add some sort of plugin system then I will simply use fpc.

Vinzvega, I am actually working on the easy android build system (to build and install apks with a single click) when that is done I will port that soccer game to android.

AirPas, the source editor is still missing many features, I am planning to work on it some time in the future (will look into making the text more sharp). for now, however, there is a "Create LPR" button that creates a lazarus project with all the necessary dependencies. so you can just open that project with lazarus and build from there.

Dan
22-12-2015, 05:29 AM
one more video. 2d particle editor in the toolkit: https://www.youtube.com/watch?v=lKz8YZrgX44&feature=youtu.be&ab_channel=DanSoftStudio

phibermon
22-12-2015, 01:24 PM
Top stuff Dan! your compiler intergration and many aspects of your interface are well in advance of what I've created - editable curves for opacity and the such is a great way to go! I've gone with a time-line that spans a particle life and mutators/effects are dropped onto / stretched across portions of the timeline to apply different things such as opacity fades - however because they apply relative changes and not absolute changes I lack the fine grain control of your curves - basically the same in principal but your system appears to be better to work with - I think I prefer your idea :)

EDIT : gah I knew I should of stuck with 2D - I just can't develop as fast - you've got so much wrapped up and working like a charm meanwhile I'm neck deep in 3D stuff - absolutely fantastic work Dan - I'm really impressed - this is what we've all needed for a long time! :)

Can you have multiple layers for your scene? for parallax scrolling of backgrounds? they could be coded by hand by the player but I think layers in a hierarchy with a scalar factor and an assigned 'tracking node' which is used to move the layer (applying scale and position relative to parent) would be a great thing to wrap up in your GUI - especially if you can apply visual effects to entire layers - for example washing out colour for 'far away' layers - I think it would be an apt feature to what you've created - if you've not already done it :D

Dan
23-12-2015, 04:05 AM
I think there is nothing wrong with focusing on 3d, but the reason I started with 2d tools is because I wanted to workout all the UI controls while doing something simple. later I am also planning to work on 3d stuff, so in some way you are actually ahead of me :) and of course I also still have lots of bugs to iron out so it's not all rainbows and unicorns, yet ;).

the parallax scrolling is very easy to achieve. all you need to do to create a background that seems infinitely far away is set the position of that entity to the position of the display (the scene to screen transformation manager). if you want to make a layer seem a bit closer then you just need to set its position to something like dipsplay.position * 0.9 and you will have a parallax effect.

SilverWarior
23-12-2015, 05:18 PM
Actually the parallax scrolling is achieved by simply combining two or more layers where background layer is moving at a lower speed than the foreground layers.
And you can get even better impression by simply increasing the number of background layers. And by controlling their moving speed you can change the impression of how far away from the camera they are.

Dan
19-01-2016, 08:35 AM
hi everyone, I am back with another video of building for android in g2mp toolkit. this is a very experimental feature at the moment. the testing device in the video is an ARM android emulator so the performance is slightly below excellent;)
https://youtu.be/PXHwAIJ8WQk