Marc Flerackers
Marc Flerackers
Additionally, you don't want to divide each time, it is better to store 1 / factor and multiply instead.
Yeah, when stretch is used, you no longer have a uniform scale. You need a vec2 in that case.
This is because it is a voxel raycaster, it traces rays along the voxels of the level (the grid) and looks only at grid tiles which are hit. This example...
I think returning a fresh type on use is acceptable, it's impossible in any typed language to mutate the type of an existing reference.
Wouldn't it be better to add a decent transition API for scenes?
Why not a function? So you can return a displacement each frame.
return null to make it stop?
Animate does not use the current color, position, angle or any other property. You need to pass several keyframes to animate and it will interpolate between them. So correct would...
https://play.kaplayjs.com/?code=eJyNkMFqwzAMhu95CuFdHDCuty5QWlooW6Hn7Vh6ELY8Qh07OOm6Mfbuc5x0hZ0mDJY%2BydIvz2bw2mPsO0DwdIE3bKg4Yevwk5eronDUg4Y1oDH8UEAyXUftiFeqFDluQ8cflBIwV1ekgwuRs7tqTmgNmyj6usGe%2BDWMhIN%2FHMZoGfw%2BvFPkvIT1Br7GPvLsp1db5wY9Ix1ZHbzsiE5c%2FUkQZ1kBE3DQMrsCnoZL2hiaPX0kbfYRF9ay8iimYYOZc8x9l6BkJX6xC6HtlnB%2FI6aOpMdKZkO8YDQsJ7%2FLIp3bPjtv%2FrVSVpn%2BeZT5sntepT4%2FZRlwmg%3D%3D&version=master
The animate component has an internal clock which starts the moment it is added to an object. So by the time you animate a property for 0.5ms, the internal clock...