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 Chat / Is there anything like a Minecraft clone out there, made with AGK?

Author
Message
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 13th Jan 2019 15:49
Added an Add cube to the mesh



Left mouse click

BUt the coords to where the pointer is are just not correct and need time to work that out
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 13th Jan 2019 19:07 Edited at: 13th Jan 2019 19:08
How does this look for everyone

FPS, Render Distance etc etc

Does it blow your systems up at all?



Shall work out the coordinate system within the next few days to be able o identify which blocks to add and remove.

Just moving around at the moment.

Attachments

Login to view attachments
Chmava
5
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 14th Jan 2019 04:21 Edited at: 14th Jan 2019 04:36
Well, We kind of needed AppGameKit 3d physic calculation even if it is bloated...
But that is alot of chunk and cube... tempting to try custom physic...
Need to look at the source...
Perhaps there is a way to inject a physic engine like havok.

Then again, there is a cheap way to do physical for all object using setposition instead...
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 14th Jan 2019 10:01
Hi. For meshmemblick chunks with 16x16x16 will be just 1 agk object for my version. So physics would only work on those chunks instead of cubes..

. Unless your thinking this for your tier 2 version.

Keep at it
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 14th Jan 2019 18:16
Identifying World Coordinate experiments on a 64 x64 chunk



Left clilck to Add cube at the moment and selected area

Shall continue to experiment with removals and height organising


Use the texture i posted a bit back

fubarpk
AGK Developer
Gold Codemaster
14
Years of Service
User Offline
Joined: 11th Jan 2005
Location: Adelaide
Posted: 14th Jan 2019 20:26
works well
fubar
Kakise
AGK Tool Maker
2
Years of Service
User Offline
Joined: 25th May 2016
Location: Paris
Posted: 14th Jan 2019 21:18
That's a really cool program ! Works well here
PCG Lover
Using AppGameKit Tier 1&2

My creations:

[Tier 1 PLUGIN] Wave Function Collapse for Tier 1
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 15th Jan 2019 12:36
Thanks both.. Will do more later today on the removals if I can find the mesh vertexes correctly

Must admit, the code is much cleaner than any of done previously and will try and keep it that way too.
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 15th Jan 2019 18:08
Niiiiccceeee - Removal blocks here we come, just does 1 height level at moment - its just to get the coord vertex numbers in order




Left click to add
Right click to remove

Come back soon with more developments on better height organisation
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 15th Jan 2019 18:40 Edited at: 15th Jan 2019 18:50
A little brain teaser,

ok, here is my crazy method to get the X and Z coords of where we are on the mesh to idenfity the block at hand



Doing this, the Y gives incorrectness to what we need - it gives the coord of the screen to where the mouse is on the screen

But we really need to have back is

global collisiondata as _CollisionData[size,size,size]

so it as the Y addresses for the chunk to decide if a block is Air or Empty

instead of the way its working now by

global collisiondata as _CollisionData[size,size]

But the Y in the function about wont bring in the data for the Y in the array

Time to have a think...



EDIT -- I have added the 3 Dimensions back in - for X,Y,Z coords



Still works for add and remove but only on the first layer until got the screen vector for Y worked out
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 15th Jan 2019 19:39 Edited at: 15th Jan 2019 19:51
I think its staring right at me

We can get the height from the Mesh VertexList Y array data of the particular X, Z cube location



Will code something up later to make that happen but for now its time to chill with YouTube and rest my weary bones

Catch up soon

EDIT--PS.. after thinking.... Dammm this is tough to work out for a novice,, We will get there though....
fubarpk
AGK Developer
Gold Codemaster
14
Years of Service
User Offline
Joined: 11th Jan 2005
Location: Adelaide
Posted: 16th Jan 2019 00:00
The adding and removing is getting there and works well
I think this is a better method than you first tried
fubar
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 16th Jan 2019 09:30 Edited at: 16th Jan 2019 09:41
So we know x and z so to find the vertex index in the array to find a cube will be

Vindex = ( (Z * 36) * chunkwidth) + ( x * 36)

Y = meshid. Vertexlist[ Vindex]. Y

Or make our own bounding boxes for each cube and use a collision technique with that bounding box data....

Interesting
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 16th Jan 2019 19:51 Edited at: 16th Jan 2019 19:52
It seemed pretty straight forward to get the Y






Tidying up to do and bits and peices on the chunk. Like expanding and varying the chunk size Y to say 256 --

