Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Is there anything like a Minecraft clone out there, made with AGK?

Author
Message
puzzler2018
User Banned
Posted: 29th Jan 2019 22:58 Edited at: 29th Jan 2019 23:03
Mesh memblocks is not scary - promise people... its worth learning

I wouldnt got where I am today wish Mesh Memblocks without (in no particular order)

Tom Toad (not sure if he realises)
Rick Nasher
Fubarpk
Santman
Janbo
Bengismo

and few others

Cheers guys
puzzler2018
User Banned
Posted: 31st Jan 2019 22:01
I feel ive dismissed this a bit - so will catch up with this work at weekend amongst other things

Things to acheive this weekend is:-

- Removal / Adding blocks to the new way of collisioning we created together (by ideas from other threads).

- occluded faces implemented properly

- Multiple Texture mapping cubes on an Atlas map (done this before) but could be better

Think that will do for a weekend

puzzler2018
User Banned
Posted: 3rd Feb 2019 22:35 Edited at: 3rd Feb 2019 22:35
I must have brought an idea with lego working on Minecraft style engine but with the nobbles

https://forum.thegamecreators.com/thread/223727
puzzler2018
User Banned
Posted: 10th Feb 2019 20:40
This is a very extremly interesting video about using normals to work out to cull backfaces or not - its just about the order of how we building triangles/vertexes up - all must be in a rotation manner

Quite pleasantly surprised



puzzler2018
User Banned
Posted: 11th Feb 2019 12:49
So as long as we define the cubes vertexes (or any objects) the right way round (clockwise) or (anticlockwise) and not a mixture then, work out the Normals for each face.

Just as long as every single triangle uses the same rotation premise on building it, then the normal results can be used to decide to draw or not a face.

So, If the results

Normalise()

