[gd_scene load_steps=15 format=2] [ext_resource path="res://LevelComponents/Killfloor.tscn" type="PackedScene" id=1] [ext_resource path="res://LevelComponents/SpawnPoint.tscn" type="PackedScene" id=2] [ext_resource path="res://LevelComponents/LevelGeometry.gd" type="Script" id=3] [ext_resource path="res://Assets/Maps/Rotor/Rotor.gltf" type="PackedScene" id=4] [ext_resource path="res://Assets/Maps/Rotor/Crank.gd" type="Script" id=5] [ext_resource path="res://Assets/Maps/Decoration/unfa stroke.tscn" type="PackedScene" id=6] [sub_resource type="VisualShaderNodeTextureUniformTriplanar" id=1] output_port_for_preview = 0 uniform_name = "BaseTexture" texture_type = 1 [sub_resource type="VisualShaderNodeTextureUniformTriplanar" id=2] output_port_for_preview = 0 uniform_name = "BaseTextureNormal" texture_type = 2 [sub_resource type="VisualShaderNodeScalarUniform" id=3] uniform_name = "ScalarUniform" [sub_resource type="VisualShader" id=4] code = "shader_type spatial; render_mode specular_schlick_ggx, world_vertex_coords; uniform sampler2D BaseTexture : hint_albedo; uniform float ScalarUniform; uniform sampler2D BaseTextureNormal : hint_normal; // TRIPLANAR FUNCTION GLOBAL CODE vec4 triplanar_texture(sampler2D p_sampler, vec3 p_weights, vec3 p_triplanar_pos) { vec4 samp = vec4(0.0); samp += texture(p_sampler, p_triplanar_pos.xy) * p_weights.z; samp += texture(p_sampler, p_triplanar_pos.xz) * p_weights.y; samp += texture(p_sampler, p_triplanar_pos.zy * vec2(-1.0, 1.0)) * p_weights.x; return samp; } uniform vec3 triplanar_scale = vec3(1.0, 1.0, 1.0); uniform vec3 triplanar_offset; uniform float triplanar_sharpness = 0.5; varying vec3 triplanar_power_normal; varying vec3 triplanar_pos; void vertex() { // Output:0 // TRIPLANAR FUNCTION VERTEX CODE triplanar_power_normal = pow(abs(NORMAL), vec3(triplanar_sharpness)); triplanar_power_normal /= dot(triplanar_power_normal, vec3(1.0)); triplanar_pos = VERTEX * triplanar_scale + triplanar_offset; triplanar_pos *= vec3(1.0, -1.0, 1.0); } void fragment() { // TextureUniformTriplanar:3 vec3 n_out3p0; float n_out3p1; { vec4 n_tex_read = triplanar_texture( BaseTexture, triplanar_power_normal, triplanar_pos ); n_out3p0 = n_tex_read.rgb; n_out3p1 = n_tex_read.a; } // ScalarUniform:6 float n_out6p0 = ScalarUniform; // TextureUniformTriplanar:5 vec3 n_out5p0; float n_out5p1; { vec4 n_tex_read = triplanar_texture( BaseTextureNormal, triplanar_power_normal, triplanar_pos ); n_out5p0 = n_tex_read.rgb; n_out5p1 = n_tex_read.a; } // Output:0 ALBEDO = n_out3p0; ROUGHNESS = n_out6p0; NORMALMAP = n_out5p0; } void light() { // Output:0 } " graph_offset = Vector2( -531, 641.5 ) flags/world_vertex_coords = true nodes/fragment/0/position = Vector2( 220, 100 ) nodes/fragment/3/node = SubResource( 1 ) nodes/fragment/3/position = Vector2( -640, 20 ) nodes/fragment/5/node = SubResource( 2 ) nodes/fragment/5/position = Vector2( -280, 500 ) nodes/fragment/6/node = SubResource( 3 ) nodes/fragment/6/position = Vector2( -140, 200 ) nodes/fragment/connections = PoolIntArray( 3, 0, 0, 0, 5, 0, 0, 8, 6, 0, 0, 3 ) [sub_resource type="OpenSimplexNoise" id=5] octaves = 7 period = 256.0 persistence = 0.859 lacunarity = 4.0 [sub_resource type="NoiseTexture" id=6] seamless = true noise = SubResource( 5 ) [sub_resource type="NoiseTexture" id=7] seamless = true as_normalmap = true bump_strength = 4.0 noise = SubResource( 5 ) [sub_resource type="ShaderMaterial" id=8] shader = SubResource( 4 ) shader_param/ScalarUniform = 0.4 shader_param/triplanar_scale = Vector3( 0.1, 0.1, 0.1 ) shader_param/triplanar_offset = null shader_param/triplanar_sharpness = 0.5 shader_param/BaseTexture = SubResource( 6 ) shader_param/BaseTextureNormal = SubResource( 7 ) [node name="Level" type="Spatial"] [node name="Rotor" parent="." instance=ExtResource( 4 )] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -73.5341, -105.864, 0 ) [node name="Crank " parent="Rotor" index="2"] transform = Transform( 0.993238, 0, -0.116093, 0, 1, 0, 0.116093, 0, 0.993238, 0, -3.13982, 0 ) script = ExtResource( 5 ) [node name="Node" type="Node" parent="."] [node name="DirectionalLight" type="DirectionalLight" parent="Node"] transform = Transform( 0.41961, 0.641844, -0.641844, 0, 0.707107, 0.707107, 0.907704, -0.296709, 0.296709, 0, 24.5477, 7 ) shadow_enabled = true [node name="CSGCombiner" type="CSGCombiner" parent="."] material_override = SubResource( 8 ) use_collision = true script = ExtResource( 3 ) [node name="CSGBox" type="CSGBox" parent="CSGCombiner"] width = 14.0 depth = 14.0 [node name="CSGCylinder" type="CSGCylinder" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -4, 7, 4 ) radius = 3.0 height = 14.0 sides = 24 smooth_faces = false [node name="CSGBox2" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 3, 0 ) operation = 2 width = 12.0 height = 6.0 depth = 12.0 [node name="CSGCylinder2" type="CSGCylinder" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -4, 7.78163, 4 ) operation = 2 radius = 2.0 height = 14.1775 sides = 24 smooth_faces = false [node name="CSGBox6" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 13.8736, 8, -5.0366 ) width = 14.0 depth = 14.0 [node name="CSGBox4" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 4, -12 ) width = 14.0 depth = 14.0 [node name="CSGBox15" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 8.59864, 4, -25.8491 ) width = 40.5262 depth = 14.0 [node name="CSGBox16" type="CSGBox" parent="CSGCombiner"] transform = Transform( -4.37114e-08, 0, -1, 0, 1, 0, 1, 0, -4.37114e-08, 27.8614, 4, -6.45679 ) width = 52.6566 depth = 14.0 [node name="CSGBox17" type="CSGBox" parent="CSGCombiner"] transform = Transform( -1, 0, 8.74228e-08, 0, 1, 0, -8.74228e-08, 0, -1, 10.2837, 1.77627, 13.1345 ) width = 23.4838 height = 6.22713 depth = 12.7782 [node name="CSGBox18" type="CSGBox" parent="CSGCombiner"] transform = Transform( -1, 0, 8.74228e-08, 0, 1, 0, -8.74228e-08, 0, -1, 2.45777, 1.77627, 6.76296 ) operation = 2 width = 8.97262 height = 0.652383 depth = 2.03151 [node name="CSGBox19" type="CSGBox" parent="CSGCombiner"] transform = Transform( -1, 0, 8.74228e-08, 0, 1, 0, -8.74228e-08, 0, -1, 2.45777, 2.36537, 7.73524 ) operation = 2 width = 8.97262 height = 0.652383 depth = 2.03151 [node name="CSGBox20" type="CSGBox" parent="CSGCombiner"] transform = Transform( -1, 0, 8.74228e-08, 0, 1, 0, -8.74228e-08, 0, -1, 2.45777, 2.94159, 7.73524 ) operation = 2 width = 8.97262 height = 0.652383 depth = 5.4952 [node name="CSGBox21" type="CSGBox" parent="CSGCombiner"] transform = Transform( -1, 0, 8.74228e-08, 0, 1, 0, -8.74228e-08, 0, -1, 2.45777, 3.55982, 9.34489 ) operation = 2 width = 8.97262 height = 0.652383 depth = 5.4952 [node name="CSGBox22" type="CSGBox" parent="CSGCombiner"] transform = Transform( -1, 0, 8.74228e-08, 0, 1, 0, -8.74228e-08, 0, -1, 2.45777, 4.18278, 9.34489 ) operation = 2 width = 8.97262 height = 0.652383 depth = 8.21342 [node name="CSGBox23" type="CSGBox" parent="CSGCombiner"] transform = Transform( -1, 0, 8.74228e-08, 0, 1, 0, -8.74228e-08, 0, -1, 2.45777, 4.67019, 10.3097 ) operation = 2 width = 8.97262 height = 0.652383 depth = 8.9872 [node name="CSGBox3" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 5, -12 ) operation = 2 width = 12.0 depth = 12.0 [node name="CSGBox8" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 10, 12, 13 ) width = 14.0 depth = 14.0 [node name="CSGBox7" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 10, 13, 13 ) operation = 2 width = 12.0 depth = 12.0 [node name="CSGCylinder3" type="CSGCylinder" parent="CSGCombiner"] transform = Transform( -1, 0, 8.74228e-08, 0, 1, 0, -8.74228e-08, 0, -1, 9.68932, 11.1741, 15.8729 ) operation = 2 height = 2.26886 sides = 16 smooth_faces = false [node name="CSGBox5" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 14, 9, -5 ) operation = 2 width = 12.0 depth = 12.0 [node name="CSGBox9" type="CSGBox" parent="CSGCombiner"] transform = Transform( 0.965926, -0.258819, 0, 0.258819, 0.965926, 0, 0, 0, 1, 16.4633, 6.96057, -13.835 ) width = 19.8983 height = 1.04801 depth = 3.06491 [node name="CSGBox13" type="CSGBox" parent="CSGCombiner"] transform = Transform( 0.965926, -0.258819, 0, 0.258819, 0.965926, 0, 0, 0, 1, 16.4633, 8.8368, -15.389 ) width = 19.8983 height = 3.0157 depth = 0.482565 [node name="CSGBox10" type="CSGBox" parent="CSGCombiner"] transform = Transform( -4.2222e-08, 1.13133e-08, 1, 0.258819, 0.965926, 0, -0.965926, 0.258819, -4.37114e-08, -8.61319, 2.55869, -9.30531 ) width = 19.8983 height = 1.04801 depth = 3.06491 [node name="CSGBox12" type="CSGBox" parent="CSGCombiner"] transform = Transform( -4.2222e-08, 1.13133e-08, 1, 0.258819, 0.965926, 0, -0.965926, 0.258819, -4.37114e-08, -10.0518, 4.14058, -9.30531 ) width = 19.8983 height = 2.8803 depth = 0.413662 [node name="CSGBox11" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1.3411e-07, -2.98023e-08, -1, 0.258819, 0.965926, 0, 0.965926, -0.258819, 1.19209e-07, 19.4633, 11.0535, 10.8751 ) width = 19.8983 height = 1.04801 depth = 3.06491 [node name="CSGBox14" type="CSGBox" parent="CSGCombiner"] transform = Transform( 1.3411e-07, -2.98023e-08, -1, 0.258819, 0.965926, 0, 0.965926, -0.258819, 1.19209e-07, 20.9571, 12.0994, 10.8751 ) width = 19.8983 height = 2.38673 depth = 0.262265 [node name="Killfloor" parent="." instance=ExtResource( 1 )] transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 89.7533, -4.36458, 0 ) monitoring = false [node name="unfa stroke" parent="." instance=ExtResource( 6 )] transform = Transform( 1.96589, 0, 0, 0, 1.96589, 0, 0, 0, 1.00018, 0.00612259, 3.93148, -4.98933 ) [node name="SpawnPoint" parent="." instance=ExtResource( 2 )] [editable path="Rotor"]