eg

X-32 - Y-256 - Z=32

and generation of chunks under the ground to still tidy up too, just not 100%, but getting there now
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 16th Jan 2019 20:18 Edited at: 16th Jan 2019 20:19
Fixed the underground development



Enjoy - catch up soon

EDIT-Its amazing when one has a break from something...
chafari
Valued Member
12
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 16th Jan 2019 20:24
Quote: "EDIT-Its amazing when one has a break from something..."


You nearly got it !!
I'm not a grumpy grandpa
Chmava
5
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 17th Jan 2019 07:22

Do you have a tier 1 function for calculate total vertex from meshmemblock?

It felt like agk is missing a function called GetMeshMemblockVertexCount();

I am going to look at the counting the byte.
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 17th Jan 2019 07:49
You can get the vertex count by using

Getmemblockint ( meshmemblock, 0)

))
Chmava
5
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 17th Jan 2019 10:24
I mean I need the inputting vertex value to key in that specific value before turning it into an object, lol...
Is this why you use a type to store the amount of vertex?

basically, I think what you are doing is this? https://answers.unity.com/questions/764334/how-to-combine-multiple-meshes-into-a-single-mesh.html

What I am doing is specific to that.

Mainly because I just loaded a very very high polygon object, and I am still getting over 2k fps...

we are starting to think we should just make a chunk object with 1024 * 16 * 16 cube worth of polygon and use smart mesh id system to turn it off...
But mesh id is base on material id...
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 17th Jan 2019 11:05
Awesome idea there to have 1 huge polygon box the size of 16*1024*16,assume then to break into it by a greedy algorithm or octree methods to add new vextexes to resemble cubes into that massive chunk

Am I right in thinking that's what you mean your trying to do

The mesh build function I use. Use vertexlist array yes and add 3 vertex commands, to indeed add at least a triangle

I'll have a think about your idea
fubarpk
AGK Developer
Gold Codemaster
14
Years of Service
User Offline
Joined: 11th Jan 2005
Location: Adelaide
Posted: 17th Jan 2019 11:53
I think pulling vertex's upward and downward for adding/removing blocks might be the go (as I believe you've demonstrated)
just need to adjust the uv's of each blocks texturing for each raise/lowering of blocks.

Think that may be the fastest most efficient
fubar
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 17th Jan 2019 12:46
hmm interesting - the way im interpreting this is

So if we have a massive cube (the chunk).. at 16x1024x16 - been one 24 vertex cube primitive - FPS will be a WOW! cause only showing 1 cube but...

if we say add a cube in the centre at the top of the chunk. We really do need to add 24 new vertexes instead of pulling from vertexes underneath - cause 1 cubes 24 vertices just makes that 1 chunk cube - there is no way we can split it up.

What if we say we add 5 cubes on top of each other then yeah we could scale up the cube to make it go higher, but what if we remove the middle cube of that 5, we will need a technique to resolve that. things will start to get a little more challenging to manage.

Im sure it will be good to try the method one day and will need some think time on how that's best achieved.

and what if we start the world with like a perlin noise structure. we still going to have those cubes at different heights anyway, think this method will be quite challenging and not sure if it will be high processing


I shall keep going on the method im currently working with and see how it goes.

Tonight will make the cubes have no sharing faces attached to them - this will reduce the vertex count and increase the FPS (a little)








Chmava
5
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 17th Jan 2019 15:00
Like another game, player will be able to mod it by writing a txt with vertex data.
This allow unique mod or something.

Also, without bone and animation data in a cube, it speed up the program alot!

Tried 100 100k polygon object and got 60 fps.
Gonna try a 10m polygon object.
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 17th Jan 2019 15:14
Great stuff. You will have to share some code as it would be interesting to see how your managing it too on tier 1 I assume...

Tier 2 for me won't happen. My knowledge is rubbish with c++... Which I'm sure around 50 % of members viewing the thread also same. But good to have tier 2 version too I'm sure.

I aim to get this app finished one day. So then can let TGC have a look to add to their collections for new tier 1 beginners that arrive in the agk scene

Keep at it....
puzzler2018
1
Years of Service
Recently Online
Joined: 8th Oct 2017
Location:
Posted: 17th Jan 2019 17:17

Login to post a reply

Server time is: 2019-01-17 20:26:45
Your offset time is: 2019-01-17 20:26:45