if sqrt( NormalX# + NormalY# + NormalZ# ) > 0

draw that face to the mesh

else

don't bother

endif

Amazing trick!! and cannot wait to give this a bash pronto!!

chafari
Valued Member
17
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 11th Feb 2019 20:42
Nice video puzzler . This is the way freebasic works....I love it !! and is total free ...Somehow we have to fooling the eye to give the appearance of 3D .

An easy example converted to Agk.


I'm not a grumpy grandpa
puzzler2018
User Banned
Posted: 11th Feb 2019 21:20
Wow - nice snippet Chafari - works well but the projection is slightly off when go up and down on the Y but should be easily remidied with multiplication matrixes

Thanks for your time and input..

fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 11th Feb 2019 22:07
that's Clever Chafari
fubar
chafari
Valued Member
17
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 12th Feb 2019 00:33
@puzzler / fubarpk thanks for your coments. This snippet needs some adjustments to work correctly. We have to limit the y movements and draw top & down face. I made this inspired by the video tutorial. Theres a tecnic of raycasting that looks like maze 3D using 2D programms .
I'm not a grumpy grandpa
puzzler2018
User Banned
Posted: 12th Feb 2019 12:37
Well done chafari. Ya bet me to it lol.
puzzler2018
User Banned
Posted: 12th Feb 2019 22:08 Edited at: 12th Feb 2019 22:17
Here is my version of basic normalising normals



Normalising



I will convert this to a cube soon and then many OBJs

Catch up soon
Tier 1 Developer
puzzler2018
User Banned
Posted: 20th Feb 2019 23:01
thought to bump this before becomes locked

Ill get to this soon

Tier 1 Developer
nonom
6
Years of Service
User Offline
Joined: 12th Nov 2017
Location: Picking mushrooms
Posted: 9th Mar 2019 16:27
Quote: "Rome wasnt built in two weeks - if this takes 2 days/2 weeks/2 months or 2 years. then im happy, as long as get this 100%"


Let me hijack your thread like you did with the mine. A few threads (months) ago you was really angry, at this point, i tho to nomitate you like valuable peson because I don't like the people crying.

Your work is much fine, but the person is so farof his work, this thread talks itself.

Stop trolling the threads and focus in your own work.
nonom
6
Years of Service
User Offline
Joined: 12th Nov 2017
Location: Picking mushrooms
Posted: 9th Mar 2019 16:29
Seems the forum cannot let me post in your thread like you did in the mine.
puzzler2018
User Banned
Posted: 9th Mar 2019 16:30
But chill out - This is Xaby thread

Tier 1 Developer
nonom
6
Years of Service
User Offline
Joined: 12th Nov 2017
Location: Picking mushrooms
Posted: 9th Mar 2019 16:30
Still spamming about your version of Perlin Noise?.
puzzler2018
User Banned
Posted: 9th Mar 2019 17:51
Hey folks - I might actually pick this up again later in the year after a small break with different programming styles maybe..

But there will be lots more meshmemblock and memory management building to make this world even bigger.

and yes there will still be Perlin Noise to it..


Tier 1 Developer
puzzler2018
User Banned
Posted: 11th Mar 2019 22:21
Now we moving on to Studio - I just had a thought on Studio could handle this? any thoughts?
Tier 1 Developer
Santman
12
Years of Service
User Offline
Joined: 15th Sep 2011
Location: Inverness
Posted: 12th Mar 2019 01:13
So at the moment studio is just an ide.......it's identical to agk.
puzzler2018
User Banned
Posted: 12th Mar 2019 22:34
lol - I was thinking more on what Vulkhan can give us for this type of app
Tier 1 Developer
Santman
12
Years of Service
User Offline
Joined: 15th Sep 2011
Location: Inverness
Posted: 13th Mar 2019 09:45 Edited at: 13th Mar 2019 09:46
Ah I see. Well from what I've seen on YouTube, Vulcan apparently gives a 20-30% increase on glsl, but that I think is a newer glsl than AppGameKit has, so I'm hopefully for a bit of a boost ... but I wouldn't expect miracles.

In terms of 3d performance and tier 1, the core of agk is a restricting factor.....for example Preben significantly increased the speed that transparent and hidden objects were handled through optimisation, and that's key for agk.

For this though, how is that a hold up? I already showed agk can handle tens of thousands of blocks in 4k at 50 ish fps....are you having major frame rate issues? How memblocks are handled won't be impacted as they are nothing to do with the gpu, and as we dont have threading handling background generation of landscape and ai is also always going to be tough.

Don't you recall the original Minecraft, huge holes in the world, chunks not generating, people falling into nothing etc?

The new modern Microsoft version is super slick, and highly threaded process driven.
shadey
14
Years of Service
User Offline
Joined: 25th Jan 2010
Location:
Posted: 18th Mar 2019 19:15
I have been messing with the 3D for some time now, and found indeed that even just using single faced planes( the ones blender creates) ... the more you use simply the more AppGameKit 2 slows down, totally not a poly count issue par say when it comes to speed,but obviously decimate the hell out of high poly counts!!

I had created a 3D Editor to place many grouped objects easily,and though it is still handy to place objects visually, it is the 'many' bit that I wont be doing under AppGameKit 2 as it stands! I am hoping this VULCAN thing improves this myself! This is strictly mobile type speed I am talking though!
Hail to the king, baby!
puzzler2018
User Banned
Posted: 18th Mar 2019 19:24 Edited at: 18th Mar 2019 19:25
Thanks - the reason why it slows down is because of the amount of "draw calls" the CPU sends to the GPU

a 10x10x10 chunk say is 1,000 objects, so 1,000 draw calls to the GPU in one sync frame

- we just need to build that chunk to a meshmemblock first so that it only sends 1 draw call

Hope that makes sense
Tier 1 Developer
shadey
14
Years of Service
User Offline
Joined: 25th Jan 2010
Location:
Posted: 18th Mar 2019 20:35 Edited at: 18th Mar 2019 20:45
of course it does! this would be handy for my editor as i would be ultimately saving out and dealing with one object,as opposed to possibly hundreds!!
Right now I am using blender to simply sculpt my landscape for instance a golf sim:




This is fast because I am only dealing with 2 objects here, the ball and the whole landscape, previously I had done about the same level using separate objects in my editor,planes/trees and so on...
However every object I added, the more it slowed down on runtime, no matter how much I decimated the models in question, like the tree, and I had a giant rock.....!

I know what you are after here is minecraft and yeh,the only way for speed is what you suggest!
Essentially you want to be doing simply what blender does when I export the scene as a .obj file!
Another good reason is that you end up saving enough speed to add realtime shadows and the shaders that some people useI they really do make a game look more polished, and because of the use of only 2 objects, will be using realtime shadows in the above golf I hope!
Hail to the king, baby!
puzzler2018
User Banned
Posted: 18th Mar 2019 20:46
Sure - that looks like a promising app too.. we all like a bit of tactical golf these days.

yes - adding more and more tree and rock like structures will make FPS come down a few bars... thats all depends on the poly counts for each.. and adding Shadows will seriously decrement it too.

If you need something to start you going with meshmemblock then i can post a template.
Tier 1 Developer
shadey
14
Years of Service
User Offline
Joined: 25th Jan 2010
Location:
Posted: 18th Mar 2019 20:53 Edited at: 18th Mar 2019 20:58
hmmm,how easy would it be to implement it into my engine though I wonder!!!
It would be very cool if it is easy, then yes please!!
btw, isnt all this only useful for static objects of course?!
But still very needy..
In minecraft you have to deal with the non static A.I!
Another headache, but I have been coding some A.I so not so bad when I realized it is better to increment through an array than using a loop!! as you get to hit the syncs() quicker!
Hail to the king, baby!
puzzler2018
User Banned
Posted: 18th Mar 2019 21:08
We will have to rebuild the mesh each time there is a change of an object - but if make the meshmemblock small enough, would have to be on a mesh grid system

Like



Where the red sqaure is the mesh the player is located on and any objects that move about say will be objects on that red sqaure that would be rebuild. when move around - then we just change the mesh to the land area of where the player is on the grid.

The golf ball will just stay as an AppGameKit object

Difficult isnt it

Ill try and put this theory into practice for you - but not jut now, in a few days ill provide some code to see it in action

What are your trees and rocks - are they OBJ files - cause you will need our OBJ importer too



Tier 1 Developer

Attachments

Login to view attachments
shadey
14
Years of Service
User Offline
Joined: 25th Jan 2010
Location:
Posted: 18th Mar 2019 21:15 Edited at: 18th Mar 2019 21:20
yeh they are .obj,though the engine can also import .fbx for animated objects. And immediately loop plays the first layer upon placing them
I would think your system best suited for static objects and still would be awesome!!
So essentially a good way for me would be to place the objects as i do,in the editor, but then at runtime, just before the main loop, do the magic on all static objects to create a single one
then delete all the static objects used,of course this would require reloading of level after each run
Hail to the king, baby!
puzzler2018
User Banned
Posted: 18th Mar 2019 21:18
ok cool - ill take a look and have a think about that model... Do you have an example FBX file to have a play with..

Could you also possibly create your own thread regarding this, so its not upsetting this one too much. otherwise we all will just get confused eventually and then ill pick this up on that thread


Cheers


Tier 1 Developer
shadey
14
Years of Service
User Offline
Joined: 25th Jan 2010
Location:
Posted: 18th Mar 2019 21:21 Edited at: 18th Mar 2019 21:24
be my guest!! tis your system

But thanks very much if you can help! I just wanted to solidify the facts about speed issues regarding 3D in general and after a solution myself!!
It would be so awesome if AppGameKit 2 had something similar to BSP!
Hail to the king, baby!
puzzler2018
User Banned
Posted: 18th Mar 2019 21:24 Edited at: 18th Mar 2019 21:26
Its not for me to create a thread for you about it - unless really want me to.

If you like - can take a look at https://forum.thegamecreators.com/thread/223640

I can continue this, there

Tier 1 Developer
shadey
14
Years of Service
User Offline
Joined: 25th Jan 2010
Location:
Posted: 18th Mar 2019 21:27
ok.i will follow that! tnx.
Hail to the king, baby!
Santman
12
Years of Service
User Offline
Joined: 15th Sep 2011
Location: Inverness
Posted: 19th Mar 2019 16:21 Edited at: 19th Mar 2019 16:23
Speed isn't just poly count, its draw calls. Been through this before. If you send 6000 objects to be drawn, each is transferred and processed individually. If you merge them into a single mesh, it's one draw call and will be hundreds, or even thousands of times faster.

That's how I had tens of thousands of cubes running so fast, and how I do vegetation.


puzzler2018
User Banned
Posted: 19th Mar 2019 17:53
Yeah i understand perfectly these days - it was more for Shadey



Code to produce that is



This will produce 1 draw call, instead of 58,081 draw calls



Tier 1 Developer

Attachments

Login to view attachments
Santman
12
Years of Service
User Offline
Joined: 15th Sep 2011
Location: Inverness
Posted: 19th Mar 2019 18:11 Edited at: 19th Mar 2019 18:13
Looking back through the thread a little, rocks and trees can all be combined to, where the same texture is used.

For example, just like the grass, every instance of a rock that uses a specific texture can be combined into a single memblock mesh, then all rocks are one draw call. And trees, and anything else that uses the same UV cords and textures.

In my project, the final build does just that, and will scan for duplicate items then combine them into a single mesh for speed. Memblocks, though larger, also load much faster then any model format, especially groups. Loading 80,000+ grass planes in a chunk of a world as one memblock mesh is infinitely faster than loading dozens of models. Plus you only need to assign the one image to the memblock, so that's easier to.

There are lots and lots of ways to get speed up, but a lot of it comes down to trial and error. For example another.....in shaders I've found texture look ups are very expensive, and link to the texture size. By holding two versions in memory, one full size texture and one much smaller one, then swapping between them beyond a certain distance, gave me about a 40%-60% speed boost, even with mip mapping.

3d is a difficult animal to balance just right. Lol.
Xaby
FPSC Reloaded TGC Backer
17
Years of Service
User Offline
Joined: 17th Apr 2007
Location: Berlin
Posted: 2nd Jun 2019 07:33
I wasn't here in a while. Thanks a lot for your hard work with the memblocks and that. Hope we can have a good time here in the board. Feel free to post your progress.
Xaby
FPSC Reloaded TGC Backer
17
Years of Service
User Offline
Joined: 17th Apr 2007
Location: Berlin
Posted: 27th Apr 2020 18:01
How fast time is running. Nearly a year is gone. Did anyone tried something with the code?
Xaby
FPSC Reloaded TGC Backer
17
Years of Service
User Offline
Joined: 17th Apr 2007
Location: Berlin
Posted: 2nd May 2020 10:45
I found this today. Maybe it is time, to create something in AppGameKit again
Santman
12
Years of Service
User Offline
Joined: 15th Sep 2011
Location: Inverness
Posted: 3rd May 2020 23:46
Did no-one ever finish the mine craft clone?
Santman
12
Years of Service
User Offline
Joined: 15th Sep 2011
Location: Inverness
Posted: 19th May 2020 21:56
WHo wants to collaborate on this. I already made the code for the basic world building, and know how to add in destroying of blocks etc, and will move those fucntions to a C plug in for speed - anyone want to have a cracka t doing the seed generation for the world if I finish the basic code?
MADATCHA
5
Years of Service
User Offline
Joined: 17th Jun 2018
Location:
Posted: 20th May 2020 08:29 Edited at: 20th May 2020 08:30
Would love to collab but only working from phone would love to see what you have
Always have fun following you
janbo
15
Years of Service
User Offline
Joined: 10th Nov 2008
Location: Germany
Posted: 24th Jul 2020 21:45
@Santmann: I'd collab but only if started from scratch and hosted on github
Xaby
FPSC Reloaded TGC Backer
17
Years of Service
User Offline
Joined: 17th Apr 2007
Location: Berlin
Posted: 27th Jul 2020 05:45
@Santman, what do you mean with C-plugIn? Will it run on Android 4.1 than? The thing Puzzler2018 build with Memblocks seems ultrafast.

@janbo sounds great.
janbo
15
Years of Service
User Offline
Joined: 10th Nov 2008
Location: Germany
Posted: 27th Jul 2020 11:25 Edited at: 27th Jul 2020 11:29
@Xaby: I wont start this on my own so hit me up with the Github link

I actually made a voxel game before Minecraft was a thing, and rewrote it in AppGameKit again 5 jeahrs ago: https://forum.thegamecreators.com/thread/215869
The thing missing, was combining the faces into chuncks, the rest was there... checking neighbouring blocks for face generation, Box UV coordinates, Creating/removing blocks...
Santman
12
Years of Service
User Offline
Joined: 15th Sep 2011
Location: Inverness
Posted: 28th Jul 2020 17:26
Janbo, what do you mean starting from scratch? If you've already done voxel stuff then there wont be anything left to do there, it's just the procedural stuff left.
janbo
15
Years of Service
User Offline
Joined: 10th Nov 2008
Location: Germany
Posted: 28th Jul 2020 20:49 Edited at: 28th Jul 2020 20:55
Well the code is from my 9-5 jeahr younger me, and I think I can do it much better now.
And everyone can jump in and help...

For the procedural stuff I guess I have 2D and 3D perlin noise too ^^
Used it for marching cube terrain...
Xaby
FPSC Reloaded TGC Backer
17
Years of Service
User Offline
Joined: 17th Apr 2007
Location: Berlin
Posted: 30th Jul 2020 10:01
@Janbo, did "War Balls" still exists? Reminds me on "Puzzle Dimension" from "Doctor Entertainment AB"

Tell me, if that is like you thought about. Is my first time I made on.
https://github.com/Xabyn/agk_wurfelcraft
janbo
15
Years of Service
User Offline
Joined: 10th Nov 2008
Location: Germany
Posted: 30th Jul 2020 10:19
Never finished it, but the code is somwhere on my harddrive.

Yeah, we can chat over Discord, work together and I'll show you how great Github is

Login to post a reply

Server time is: 2024-04-20 00:19:50
Your offset time is: 2024-04-20 00:19:50