What is Codea Craft?

IgnatzIgnatz Mod
edited June 2016 in Codea Craft Posts: 5,396

"Codea Craft is a voxel-based programming sandbox that lets you create and change anything you can imagineā€¦"

" a Minecraft-like creative coding and game development tool on iPad being designed for both children and young adults."

Come on @John or @Simeon, tell us more..

Comments

  • edited December 2015 Posts: 257

    Very Good Work, Thanks.

    It would be great to have an option to smooth curve from cubes
    ( bezier curve in 3d ) and possibility to modify scale or cube's width ( to build chair for example) . It was simple and realistic. I buy

    Because it exist yet sculpt 3d apps and minecraft apps but never software between the two :)>-

  • IgnatzIgnatz Mod
    Posts: 5,396

    Assuming Codea Craft is a block world, I have a question. When I built a 3D scene with blocks, I put them in one mesh for speed, and still needed to cull hidden faces to avoid slowing down too much.

    But if your blocks can be moved or destroyed, then do you keep them in separate meshes, and what do you do about hidden faces? How you optimize performance?

  • Posts: 2,020

    Perhaps the voxel engine is written in C or Swift.

  • SimeonSimeon Admin Mod
    Posts: 5,387

    It's a project @john has been working on. Basically it's a voxel world building environment where you can attach code to blocks. And you can also code the procedural world generator.

    In the video above @john created a block with a script that causes it to grow outwards and upwards. Then placed it and watched the algorithm evaluate in the world.

    The Voxel engine is C++ and it's something I'd like to pull back into the main version of Codea and expose through an API. Codea Craft uses a custom voxel renderer instead of the regular runtime (to do things like ambient occlusion and voxel-specific occlusion culling).

    @Ignatz I will try get @john to explain the optimisations. I think the most basic one is that all internal structures are removed (so only the visible surfaces of voxels are rendered).

  • IgnatzIgnatz Mod
    Posts: 5,396

    Thanks, @Simeon, what I'm most interested in is how he replaces culled faces if they are exposed later, by other blocks being moved or destroyed

    I'd also be interested in any of his techniques or algorithms for efficient drawing of large numbers of 3D objects, and occlusion.

  • JohnJohn Admin Mod
    Posts: 622

    Hi @Ignatz,

    The way the voxel renderer works is very similar to Minecraft. The world is divided into a 2D grid of chunks (each is 16x16x128 blocks). Whenever a block is modified (or removed) it's chunk is marked as dirty and then gets re-meshed in the next frame. Any blocks faces that are occluded by other solid blocks aren't generated. In some cases when a block is modified on the border between chunks, multiple chunks will need to be re-meshed.

    Meshing starts from scratch each time a chunk is modified, there is currently no smart algorithm for reusing vertex buffers and I don't have a greedy algorithm that merges planar surfaces based on materials and textures.

    The flags are used to allow for multiple block edits per frame but only a single re-mesh operation. The bounds of each chunk are computed during meshing, which is then used with frustum culling so that non-visible chunks aren't drawn.

    In order to speed up the meshing algorithm, chunks store copies of adjacent blocks on their borders. When modifications are made these copies need to be updated to keep everything in sync (this is quite tricky and error prone).

    There are quite a few other optimisations but these are the basics. Also much of the work is done is multiple threads, such as terrain generation, saving and loading.

  • IgnatzIgnatz Mod
    Posts: 5,396

    Thanks, @John, much appreciated

  • AnatolyAnatoly Mod
    edited December 2015 Posts: 889

    Where to download?

  • IgnatzIgnatz Mod
    Posts: 5,396

    You can't download it, it is a new app and not finished

  • JohnJohn Admin Mod
    Posts: 622

    @TokOut Codea Craft will be reaching closed beta soon (likely January) and I'll be putting it on TestFlight for selected testers (we'll have signups on the forums).

    My plan is to release it with minimal features and provide updates every month or so. The focus is on letting users create and share content (block types, generation scripts, texture packs, monsters, items).

    The first version will contain:
    * Voxel based world
    * Integrated editor tools
    * Lua scripting
    * First person player controllers (placing and destroying blocks)
    * Custom block type creation
    * Saving and loading block and entity state
    * Customisable world generation
    * Custom texture importing
    * Documentation
    * Built-in tutorial videos

    Additional features coming later:
    * Lighting
    * Custom block shapes (i.e. stairs, buttons, railways, liquids, plants)
    * Transparent block rendering
    * Custom entities (creatures, mobs)
    * Items and Inventories
    * Mod-pack creation and sharing (via copy and paste)
    * UI customisation
    * Codea PIP (popup a self-contained window that has all Codea rendering and API capabilities)
    * Network API

  • Posts: 2,020

    This is an awesome and very original idea. It will go down really well with the modding community (who seem to do everything with Lua scripts, Lua is definitely the number one game-mod language).

  • AnatolyAnatoly Mod
    edited December 2015 Posts: 889

    More Infoseek please. How many will it cost and a SERVER game? First User controls removing and placing blocks. It IS AWESOME! Thank you very much @Simeon, but one question in the next codea version, will there be the game script codes y/n? Like CargoBot?

  • Posts: 1,255

    Very neatly done, guys. Coming up with a compelling development environment for those learning to code is always a challenge (I wrote the Logo-based Turbo Turtle for the original Mac in 1984 before the machine was officially released, but it didn't exactly start a craze). This seems to do a good job of offering the sort of in-game mod system that's actually quite rare.

    I'll be interested to see how you handle the controls. None of the iPad Minecraft clones I've tried (including Minecraft) have felt quite right.

    Then I'll be looking forward to the day when you can "train" and arm ranks of pigmen to man the top of your battlements as they fight off waves of incoming creepers.

  • Jmv38Jmv38 Mod
    Posts: 3,297

    fantastic project!
    i am eager to buy it!

  • JohnJohn Admin Mod
    Posts: 622

    @Mark The default controls will be similar to Minecraft PE, however I plan to make them moddable as well so you can come up with a totally new control scheme if you wish.

  • AnatolyAnatoly Mod
    Posts: 889

    I think it's better then normal MineCraft, but if it's a server game, I know it will be top 1, and @Ignatz, you said both children - who are they?

  • SimeonSimeon Admin Mod
    Posts: 5,387

    @TokOut what @john means is that Codea Craft is designed for children and adults

  • AnatolyAnatoly Mod
    edited December 2015 Posts: 889

    Deleted!

  • edited December 2015 Posts: 505
    :D (- sorry)
  • edited December 2015 Posts: 87

    Cool idea hope I can see it soon

  • edited December 2015 Posts: 557
    Codea will still get love too though right? :)

    There's something I've wondered about with Minecraft-like worlds: you can have blocks, and you can have mobs, but can the blocks themselves become mobile?

    Can you give a block "sentience" and have it move around like a piglet?

    Could you make, say, a big burrowing sandworm out of a huge coordinated group of "sentient" blocks?
  • AnatolyAnatoly Mod
    edited December 2015 Posts: 889

    Will there be also something like "Clash of Codea" or "Asphalt vCodea" or something else?

  • JohnJohn Admin Mod
    Posts: 622

    @UberGoober

    Codea is still going to receive plenty of love!

    Yes, blocks can have "sentience" and move themselves around. I will eventually add support for interpolation so you can have things like pistons, falling sand and, etc... that move over time. Initially blocks will only be able to transfer themselves instantly between grid points.

    For a giant sand worm you would probably make a special 'brain' block that coordinates the behaviour of the worm and then it would also create all the 'flesh' blocks that surround it, which would be added and removed as it moves around. Generating the shape of the worm wouldn't be too hard (maybe a bezier curve combined with a voxel-based line drawing tool), although regularly updating the voxels could slow it down (every frame is probably a bit too much). Cool idea, I might try it out!

    You can update blocks based on events, such as ticks (regular updates), interaction (the user tapping on them), physics (being touched by an object), being exposed to light, being created or destroyed. These events are exposed as specially named methods within a block's class, similar to callbacks within Codea (i.e. touched, draw, etc...).

    @TokOut
    Clash of Codea, now there's a good idea ;)

  • Jmv38Jmv38 Mod
    edited December 2015 Posts: 3,297

    @John we already have a 'crash of Codea' thread... ;-)

  • AnatolyAnatoly Mod
    Posts: 889

    @Jmv3, I didn't mean "crash", I mean "clash": You have to build houses and attack enemy's by coding a cheat or coding a very hard enemy. You can also code the heal or any plugin

  • Posts: 216
    @TokOut it was a pun :smile:
  • AnatolyAnatoly Mod
    Posts: 889

    What's a pun? And @jmv38, I was searching for crash of Codea and clash of codea -> No Results!

  • IgnatzIgnatz Mod
    Posts: 5,396

    @TokOut - Jmv38 was referring to the "what crashes Codea" thread, it was a joke, let's forget about it now

  • AnatolyAnatoly Mod
    Posts: 889

    Oh, I didn't understood what he meant...

  • Posts: 688

    Very cool looking project, can't wait to try it out!

  • AnatolyAnatoly Mod
    Posts: 889

    Will it be free?

  • when will it come out?

  • AnatolyAnatoly Mod
    Posts: 889

    @WlofBoy32, wait they will inform you when it will be ready, a game isn't created in one day! Maybe it will be in Codea App Store Games-Anouncement

  • Posts: 688

    Just wondering - has there been any update on Codea Craft recently???

  • JohnJohn Admin Mod
    Posts: 622

    @TechDojo
    I'm currently working hard to get it ready for beta release (this is taking a lot longer than I originally though). I'm currently focusing on finishing up key features and also making the API as simple and accessible as possible while maintaining the power to create interesting stuff.

    I'll be posting a sticky with more information in the coming week along with some more videos, screenshots and details.

  • Posts: 688

    @John - Can't wait, I love the concept and I think it'll be a massive hit!
    :)

  • I have a question: how to download codea craft?

  • dave1707dave1707 Mod
    Posts: 8,464

    You can't, it's not out yet.

  • JohnJohn Admin Mod
    Posts: 622

    Hey guys here's a progress video featuring some work on integrating Bullet Physics:

  • Posts: 2,020

    Nice! Any chance bullet3D will come to regular Codea too? o:)

  • AnatolyAnatoly Mod
    Posts: 889

    How to get its beta? How many will it cost?

  • JohnJohn Admin Mod
    Posts: 622

    @yojimbo2000 Yes I think so. I plan to make the bindings written for Codea Craft compatible with Codea eventually. No ETA just yet though.

    @TokOut I'll be putting up a beta signup sheet soon. The base cost will most likely be $5.00, which will rise by $1.00 each update.

  • AnatolyAnatoly Mod
    Posts: 889

    And if you buy it on start, and it will rise, you have to repay?

  • Posts: 38

    @TokOut if you buy an app on the AppStore you don't pay for it again. If you buy it at release and afterwords the price rises you don't pay again. So if it appeals to you buy it when it comes out.

  • Posts: 418

    This is a really cool project. A Minecraft clone + custom scripting is a fantastic idea! I think it would be approachable for new coders and intriguing enough for the experienced.

    But the best user input method for this is, by far, keyboard and mouse. For moving around a first person world and for typing.

    Your not making to for PC/Mac though so maybe it can have support for a Bluetooth mouse + keyboard? Someday?

  • JohnJohn Admin Mod
    Posts: 622

    I've been working a lot on improving the flexibility of the Codea Craft rendering system along with extending API coverage in Codea.

    I've added model loading, configurable materials (lighting, textures, colors, etc...), 3D physics and a new mesh API. New examples are being added to Codea to show off and teach these features. I'll be posting some videos explaining them soon.

    Procedural planet with models loading from asset pack decorating the surface:

    Character from asset pack with custom skin

  • Posts: 2,020

    Excellent, keep the screenshots coming please! Looking forward to the beta too B)

  • Is the beta in january 2017? or have i missed it, i really want to be in a beta and will gladly pay up to $20 for it, plus spend some time righting feedback.....but be warned.......i just started codea and learning lua plus im 13. Great project!

Sign In or Register to comment.