Codea Craft 2.5 (90)

@John Which one of my issues are you referring to, the missing lines, the selected lines, or the Voxel asset not showing.

@Simeon braces with == signs are not changing the color of code inbetween them, and getmetatable is not yellow

@xThomas I kinda like the -[==[...]==]-- braces bug. It allows you to edit code that is commented out with proper indentation and syntax highlighting.
The yellow color [syntax highlighting] on getmetatable is a bug, which I also described a few posts above.

@dave1707 from my inference, @John is referring to the Voxel Assets issue.

More bugs:

  • Try this: open a file long enough so that you can scroll in it. Open the search field to find something. While scrolling the text, tap on a match in the sidebar. Continued tapping will scroll in increments but never to the matched text.
  • Very small pixel sprites (9x11) do not show up in the asset preview panel. Maybe they should be resized up so that they can be seen. Otherwise they are practically invisible

If you don’t understand, I’ll try to post GIFs of what I mean.

@em2 thanks so much for the continued reports. It’s appreciated

Question: is split-screen support planned?
@Simeon I’m glad to help, especially so that you can have these issues fixed soon. Codea is such a great product and little nuances can really irritate.

@Simeon , @John,

Now managed to resolve problems with most of my .obj files. Some trivial like .png file for texture spelling error - in that case shows untextured model. Blender models work consistently. Errors given on some files in the print output window. Most failures down to a utility for conversion of .dat files to .obj files. Must be a formatting error in the data - there does seem to be a number of different formats for the .obj file - have you covered them all in your loader?

Here’s a bug:
Importing projects crashes the app.

More suggestions

  • readImage on retina devices should have a “force” option or something similar to disable @2x files.
  • A great addition to the close and physics.pause functions would be pause and restart functions.

@em2 I have a development branch with split screen support. It’s basically a rewrite of every major part. It’s getting there!

I’m also getting the bitset to u_long on an iPad4 (not air).

Could the beta be updated to version 90? It’s currently on 88 and the App Store won’t let me install the published version over the top and I don’t want to risk uninstalling - too many projects going back many, many years! (Yes, I know I can export and reimport but I worry about stuff like shaders with that.)

@LoopSpace To load the latest non beta version, you first have to go to purchases and load the old version of Codea over the beta version. Then you can load the updated version from the update screen over the latest non beta version.

@Simeon excited about that!

@LoopSpace backing up your device to iTunes will preserve all your data. I checked the iTunes backup file system to verify. Backup browsers can extract the files individually.

@dave1707 That’s what I tried. I’ll try again. @em2 I know that there are ways and means … but I have a lot of code invested in Codea and I’m being cautious.

@Simeon Can the metatables for quat and craft.model be made mutable (just like vec4 and so on are)? I’ve built up a variety of shapes with meshes which I’d like to convert to models and I’d like to be able to call them as, say, craft.model.pyramid(). Similarly, my quaternion library contains a bit more than yours so I’d like to add my extras but retain using the underlying quat structure.

I’m also trying to understand the difference between the old mesh and the new model. The new model separates the roles of the vertices and the triangles (does this significantly improve performance?) but are there any other differences? I did try assigning a mesh as a model to test!

Sweet Jeebus but that there Craft is nice. My wife has an iPad Pro, and I snuck Codea on it to take a look. That is some great stuff. Can’t wait till I can play with it.

@LoopSpace in the settings panel there is an “Export All Projects” button that will give you a zip archive of everything. We’re working on a fix for 32 bit devices. Sorry about that

@Simeon does it do shaders as well?

More on the quats: it doesn’t seem possible to set a quat via: quat(.5,.5,.5,.5) (note that this is a valid rotation quaternion) as it complains about ints. Rather, I have to do q = quat() and then set each of q.x etc individually.

Any thoughts on the metatables?

Hi everyone

I’ve found the source of the to_ulong() overflow error. This was due to 32 bit long integers being too small on 32 bit devices causing an overflow. I think i’ve fixed this and will be putting out a build soon.

@LoopSpace
You should be able to add new functions (i.e. craft.model.staticFunction(), craft.model:method()) to a class by doing the following:

local modelMeta = getmetatable(craft.model)
rawset(modelMeta, "myStaticFunction", function() ` end)
rawset(modelMeta.___class, "myClassMethod", function(self) ` end)

I’ve also fixed the issue with the quat class, which was incorrectly expecting ints in the constructor. Now it should work with float and anything not supplied is 0 by default.

Codea Craft AR: Clicking Shelf returns error