initial commit
This commit is contained in:
commit
dc2e10db3a
18 files changed
+328
No files matched your search
@@ -0,0 +1,2 @@
|
|||||||
|
# Normalize EOL for all files that Git considers text files.
|
||||||
|
* text=auto eol=lf
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
# Godot 4+ specific ignores
|
||||||
|
.godot/
|
||||||
BIN
Binary file not shown.
@@ -0,0 +1,19 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="mp3"
|
||||||
|
type="AudioStreamMP3"
|
||||||
|
uid="uid://mbkqoqmf0go7"
|
||||||
|
path="res://.godot/imported/Galaxy.mp3-73ed80155d141d7556f1bab482b335a9.mp3str"
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://Galaxy.mp3"
|
||||||
|
dest_files=["res://.godot/imported/Galaxy.mp3-73ed80155d141d7556f1bab482b335a9.mp3str"]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
loop=false
|
||||||
|
loop_offset=0
|
||||||
|
bpm=0
|
||||||
|
beat_count=0
|
||||||
|
bar_beats=4
|
||||||
BIN
Binary file not shown.
|
After Width: | Height: | Size: 7.4 MiB |
@@ -0,0 +1,35 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="texture"
|
||||||
|
type="CompressedTexture2D"
|
||||||
|
uid="uid://yjay8cqle8yi"
|
||||||
|
path.s3tc="res://.godot/imported/aurora.png-524a642accc848cd0098eaf7446f02e5.s3tc.ctex"
|
||||||
|
metadata={
|
||||||
|
"imported_formats": ["s3tc_bptc"],
|
||||||
|
"vram_texture": true
|
||||||
|
}
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://aurora.png"
|
||||||
|
dest_files=["res://.godot/imported/aurora.png-524a642accc848cd0098eaf7446f02e5.s3tc.ctex"]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
compress/mode=2
|
||||||
|
compress/high_quality=false
|
||||||
|
compress/lossy_quality=0.7
|
||||||
|
compress/hdr_compression=1
|
||||||
|
compress/normal_map=0
|
||||||
|
compress/channel_pack=0
|
||||||
|
mipmaps/generate=true
|
||||||
|
mipmaps/limit=-1
|
||||||
|
roughness/mode=0
|
||||||
|
roughness/src_normal=""
|
||||||
|
process/fix_alpha_border=true
|
||||||
|
process/premult_alpha=false
|
||||||
|
process/normal_map_invert_y=false
|
||||||
|
process/hdr_as_srgb=false
|
||||||
|
process/hdr_clamp_exposure=false
|
||||||
|
process/size_limit=0
|
||||||
|
detect_3d/compress_to=0
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
extends CharacterBody3D
|
||||||
|
|
||||||
|
|
||||||
|
const SPEED = 5.0
|
||||||
|
const JUMP_VELOCITY = 4.5
|
||||||
|
const WALK_SPEED = 2.0
|
||||||
|
const MOUSE_SENS = 0.002
|
||||||
|
|
||||||
|
# Get the gravity from the project settings to be synced with RigidBody nodes.
|
||||||
|
var gravity = ProjectSettings.get_setting("physics/3d/default_gravity")
|
||||||
|
|
||||||
|
func _ready():
|
||||||
|
Input.set_mouse_mode(2)
|
||||||
|
|
||||||
|
func _input(event):
|
||||||
|
if event is InputEventMouseMotion:
|
||||||
|
$Pivot.rotate_y(-event.relative.x*MOUSE_SENS)
|
||||||
|
$Pivot/Camera.rotate_x(-event.relative.y*MOUSE_SENS)
|
||||||
|
|
||||||
|
func _physics_process(delta):
|
||||||
|
# Add the gravity.
|
||||||
|
if not is_on_floor():
|
||||||
|
velocity.y -= gravity * delta
|
||||||
|
|
||||||
|
# Handle jump.
|
||||||
|
if Input.is_action_just_pressed("ui_accept") and is_on_floor():
|
||||||
|
velocity.y = JUMP_VELOCITY
|
||||||
|
|
||||||
|
# Get the input direction and handle the movement/deceleration.
|
||||||
|
# As good practice, you should replace UI actions with custom gameplay actions.
|
||||||
|
var input_dir = Input.get_vector("ui_left", "ui_right", "ui_up", "ui_down")
|
||||||
|
var direction = (transform.basis * Vector3(input_dir.x, 0, input_dir.y)).normalized()
|
||||||
|
if direction:
|
||||||
|
velocity.x = direction.x * SPEED
|
||||||
|
velocity.z = direction.z * SPEED
|
||||||
|
else:
|
||||||
|
velocity.x = move_toward(velocity.x, 0, SPEED)
|
||||||
|
velocity.z = move_toward(velocity.z, 0, SPEED)
|
||||||
|
|
||||||
|
move_and_slide()
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
[gd_scene load_steps=3 format=3 uid="uid://d4fal6apyqrlf"]
|
||||||
|
|
||||||
|
[ext_resource type="Script" path="res://character_body_3d.gd" id="1_gy10k"]
|
||||||
|
|
||||||
|
[sub_resource type="SphereShape3D" id="SphereShape3D_gkp0s"]
|
||||||
|
|
||||||
|
[node name="CharacterBody3D" type="CharacterBody3D"]
|
||||||
|
script = ExtResource("1_gy10k")
|
||||||
|
|
||||||
|
[node name="Pivot" type="Node3D" parent="."]
|
||||||
|
|
||||||
|
[node name="Camera" type="Camera3D" parent="Pivot"]
|
||||||
|
|
||||||
|
[node name="CollisionShape3D" type="CollisionShape3D" parent="."]
|
||||||
|
shape = SubResource("SphereShape3D_gkp0s")
|
||||||
BIN
Binary file not shown.
|
After Width: | Height: | Size: 39 MiB |
@@ -0,0 +1,35 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="texture"
|
||||||
|
type="CompressedTexture2D"
|
||||||
|
uid="uid://cjr3yq45rbob0"
|
||||||
|
path.s3tc="res://.godot/imported/galaxy.png-826bf465bd9a246a30eb75141ad1440f.s3tc.ctex"
|
||||||
|
metadata={
|
||||||
|
"imported_formats": ["s3tc_bptc"],
|
||||||
|
"vram_texture": true
|
||||||
|
}
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://galaxy.png"
|
||||||
|
dest_files=["res://.godot/imported/galaxy.png-826bf465bd9a246a30eb75141ad1440f.s3tc.ctex"]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
compress/mode=2
|
||||||
|
compress/high_quality=false
|
||||||
|
compress/lossy_quality=0.7
|
||||||
|
compress/hdr_compression=1
|
||||||
|
compress/normal_map=0
|
||||||
|
compress/channel_pack=0
|
||||||
|
mipmaps/generate=true
|
||||||
|
mipmaps/limit=-1
|
||||||
|
roughness/mode=0
|
||||||
|
roughness/src_normal=""
|
||||||
|
process/fix_alpha_border=true
|
||||||
|
process/premult_alpha=false
|
||||||
|
process/normal_map_invert_y=false
|
||||||
|
process/hdr_as_srgb=false
|
||||||
|
process/hdr_clamp_exposure=false
|
||||||
|
process/size_limit=0
|
||||||
|
detect_3d/compress_to=0
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
<svg height="128" width="128" xmlns="http://www.w3.org/2000/svg"><rect x="2" y="2" width="124" height="124" rx="14" fill="#363d52" stroke="#212532" stroke-width="4"/><g transform="scale(.101) translate(122 122)"><g fill="#fff"><path d="M105 673v33q407 354 814 0v-33z"/><path d="m105 673 152 14q12 1 15 14l4 67 132 10 8-61q2-11 15-15h162q13 4 15 15l8 61 132-10 4-67q3-13 15-14l152-14V427q30-39 56-81-35-59-83-108-43 20-82 47-40-37-88-64 7-51 8-102-59-28-123-42-26 43-46 89-49-7-98 0-20-46-46-89-64 14-123 42 1 51 8 102-48 27-88 64-39-27-82-47-48 49-83 108 26 42 56 81zm0 33v39c0 276 813 276 814 0v-39l-134 12-5 69q-2 10-14 13l-162 11q-12 0-16-11l-10-65H446l-10 65q-4 11-16 11l-162-11q-12-3-14-13l-5-69z" fill="#478cbf"/><path d="M483 600c0 34 58 34 58 0v-86c0-34-58-34-58 0z"/><circle cx="725" cy="526" r="90"/><circle cx="299" cy="526" r="90"/></g><g fill="#414042"><circle cx="307" cy="532" r="60"/><circle cx="717" cy="532" r="60"/></g></g></svg>
|
||||||
|
After Width: | Height: | Size: 949 B |
@@ -0,0 +1,37 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="texture"
|
||||||
|
type="CompressedTexture2D"
|
||||||
|
uid="uid://c1v7dh35tub0l"
|
||||||
|
path="res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"
|
||||||
|
metadata={
|
||||||
|
"vram_texture": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://icon.svg"
|
||||||
|
dest_files=["res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
|
compress/lossy_quality=0.7
|
||||||
|
compress/hdr_compression=1
|
||||||
|
compress/normal_map=0
|
||||||
|
compress/channel_pack=0
|
||||||
|
mipmaps/generate=false
|
||||||
|
mipmaps/limit=-1
|
||||||
|
roughness/mode=0
|
||||||
|
roughness/src_normal=""
|
||||||
|
process/fix_alpha_border=true
|
||||||
|
process/premult_alpha=false
|
||||||
|
process/normal_map_invert_y=false
|
||||||
|
process/hdr_as_srgb=false
|
||||||
|
process/hdr_clamp_exposure=false
|
||||||
|
process/size_limit=0
|
||||||
|
detect_3d/compress_to=1
|
||||||
|
svg/scale=1.0
|
||||||
|
editor/scale_with_editor_scale=false
|
||||||
|
editor/convert_colors_with_editor_theme=false
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
[gd_scene load_steps=8 format=3 uid="uid://b6pci344cb2hb"]
|
||||||
|
|
||||||
|
[ext_resource type="Material" uid="uid://51srw6jbogv2" path="res://sky.tres" id="1_xmp2j"]
|
||||||
|
[ext_resource type="PackedScene" uid="uid://d4fal6apyqrlf" path="res://character_body_3d.tscn" id="2_wemtx"]
|
||||||
|
|
||||||
|
[sub_resource type="Sky" id="Sky_nb8j0"]
|
||||||
|
sky_material = ExtResource("1_xmp2j")
|
||||||
|
|
||||||
|
[sub_resource type="Environment" id="Environment_w4a4u"]
|
||||||
|
background_mode = 2
|
||||||
|
sky = SubResource("Sky_nb8j0")
|
||||||
|
|
||||||
|
[sub_resource type="BoxMesh" id="BoxMesh_klvfh"]
|
||||||
|
|
||||||
|
[sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_ckv2w"]
|
||||||
|
data = PackedVector3Array(-0.5, 0.5, 0.5, 0.5, 0.5, 0.5, -0.5, -0.5, 0.5, 0.5, 0.5, 0.5, 0.5, -0.5, 0.5, -0.5, -0.5, 0.5, 0.5, 0.5, -0.5, -0.5, 0.5, -0.5, 0.5, -0.5, -0.5, -0.5, 0.5, -0.5, -0.5, -0.5, -0.5, 0.5, -0.5, -0.5, 0.5, 0.5, 0.5, 0.5, 0.5, -0.5, 0.5, -0.5, 0.5, 0.5, 0.5, -0.5, 0.5, -0.5, -0.5, 0.5, -0.5, 0.5, -0.5, 0.5, -0.5, -0.5, 0.5, 0.5, -0.5, -0.5, -0.5, -0.5, 0.5, 0.5, -0.5, -0.5, 0.5, -0.5, -0.5, -0.5, 0.5, 0.5, 0.5, -0.5, 0.5, 0.5, 0.5, 0.5, -0.5, -0.5, 0.5, 0.5, -0.5, 0.5, -0.5, 0.5, 0.5, -0.5, -0.5, -0.5, 0.5, 0.5, -0.5, 0.5, -0.5, -0.5, -0.5, 0.5, -0.5, 0.5, 0.5, -0.5, -0.5, -0.5, -0.5, -0.5)
|
||||||
|
|
||||||
|
[sub_resource type="AudioStreamMP3" id="AudioStreamMP3_kr6wb"]
|
||||||
|
data = PackedByteArray(73, 68, 51, 4, 0, 0, 0, 0, 0, 113, 84, 66, 80, 77, 0, 0, 0, 6, 0, 0, 3, 56, 48, 46, 48, 0, 84, 88, 88, 88, 0, 0, 0, 11, 0, 0, 3, 73, 66, 80, 77, 0, 56, 48, 46, 48, 0, 84, 88, 88, 88, 0, 0, 0, 12, 0, 0, 3, 116, 101, 109, 112, 111, 0, 56, 48, 46, 48, 0, 84, 88, 88, 88, 0, 0, 0, 10, 0, 0, 3, 98, 112, 109, 0, 56, 48, 46, 48, 0, 84, 83, 83, 69, 0, 0, 0, 14, 0, 0, 3, 76, 97, 118, 102, 54, 48, 46, 51, 46, 49, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 251, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 88, 105, 110, 103, 0, 0, 0, 15, 0, 0, 78, 33, 0, 157, 172, 16, 0, 1, 3, 5, 7, 9, 12, 14, 17, 20, 22, 25, 27, 30, 32, 35, 37, 40, 43, 45, 48, 50, 53, 55, 58, 61, 64, 66, 69, 71, 74, 76, 79, 81, 84, 87, 89, 92, 94, 97, 100, 102, 105, 108, 110, 113, 116, 118, 121, 123, 127, 129, 132, 134, 137, 139, 142, 144, 147, 150, 153, 155, 158, 160, 163, 165, 168, 171, 174, 176, 179, 181, 184, 186, 189, 192, 195, 197, 200, 203, 205, 208, 210, 213, 216, 219, 221, 224, 226, 229, 231, 234, 237, 239, 242, 244, 247, 249, 251, 253, 0, 0, 0, 0, 76, 97, 118, 99, 54, 48, 46, 51, 46, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 36, 2, 64, 0, 0, 0, 0, 0, 157, 172, 16, 27, 233, 165, 111, 255, 251, 164, 68, 0, 15, 240, 0, 0, 127, 128, 0, 0, 8, 0, 0, 15, 240, 0, 0, 1, 0, 48, 5, 12, 1, 0, 0, 32, 6, 0, 161, 128, 32, 0, 4, 0, 96, 6, 6, 29, 156, 160, 227, 24, 46, 7, 36, 0, 192, 241, 42, 76, 65, 77, 69, 51, 46, 49, 48, 48, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 38, 51, 138, 84, 17, 105, 150, 184, 230, 6, 85, 177, 201, 1, 136, 211, 88, 133, 76, 65, 77, 69, 51, 46, 49, 48, 48, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 132, 0, 0, 0, 21, 52, 169, 235, 128, 0, 0, 169, 165, 77, 164, 5, 87, 60, 34, 243, 194, 0, 135, 50, 34, 7, 76, 65, 77, 69, 51, 46, 49, 48, 48, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 132, 0, 0, 0, 27, 151, 78, 153, 219, 192, 0, 1, 154, 22, 68, 129, 36, 3, 14, 222, 129, 49, 179, 200, 84, 136, 187, 32, 149, 76, 65, 77, 69, 51, 46, 49, 48, 48, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 22, 140, 184, 105, 23, 0, 0, 1, 69, 154, 1, 44, 43, 0, 73, 45, 61, 68, 128, 9, 37, 49, 144, 168, 58, 21, 76, 65, 77, 69, 51, 46, 49, 48, 48, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 96, 0, 1, 2, 223, 179, 40, 17, 128, 0, 0, 16, 14, 46, 124, 68, 18, 96, 0, 146, 152, 41, 25, 9, 0, 5, 170, 161, 99, 52, 76, 65, 77, 69, 51, 46, 49, 48, 48, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 224, 0, 0, 0, 55, 101, 72, 0, 246, 161, 144, 0, 0, 0, 227, 85, 152, 184, 192, 117, 69, 192, 6, 146, 128, 114, 73, 137, 0, 51, 146, 172, 1, 198, 116, 85, 76, 65, 77, 69, 51, 46, 49, 48, 48, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 36, 0, 0, 0, 1, 58, 50, 2, 166, 13, 60, 0, 0, 0, 27, 69, 41, 22, 1, 1, 42, 2, 197, 117, 192, 155, 40, 49, 17, 0, 24, 183, 93, 78, 55, 195, 178, 21, 76, 65, 77, 69, 51, 46, 49, 48, 48, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 17, 144, 0, 0, 4, 98, 240, 238, 96, 217, 42, 255, 251, 20, 68, 220, 143, 240, 28, 1, 65, 1, 224, 0, 8, 2, 96, 24, 64, 60, 0, 1, 64, 108, 3, 12, 7, 128, 0, 32, 11, 128, 224, 192, 240, 128, 4, 0, 0, 1, 82, 82, 160, 200, 4, 9, 40, 171, 192, 29, 191, 129, 104, 35, 208, 37, 96, 3, 91, 14, 11, 0, 216, 40, 144, 197, 76, 65, 77, 69, 51, 46, 49, 48, 48, 85, 85, 85, 85, 85, 85, 85, 17, 16, 0, 0, 0, 80, 128, 72, 113, 202, 98, 128, 0, 0, 116, 255, 251, 20, 68, 234, 143, 240, 33, 1, 193, 131, 1, 0, 8, 4, 192, 88, 16, 96, 65, 1, 0, 136, 7, 10, 7, 132, 0, 32, 18, 0, 160, 193, 0, 0, 5, 101, 64, 244, 16, 88, 237, 54, 34, 7, 228, 165, 161, 36, 4, 106, 191, 255, 145, 17, 20, 7, 180, 203, 75, 144, 255, 16, 236, 170, 76, 65, 77, 69, 51, 46, 49, 48, 48, 170, 170, 170, 170, 170, 170, 170, 40, 0, 0, 0, 2, 10, 216, 245, 147, 2, 17, 176, 0, 0, 1, 255, 251, 20, 68, 238, 135, 112, 64, 1, 69, 67, 0, 0, 8, 6, 128, 56, 133, 96, 32, 1, 64, 180, 7, 14, 172, 8, 0, 40, 23, 128, 226, 97, 128, 128, 5, 200, 219, 44, 3, 0, 6, 32, 44, 108, 8, 205, 26, 3, 84, 129, 78, 148, 86, 146, 11, 201, 254, 49, 136, 241, 18, 152, 185, 122, 76, 65, 77, 69, 51, 46, 49, 48, 48, 170, 170, 170, 18, 48, 0, 0, 10, 238, 120, 6, 62, 152, 121, 218, 51, 108, 0, 0, 25, 125, 242, 255, 251, 20, 68, 240, 7, 240, 72, 1, 196, 163, 33, 0, 10, 7, 128, 88, 149, 96, 65, 1, 128, 192, 7, 16, 172, 8, 0, 40, 25, 1, 161, 129, 132, 140, 4, 128, 102, 139, 132, 124, 18, 192, 2, 0, 2, 9, 136, 11, 28, 112, 221, 245, 135, 25, 70, 40, 89, 11, 9, 129, 146, 103, 106, 157, 76, 65, 77, 69, 51, 46, 49, 48, 48, 170, 170, 57, 0, 0, 0, 60, 141, 51, 71, 22, 94, 202, 36, 88, 144, 0, 0, 6, 218, 253, 11, 255, 251, 20, 68, 238, 135, 112, 36, 1, 195, 131, 2, 0, 8, 8, 64, 72, 149, 60, 96, 1, 64, 148, 5, 22, 172, 0, 0, 32, 31, 129, 162, 97, 132, 136, 4, 160, 201, 40, 160, 170, 168, 182, 0, 7, 23, 192, 97, 199, Line truncated
|
||||||
|
loop = true
|
||||||
|
|
||||||
|
[node name="Node3D" type="Node3D"]
|
||||||
|
|
||||||
|
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
|
||||||
|
environment = SubResource("Environment_w4a4u")
|
||||||
|
|
||||||
|
[node name="MeshInstance3D" type="MeshInstance3D" parent="."]
|
||||||
|
transform = Transform3D(2.18258, 0, 0, 0, 0.3, 0, 0, 0, 1.99376, 0, -1, 0)
|
||||||
|
mesh = SubResource("BoxMesh_klvfh")
|
||||||
|
|
||||||
|
[node name="StaticBody3D" type="StaticBody3D" parent="MeshInstance3D"]
|
||||||
|
|
||||||
|
[node name="CollisionShape3D" type="CollisionShape3D" parent="MeshInstance3D/StaticBody3D"]
|
||||||
|
shape = SubResource("ConcavePolygonShape3D_ckv2w")
|
||||||
|
|
||||||
|
[node name="CharacterBody3D" parent="." instance=ExtResource("2_wemtx")]
|
||||||
|
transform = Transform3D(0.256576, 0, -0.966524, 0, 1, 0, 0.966524, 0, 0.256576, 0, 0, 0)
|
||||||
|
|
||||||
|
[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="."]
|
||||||
|
stream = SubResource("AudioStreamMP3_kr6wb")
|
||||||
|
autoplay = true
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
; Engine configuration file.
|
||||||
|
; It's best edited using the editor UI and not directly,
|
||||||
|
; since the parameters that go here are not all obvious.
|
||||||
|
;
|
||||||
|
; Format:
|
||||||
|
; [section] ; section goes between []
|
||||||
|
; param=value ; assign values to parameters
|
||||||
|
|
||||||
|
config_version=5
|
||||||
|
|
||||||
|
[application]
|
||||||
|
|
||||||
|
config/name="Galaxy"
|
||||||
|
run/main_scene="res://node_3d.tscn"
|
||||||
|
config/features=PackedStringArray("4.2", "Forward Plus")
|
||||||
|
config/icon="res://icon.svg"
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
shader_type sky;
|
||||||
|
|
||||||
|
uniform sampler2D base;
|
||||||
|
uniform vec3 base_color : source_color;
|
||||||
|
uniform float base_speed : hint_range(0,1) = 0.1;
|
||||||
|
|
||||||
|
uniform sampler2D layer;
|
||||||
|
uniform sampler2D layer_two;
|
||||||
|
|
||||||
|
uniform float NOISE : hint_range(0,1) = 0.5;
|
||||||
|
|
||||||
|
float random(vec2 coords) {
|
||||||
|
return fract(sin(dot(coords.xy, vec2(12.9898,78.233))) * 43758.5453);
|
||||||
|
}
|
||||||
|
|
||||||
|
void sky() {
|
||||||
|
float NOISE_GRANULARITY = NOISE / 100.0;
|
||||||
|
|
||||||
|
vec2 base_coords = vec2(SKY_COORDS.x+TIME*base_speed*0.05, SKY_COORDS.y);
|
||||||
|
vec4 base_pix = texture(base, base_coords);
|
||||||
|
float noise = mix(-NOISE_GRANULARITY, NOISE_GRANULARITY, random(base_coords));
|
||||||
|
float base_alpha = base_pix.a;
|
||||||
|
//if (base_alpha < 0.01 && base_alpha > 0.0) {
|
||||||
|
//base_alpha += noise;
|
||||||
|
//}
|
||||||
|
|
||||||
|
vec2 star_coords = vec2(SKY_COORDS.x-TIME*base_speed*0.05, SKY_COORDS.y);
|
||||||
|
vec4 star_pix = texture(layer_two, star_coords)*0.5;
|
||||||
|
|
||||||
|
vec2 galaxy_coords = vec2(SKY_COORDS.x-TIME*base_speed*0.01, SKY_COORDS.y);
|
||||||
|
vec4 galaxy_pix = max(vec4(0,0,0,0),texture(layer, galaxy_coords));
|
||||||
|
COLOR = vec3(0,0,0) + star_pix.rgb * star_pix.a + base_pix.rgb * base_alpha + + galaxy_pix.rgb * galaxy_pix.a;
|
||||||
|
// Called for every visible pixel in the sky background, as well as all pixels
|
||||||
|
// in the radiance cubemap.
|
||||||
|
}
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
[gd_resource type="ShaderMaterial" load_steps=5 format=3 uid="uid://51srw6jbogv2"]
|
||||||
|
|
||||||
|
[ext_resource type="Shader" path="res://sky.gdshader" id="1_eneyl"]
|
||||||
|
[ext_resource type="Texture2D" uid="uid://yjay8cqle8yi" path="res://aurora.png" id="2_tntr4"]
|
||||||
|
[ext_resource type="Texture2D" uid="uid://cjr3yq45rbob0" path="res://galaxy.png" id="3_ue5o8"]
|
||||||
|
[ext_resource type="Texture2D" uid="uid://bbu4k18ek1nk3" path="res://starlayer.png" id="4_qqleb"]
|
||||||
|
|
||||||
|
[resource]
|
||||||
|
shader = ExtResource("1_eneyl")
|
||||||
|
shader_parameter/base_color = Color(0.125402, 0.324219, 0.138971, 1)
|
||||||
|
shader_parameter/base_speed = 0.033
|
||||||
|
shader_parameter/NOISE = 1.0
|
||||||
|
shader_parameter/base = ExtResource("2_tntr4")
|
||||||
|
shader_parameter/layer = ExtResource("3_ue5o8")
|
||||||
|
shader_parameter/layer_two = ExtResource("4_qqleb")
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 77 MiB |
@@ -0,0 +1,35 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="texture"
|
||||||
|
type="CompressedTexture2D"
|
||||||
|
uid="uid://bbu4k18ek1nk3"
|
||||||
|
path.s3tc="res://.godot/imported/starlayer.png-be8c917fd2a84636b922f33e720b2c13.s3tc.ctex"
|
||||||
|
metadata={
|
||||||
|
"imported_formats": ["s3tc_bptc"],
|
||||||
|
"vram_texture": true
|
||||||
|
}
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://starlayer.png"
|
||||||
|
dest_files=["res://.godot/imported/starlayer.png-be8c917fd2a84636b922f33e720b2c13.s3tc.ctex"]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
compress/mode=2
|
||||||
|
compress/high_quality=false
|
||||||
|
compress/lossy_quality=0.7
|
||||||
|
compress/hdr_compression=1
|
||||||
|
compress/normal_map=0
|
||||||
|
compress/channel_pack=0
|
||||||
|
mipmaps/generate=true
|
||||||
|
mipmaps/limit=-1
|
||||||
|
roughness/mode=0
|
||||||
|
roughness/src_normal=""
|
||||||
|
process/fix_alpha_border=true
|
||||||
|
process/premult_alpha=false
|
||||||
|
process/normal_map_invert_y=false
|
||||||
|
process/hdr_as_srgb=false
|
||||||
|
process/hdr_clamp_exposure=false
|
||||||
|
process/size_limit=0
|
||||||
|
detect_3d/compress_to=0
|
||||||
Reference in new issue
Block a user