Cleanup
parent
5011bca3f9
commit
7cf17fc425
|
@ -1,26 +0,0 @@
|
|||
[gd_scene load_steps=2 format=1]
|
||||
|
||||
[ext_resource path="res://block_node.gd" type="Script" id=1]
|
||||
|
||||
[node name="Block" type="MeshInstance"]
|
||||
|
||||
_import_transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
|
||||
layers = 1
|
||||
geometry/visible = true
|
||||
geometry/material_override = null
|
||||
geometry/cast_shadow = 1
|
||||
geometry/receive_shadows = true
|
||||
geometry/range_begin = 0.0
|
||||
geometry/range_end = 0.0
|
||||
geometry/extra_cull_margin = 0.0
|
||||
geometry/billboard = false
|
||||
geometry/billboard_y = false
|
||||
geometry/depth_scale = false
|
||||
geometry/visible_in_all_rooms = false
|
||||
geometry/use_baked_light = false
|
||||
geometry/baked_light_tex_id = 0
|
||||
mesh/mesh = null
|
||||
mesh/skeleton = NodePath("..")
|
||||
script/script = ExtResource( 1 )
|
||||
|
||||
|
|
@ -1,54 +0,0 @@
|
|||
|
||||
extends MeshInstance
|
||||
|
||||
|
||||
var voxel_map = null
|
||||
|
||||
var _normal_material = null
|
||||
var _spawn_material = null
|
||||
var _normal_pos = Vector3(0,0,0)
|
||||
var _anim_time = 0
|
||||
|
||||
|
||||
func _ready():
|
||||
pass
|
||||
|
||||
|
||||
func spawn():
|
||||
# _spawn_material = FixedMaterial.new()
|
||||
# _spawn_material.set_texture(FixedMaterial.PARAM_DIFFUSE, voxel_map.material.get_texture(FixedMaterial.PARAM_DIFFUSE))
|
||||
# _spawn_material.set_parameter(FixedMaterial.PARAM_DIFFUSE, Color(1,1,1,0.5))
|
||||
# _spawn_material.set_flag(FixedMaterial.FLAG_USE_ALPHA, true)
|
||||
#_spawn_material.set_blend_mode(Material.BLEND_MODE_MIX)
|
||||
#set_material_override(_spawn_material)
|
||||
#set_material_override(voxel_map.material)
|
||||
_normal_pos = get_translation()
|
||||
set_translation(Vector3(_normal_pos.x, _normal_pos.y - 64.0, _normal_pos.x))
|
||||
set_process(true)
|
||||
|
||||
|
||||
func _process(delta):
|
||||
_anim_time += delta
|
||||
var k = _anim_time
|
||||
if k < 1.0:
|
||||
var pos = _normal_pos
|
||||
pos.y -= (1-k)*(1-k) * 64.0
|
||||
set_translation(pos)
|
||||
else:
|
||||
set_translation(_normal_pos) # here
|
||||
set_process(false)
|
||||
|
||||
# var color = _spawn_material.get_parameter(FixedMaterial.PARAM_DIFFUSE)
|
||||
# if color.a < 1.0:
|
||||
# color.a += (0.1*delta)
|
||||
# if color.a >= 1.0:
|
||||
# set_material_override(voxel_map.material)
|
||||
# set_process(false)
|
||||
# _spawn_material = null
|
||||
# else:
|
||||
# color.r = color.a
|
||||
# color.g = color.a
|
||||
# color.b = color.a
|
||||
# _spawn_material.set_parameter(FixedMaterial.PARAM_DIFFUSE, color)
|
||||
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
config_version=3
|
||||
[application]
|
||||
|
||||
name="Test3"
|
||||
name="Voxel Game"
|
||||
main_scene="res://main.tscn"
|
||||
icon="res://icon.png"
|
||||
|
||||
|
@ -12,3 +12,4 @@ multithread/thread_rid_pool_prealloc=60
|
|||
[rendering]
|
||||
|
||||
viewport/default_clear_color=Color( 0.407806, 0.628906, 0.618542, 1 )
|
||||
quality/use_nearest_mipmap_filter=true
|
||||
|
|
|
@ -12,4 +12,4 @@ func _ready():
|
|||
|
||||
|
||||
func _on_Node_pressed():
|
||||
get_tree().change_scene("res://new_scene.tscn")
|
||||
get_tree().change_scene("res://main.tscn")
|
||||
|
|
|
@ -1,275 +0,0 @@
|
|||
[gd_scene load_steps=8 format=1]
|
||||
|
||||
[ext_resource path="res://debug_camera.gd" type="Script" id=1]
|
||||
[ext_resource path="res://voxel_map.gd" type="Script" id=2]
|
||||
[ext_resource path="res://terrain.png" type="Texture" id=3]
|
||||
[ext_resource path="res://grid.gd" type="Script" id=4]
|
||||
|
||||
[sub_resource type="FixedMaterial" id=1]
|
||||
|
||||
flags/visible = true
|
||||
flags/double_sided = false
|
||||
flags/invert_faces = false
|
||||
flags/unshaded = false
|
||||
flags/on_top = false
|
||||
flags/lightmap_on_uv2 = true
|
||||
flags/colarray_is_srgb = true
|
||||
params/blend_mode = 0
|
||||
params/depth_draw = 1
|
||||
params/line_width = 0.0
|
||||
fixed_flags/use_alpha = false
|
||||
fixed_flags/use_color_array = true
|
||||
fixed_flags/use_point_size = false
|
||||
fixed_flags/discard_alpha = false
|
||||
fixed_flags/use_xy_normalmap = false
|
||||
params/diffuse = Color( 1, 1, 1, 1 )
|
||||
params/specular = Color( 0, 0, 0, 1 )
|
||||
params/emission = Color( 0, 0, 0, 1 )
|
||||
params/specular_exp = 40
|
||||
params/detail_mix = 1.0
|
||||
params/normal_depth = 1
|
||||
params/shader = 0
|
||||
params/shader_param = 0.5
|
||||
params/glow = 0
|
||||
params/point_size = 1.0
|
||||
uv_xform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
|
||||
textures/diffuse = ExtResource( 3 )
|
||||
textures/diffuse_tc = 0
|
||||
textures/detail_tc = 0
|
||||
textures/specular_tc = 0
|
||||
textures/emission_tc = 0
|
||||
textures/specular_exp_tc = 0
|
||||
textures/glow_tc = 0
|
||||
textures/normal_tc = 0
|
||||
textures/shade_param_tc = 0
|
||||
|
||||
[sub_resource type="FixedMaterial" id=2]
|
||||
|
||||
flags/visible = true
|
||||
flags/double_sided = true
|
||||
flags/invert_faces = false
|
||||
flags/unshaded = false
|
||||
flags/on_top = false
|
||||
flags/lightmap_on_uv2 = true
|
||||
flags/colarray_is_srgb = true
|
||||
params/blend_mode = 0
|
||||
params/depth_draw = 2
|
||||
params/line_width = 0.0
|
||||
fixed_flags/use_alpha = true
|
||||
fixed_flags/use_color_array = false
|
||||
fixed_flags/use_point_size = false
|
||||
fixed_flags/discard_alpha = false
|
||||
fixed_flags/use_xy_normalmap = false
|
||||
params/diffuse = Color( 1, 1, 1, 1 )
|
||||
params/specular = Color( 0, 0, 0, 1 )
|
||||
params/emission = Color( 0, 0, 0, 1 )
|
||||
params/specular_exp = 40
|
||||
params/detail_mix = 1.0
|
||||
params/normal_depth = 1
|
||||
params/shader = 0
|
||||
params/shader_param = 0.5
|
||||
params/glow = 0
|
||||
params/point_size = 1.0
|
||||
uv_xform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
|
||||
textures/diffuse = ExtResource( 3 )
|
||||
textures/diffuse_tc = 0
|
||||
textures/detail_tc = 0
|
||||
textures/specular_tc = 0
|
||||
textures/emission_tc = 0
|
||||
textures/specular_exp_tc = 0
|
||||
textures/glow_tc = 0
|
||||
textures/normal_tc = 0
|
||||
textures/shade_param_tc = 0
|
||||
|
||||
[sub_resource type="Environment" id=3]
|
||||
|
||||
ambient_light/enabled = true
|
||||
ambient_light/color = Color( 0.378906, 0.378906, 0.378906, 1 )
|
||||
ambient_light/energy = 1.0
|
||||
fxaa/enabled = false
|
||||
background/mode = 2
|
||||
background/color = Color( 0.446167, 0.645425, 0.671875, 1 )
|
||||
background/energy = 1.0
|
||||
background/scale = 1.0
|
||||
background/glow = 0.0
|
||||
background/canvas_max_layer = null
|
||||
glow/enabled = false
|
||||
glow/blur_passes = 1
|
||||
glow/blur_scale = 1
|
||||
glow/blur_strength = 1
|
||||
glow/blur_blend_mode = null
|
||||
glow/bloom = 0.0
|
||||
glow/bloom_treshold = 0.5
|
||||
dof_blur/enabled = false
|
||||
dof_blur/blur_passes = 2
|
||||
dof_blur/begin = 0.0
|
||||
dof_blur/range = 10.0
|
||||
hdr/enabled = false
|
||||
hdr/tonemapper = 0
|
||||
hdr/exposure = 0.4
|
||||
hdr/white = 1.0
|
||||
hdr/glow_treshold = 0.95
|
||||
hdr/glow_scale = 0.2
|
||||
hdr/min_luminance = 0.4
|
||||
hdr/max_luminance = 8.0
|
||||
hdr/exposure_adj_speed = 0.5
|
||||
fog/enabled = true
|
||||
fog/begin = 32.0
|
||||
fog/begin_color = Color( 0, 0, 0, 1 )
|
||||
fog/end_color = Color( 0.443137, 0.643137, 0.670588, 1 )
|
||||
fog/attenuation = 2.14355
|
||||
fog/bg = true
|
||||
bcs/enabled = false
|
||||
bcs/brightness = 1.0
|
||||
bcs/contrast = 1.0
|
||||
bcs/saturation = 1.0
|
||||
srgb/enabled = false
|
||||
|
||||
[node name="Node" type="Node"]
|
||||
|
||||
[node name="Camera" type="Camera" parent="."]
|
||||
|
||||
editor/display_folded = true
|
||||
_import_transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
|
||||
transform/local = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 4, 0 )
|
||||
projection = 0
|
||||
fov = 80.0
|
||||
near = 0.1
|
||||
far = 200.0
|
||||
keep_aspect = 1
|
||||
current = true
|
||||
visible_layers = 1048575
|
||||
environment = null
|
||||
h_offset = 0.0
|
||||
v_offset = 0.0
|
||||
script/script = ExtResource( 1 )
|
||||
sensitivity = 0.4
|
||||
min_angle = -90
|
||||
max_angle = 90
|
||||
speed = 10.0
|
||||
capture_mouse = true
|
||||
|
||||
[node name="Particles" type="Particles" parent="Camera"]
|
||||
|
||||
_import_transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
|
||||
layers = 1
|
||||
geometry/visible = true
|
||||
geometry/material_override = null
|
||||
geometry/cast_shadow = 0
|
||||
geometry/receive_shadows = true
|
||||
geometry/range_begin = 0.0
|
||||
geometry/range_end = 0.0
|
||||
geometry/extra_cull_margin = 0.0
|
||||
geometry/billboard = false
|
||||
geometry/billboard_y = false
|
||||
geometry/depth_scale = false
|
||||
geometry/visible_in_all_rooms = false
|
||||
geometry/use_baked_light = false
|
||||
geometry/baked_light_tex_id = 0
|
||||
material = null
|
||||
amount = 256
|
||||
emitting = true
|
||||
visibility = AABB( -4, -4, -4, 8, 8, 8 )
|
||||
emission_extents = Vector3( 32, 32, 32 )
|
||||
emission_base_velocity = Vector3( 0, 0, 0 )
|
||||
emission_points = Vector3Array( )
|
||||
gravity_normal = Vector3( 0, -1, 0 )
|
||||
local_coords = false
|
||||
emit_timeout = 0.0
|
||||
vars/lifetime = 5.0
|
||||
vars/spread = 0.2
|
||||
vars/gravity = 0.0
|
||||
vars/linear_vel = 0.2
|
||||
vars/angular_vel = 0.0
|
||||
vars/linear_accel = 0.0
|
||||
vars/radial_accel = 0.0
|
||||
vars/tan_accel = 0.0
|
||||
vars/damping = 0.0
|
||||
vars/initial_size = 0.05
|
||||
vars/final_size = 0.05
|
||||
vars/initial_angle = 0.0
|
||||
vars/height_from_velocity = false
|
||||
vars/height = 1.0
|
||||
vars/height_speed_scale = 0.0
|
||||
rand/lifetime = 0.0
|
||||
rand/spread = 0.0
|
||||
rand/gravity = 0.0
|
||||
rand/linear_vel = 0.0
|
||||
rand/angular_vel = 0.0
|
||||
rand/linear_accel = 0.0
|
||||
rand/radial_accel = 0.0
|
||||
rand/tan_accel = 0.0
|
||||
rand/damping = 0.0
|
||||
rand/initial_size = 0.0
|
||||
rand/final_size = 0.0
|
||||
rand/initial_angle = 0.0
|
||||
rand/height = 0.0
|
||||
rand/height_speed_scale = 0.0
|
||||
color_phases/count = 0
|
||||
phase_0/pos = 0.0
|
||||
phase_0/color = Color( 0, 0, 0, 1 )
|
||||
phase_1/pos = 1.0
|
||||
phase_1/color = Color( 0, 0, 0, 1 )
|
||||
phase_2/pos = 1.0
|
||||
phase_2/color = Color( 0, 0, 0, 1 )
|
||||
phase_3/pos = 1.0
|
||||
phase_3/color = Color( 0, 0, 0, 1 )
|
||||
|
||||
[node name="VoxelTerrain" type="VoxelTerrain" parent="."]
|
||||
|
||||
script/script = ExtResource( 2 )
|
||||
solid_material = SubResource( 1 )
|
||||
transparent_material = SubResource( 2 )
|
||||
|
||||
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
|
||||
|
||||
_import_transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
|
||||
environment = SubResource( 3 )
|
||||
|
||||
[node name="DirectionalLight" type="DirectionalLight" parent="."]
|
||||
|
||||
_import_transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
|
||||
transform/local = Transform( -0.761692, 0.482016, -0.432995, -0.609208, -0.305189, 0.731932, 0.220658, 0.821291, 0.526108, 1.11878, 2.33452, 7.6244 )
|
||||
layers = 1
|
||||
params/enabled = true
|
||||
params/editor_only = false
|
||||
params/bake_mode = 0
|
||||
params/energy = 1.0
|
||||
colors/diffuse = Color( 1, 1, 1, 1 )
|
||||
colors/specular = Color( 1, 1, 1, 1 )
|
||||
shadow/shadow = false
|
||||
shadow/darkening = 0.0
|
||||
shadow/z_offset = 0.05
|
||||
shadow/z_slope_scale = 0.0
|
||||
shadow/esm_multiplier = 60.0
|
||||
shadow/blur_passes = 1.0
|
||||
projector = null
|
||||
operator = 0
|
||||
shadow/mode = 3
|
||||
shadow/max_distance = 32.0
|
||||
shadow/split_weight = 0.5
|
||||
shadow/zoffset_scale = 2.0
|
||||
|
||||
[node name="Grid" type="MeshInstance" parent="."]
|
||||
|
||||
_import_transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
|
||||
visibility/visible = false
|
||||
layers = 1
|
||||
geometry/visible = true
|
||||
geometry/material_override = null
|
||||
geometry/cast_shadow = 1
|
||||
geometry/receive_shadows = true
|
||||
geometry/range_begin = 0.0
|
||||
geometry/range_end = 0.0
|
||||
geometry/extra_cull_margin = 0.0
|
||||
geometry/billboard = false
|
||||
geometry/billboard_y = false
|
||||
geometry/depth_scale = false
|
||||
geometry/visible_in_all_rooms = false
|
||||
geometry/use_baked_light = false
|
||||
geometry/baked_light_tex_id = 0
|
||||
mesh/mesh = null
|
||||
mesh/skeleton = NodePath("..")
|
||||
script/script = ExtResource( 4 )
|
||||
|
||||
|
|
@ -6,15 +6,15 @@ path="res://.import/terrain.png-84a626877af7de08ecf24965bda52835.stex"
|
|||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/mode=3
|
||||
compress/lossy_quality=0.7
|
||||
flags/repeat=0
|
||||
flags/repeat=true
|
||||
flags/filter=false
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
flags/srgb=0
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=true
|
||||
process/premult_alpha=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
detect_3d=false
|
||||
|
|
Loading…
Reference in New Issue