This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Resources | |
// https://burakkanber.com/blog/physics-in-javascript-car-suspension-part-1-spring-mass-damper/ | |
// https://gafferongames.com/post/spring_physics/ | |
// https://gafferongames.com/post/physics_in_3d/ | |
// http://digitalopus.ca/site/pd-controllers/ | |
// .. Has things about Torque | |
class QuaterionSpring{ | |
constructor( damping=5, stiffness=30 ){ | |
this.velocity = new Float32Array(4); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
shader_type canvas_item; | |
uniform sampler2D spritesheet; // Should be a slice image as exported from Magica Voxel | |
uniform int slice_count = 1; // The number of slices | |
uniform vec2 camera_vec = vec2( 1., 1. ); // Recomend using (1,1) or (1,1.5) | |
uniform float camera_ang = 0.0; // change this to change the view angle of the object | |
const vec2 center = vec2( 0.5 ); | |
bool scale_and_rotate_with_offset( inout vec2 uv, vec2 sxy, float ang, vec2 cent, vec2 offset ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[gd_resource type="Theme" load_steps=12 format=3 uid="uid://7bvxnk5n5imx"] | |
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_6h42l"] | |
content_margin_left = 10.5 | |
content_margin_top = 8.75 | |
content_margin_right = 10.5 | |
content_margin_bottom = 8.75 | |
bg_color = Color(0.117647, 0.117647, 0.117647, 1) | |
draw_center = false | |
border_color = Color(1, 1, 1, 0.137255) |