For sprite objects with the plane behavior you need to add a spritesheet in your project folder.
If you know you do not need animations use a tiled background object instead which does not require this step.
The only behavior that can obey to runtime changes in dimensions is Plane (Resize property). However it does this by disposing and creating the mesh anew which is not a particularly elegant solution.
Now all mesh behaviors should be able to follow changes in dimensions by scaling. Will very likely be included in the next update.
If you need to do this currently you'll have to scale yourself via events.
You're supposed to add B3D Model objects for different model files. That's how it's designed to work.
If you were trying to do something like a model viewer or level editor (did you mean that by "customize the level"?) this would indeed become a problem. Something like the "Override" action of the box behavior could remedy this.
Again though for a regular game it's not necessary. I'll see about bringing "Override" to other behaviors/plugins.
Since the plugin uses its own canvas blend modes or effects used on Construct 2 layers won't take effect.
Sadly there isn't really a workaround for this other than making the plugin render to a texture instead that then would be it's own C2 plugin to be placed on a layer - I believe this is what the Q3D plugin did for example.
I have mentioned in other places that this was also my initial plan which I failed at and fell back on the straightforward additional canvas solution. I also said I may be revisiting this at a later date.
Be aware though such a change wouldn't be trivial and require reworking any projects you may already have too. It's not a can of worms I plan to open any time before 1.0 to be honest.
I'm sorry if this makes things difficult for your project.
Please give me the link to this model if you can (is it a free asset?) so I can test it out for myself.
If a complex model gets saved again with different options the output of Babylon.js might become weird, I will say that much... but I would require an example model that demonstrated a general problem.
But that's what I want to know. You're having a specific issue?
May I refer you to this topic: https://itch.io/t/5595165/how-does-the-skybox-work
Sure it just needs to be a doublesided mesh in Babylon.js/ have no backface culling.
Are you talking about using the "Add sphere" action here? Because that one has been there a long time just for testing and doesn't really provide anything in the way of manipulating the sphere beyond positioning.
So yes what you're asking is perfectly possible but unless you're using an imported sphere model that's properly set up in the way you suggest you will not have much luck with the things the plugin provides directly.
Maybe that should change.
There's two places you need to take a look at in that example.
First the property "Multi-face" needs to be set to "Yes" to get a unique image on each side of the box.
Then open the tiled background image of the box in Construct 2 and you will see that it's a strip of six 16x16 images making a 96x16 texture.
The first 16x16 is the left side, second right side, then front, back, top and down. You have to think of the front face looking in direction of the angle the box is facing.
Let me know if this helps you. Happy easter!
I have already checked it out and made the necessary alterations.
Since it was saved with my current unreleased version of the plugin it has the potential to give you errors when opening. So I would want to hold off until the next update releases which will be later this week.
If you absolutely cannot wait here it is, but you've been warned: https://www.dropbox.com/scl/fi/ml2kqs716uotxqtrp8o06/forJDev.capx?rlkey=ildk4l8b...
I still left a little challenge in there for you. While jumping is implemented there are no checks for hitting something above you, so you will currently get pushed out when doing that. Once you understand the events you should be able to add that functionality yourself. Cheers!
There are actually quite a few issues with texture management I have to admit, so you are correct to question this.
While materials should already be disposed of properly in most circumstances, I was ignorant so far to the texture situation itself.
Improvements are planned for an upcoming update where materials automatically get rid of their textures. But this will unfortunately not address "Set mesh texture".
Proper texture management in the future (before 1.0) will have the aim to dispose of any texture in memory that is not currently used by any object and also probably provide shared textures for non-instanced objects.
Speaking more generally I don't know if it's the best approach to load/dispose the texture every time for a supposed LOD change. What kind of objects/behaviors are you trying to apply a level of detail system to like this? And are you using large textures?
Basically you just add a jump value to the player Z position which you decrease every tick by some gravity value. Then increase the gravity by some factor once you're falling again (for a better less floaty feel).
Of course you need to implement checks to see if the player is on ground. This has to be your own event logic. Check for overlaps and compare Z top positions of your geometry to the player bottom position (feet if you will) and also player top for colliding above when jumping - alternatively you could also use ray picking for this which will probably run faster but might introduce some other difficulties.
In general using some kind of state machine (via the plugin of the same name is pretty handy) helps in such endeavors.
If you want to I can still take a look at your capx file, sure.
Here's the most minimal example of showing a model: https://drive.google.com/file/d/11-Wg3IkP4sJ06jPNEezIQ4tLTNtil12D/view?usp=shari...
Error "0" doesn't seem right do you have a screenshot of this (with console) or maybe even an example file?
So I went ahead and made this slightly trippy white void version of a basic third person camera and controls.
https://drive.google.com/file/d/1R-o6JJ-MscUvzhFbKllTcb9AjJB8Idex/view?usp=shari...
Check it out it should answer most of your questions when you study it (it's only 13 events).
WASD moves the character box, mouse moves the camera around it. Mouse wheel up/down zooms in/out.
Oh yeah this example requires the Simple Mouselock plugin.
For a third person view like this you should create a camera that is at a certain radius from the character while always looking at it and offset in elevation (Z) to look from above basically.
Something similar is shown in the 8 direction billboard example where the camera rotates around the billboard character in the center.
Now when you simply slap 8 direction movement on your character you will get probably undesired results since the character is not moving relative to the perspective (regular third person movement) or depending on where the character is facing (tank controls).
For first person controls (which does not apply here) and tank controls I'm actually using an edited version of the 8 direction behavior called wasd movement which is adjusted to move its object relative to its angle and defaults to w,a,s and d instead arrow keys. Maybe I should share this at some point.
For regular third person movement, which I haven't actually used myself in anything I've created with Baby 3D yet, you should apply vectorX and vectorY of the 8 direction movement behavior relative to the camera angle. Unless I'm totally thinking of something stupid and wrong right now...
If this doesn't help enough I guess I can cook up an actual example in the next few days
You can set the sampling mode to NEAREST, BILINEAR and TRILINEAR via property for the Plane behavior. I just noticed you can't yet for Box/Cylinder (defaults to NEAREST atm) so it will be added in the next update.
If you want a really blurry look for some reason (N64 chique?) you can also try using FXAA.
Here is your edited capx: https://www.dropbox.com/scl/fi/lwujjl1kgp83pk6nucwet/horrorEdit.capx?rlkey=45rt5...
I basically just removed the camera behavior, added a camera via the main plugin and set its position and angle every tick like the behavior would've done automatically. Comments are at the two relevant spots in the event sheet.
Hey, I haven't looked at the capx yet but the issue last time was the use of camera behaviors instead of cameras created by the main plugin.
The behavior camera is bound to a layout object and therefore destroyed on layout change/restart which can lead to unintended glitches and errors. Therefore I have to strongly recommend for most cases adding cameras via the main plugin.
Hello there!
For the model plugin to work you have to first import the model file (glb/gltf or obj) you want to use into your project's files folder.
Then in the model object's properties you set 'File name' to the name of the file you just imported. Now the model should actually show up in your scene when you run it.
Let me know if you need further assistance. There probably should be an example file for this in the future.
Just to be clear: you want to get the yaw, pitch and roll of a hit face? What's the use case if I may ask?
Afaik you could use a bit of math and get yaw and pitch of the face from the normalized normal. However the normal from the ray hit is being used internally, it's not exposed via expressions or anything currently.
Maybe such expressions could be useful.
Hey!
Since the latest update your imported model can be completely excluded from picking by setting the property "Pickable" to false;
But you're right to assume that an imported model with different meshes can currently not be altered separately.
I just noticed a related issue with picking against imported models. For submeshes it will actually return NaN and therefore won't be really useable. It's clearly something to think about for the next little maintenance update.
With the addition of a general mesh visibility action your suggestion would become fully feasible.