Commit 413dfe00 authored by frankie's avatar frankie 💬

example UI

parent e5437cb9
This diff is collapsed.
......@@ -65,7 +65,6 @@ ssao_radius2 = 0.0
ssao_intensity2 = 1.0
ssao_bias = 0.01
ssao_light_affect = 0.0
ssao_ao_channel_affect = 0.0
ssao_color = Color( 0, 0, 0, 1 )
ssao_quality = 0
ssao_blur = 3
......
......@@ -6,7 +6,7 @@
; [section] ; section goes between []
; param=value ; assign values to parameters
config_version=4
config_version=3
_global_script_classes=[ ]
_global_script_class_icons={
......
......@@ -17,9 +17,6 @@ flags_use_point_size = false
flags_world_triplanar = false
flags_fixed_size = false
flags_albedo_tex_force_srgb = false
flags_do_not_receive_shadows = false
flags_disable_ambient_light = false
flags_ensure_correct_normals = false
vertex_color_use_as_albedo = false
vertex_color_is_srgb = false
params_diffuse_mode = 0
......@@ -30,7 +27,6 @@ params_depth_draw_mode = 0
params_line_width = 1.0
params_point_size = 1.0
params_billboard_mode = 0
params_billboard_keep_scale = false
params_grow = false
params_use_alpha_scissor = false
albedo_color = Color( 1, 1, 1, 1 )
......@@ -59,7 +55,7 @@ uv2_offset = Vector3( 0, 0, 0 )
uv2_triplanar = false
uv2_triplanar_sharpness = 1.0
proximity_fade_enable = false
distance_fade_mode = 0
distance_fade_enable = false
_sections_unfolded = [ "Albedo", "Metallic", "Parameters", "Roughness" ]
[sub_resource type="Environment" id=2]
......@@ -106,7 +102,6 @@ ssao_radius2 = 0.0
ssao_intensity2 = 1.0
ssao_bias = 0.01
ssao_light_affect = 0.0
ssao_ao_channel_affect = 0.0
ssao_color = Color( 0, 0, 0, 1 )
ssao_quality = 0
ssao_blur = 3
......@@ -145,16 +140,16 @@ _sections_unfolded = [ "Ambient Light", "Background", "DOF Far Blur", "Fog", "Gl
[sub_resource type="CylinderMesh" id=3]
custom_aabb = AABB( 0, 0, 0, 0, 0, 0 )
flip_faces = false
top_radius = 1.0
bottom_radius = 1.0
height = 2.0
radial_segments = 64
rings = 4
[node name="root" type="Spatial"]
[node name="root" type="Spatial" index="0"]
[node name="cam" type="Camera" parent="." index="0"]
[node name="cam" type="Camera" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 29.2395 )
keep_aspect = 1
cull_mask = 1048575
......@@ -170,7 +165,8 @@ near = 0.05
far = 100.0
_sections_unfolded = [ "Matrix", "Transform" ]
[node name="sun" type="DirectionalLight" parent="."]
[node name="sun" type="DirectionalLight" parent="." index="1"]
transform = Transform( 0.878977, -0.128364, -0.459263, 0.476865, 0.236606, 0.846532, 0, -0.963089, 0.269184, 0, 3.72335, 0 )
layers = 1
light_color = Color( 1, 1, 1, 1 )
......@@ -196,7 +192,8 @@ directional_shadow_bias_split_scale = 0.25
directional_shadow_depth_range = 0
directional_shadow_max_distance = 200.0
[node name="smasher" parent="." instance=ExtResource( 1 )]
[node name="smasher" parent="." index="2" instance=ExtResource( 1 )]
transform = Transform( 4.52178, 0, 0, 0, 4.52178, 0, 0, 0, 4.52178, 0, 0, 0 )
material/0 = SubResource( 1 )
script = ExtResource( 2 )
......@@ -205,17 +202,20 @@ debug = false
speed_horizontal = 0.2
speed_vertical = 0.2
[node name="env" type="WorldEnvironment" parent="."]
[node name="env" type="WorldEnvironment" parent="." index="3"]
environment = SubResource( 2 )
_sections_unfolded = [ "environment" ]
[node name="axis" type="Spatial" parent="."]
[node name="axis" type="Spatial" parent="." index="4"]
script = ExtResource( 2 )
debug = false
speed_horizontal = -0.03
speed_vertical = 0.035
[node name="x" type="MeshInstance" parent="axis"]
[node name="x" type="MeshInstance" parent="axis" index="0"]
transform = Transform( -1.31134e-09, -1000, 0, 0.03, -4.37114e-05, 0, 0, 0, 0.03, 0, 0, 0 )
layers = 1
material_override = null
......@@ -231,7 +231,8 @@ skeleton = NodePath("..")
material/0 = ExtResource( 3 )
_sections_unfolded = [ "Transform", "material" ]
[node name="y" type="MeshInstance" parent="axis"]
[node name="y" type="MeshInstance" parent="axis" index="1"]
transform = Transform( 0.03, 0, 0, 0, 1000, 0, 0, 0, 0.03, 0, 0, 0 )
layers = 1
material_override = null
......@@ -247,7 +248,8 @@ skeleton = NodePath("..")
material/0 = ExtResource( 4 )
_sections_unfolded = [ "Transform", "material" ]
[node name="z" type="MeshInstance" parent="axis"]
[node name="z" type="MeshInstance" parent="axis" index="2"]
transform = Transform( 0.03, 0, 0, 0, -4.37114e-05, -0.03, 0, 1000, -1.31134e-09, 0, 0, 0 )
layers = 1
material_override = null
......@@ -263,3 +265,4 @@ skeleton = NodePath("..")
material/0 = ExtResource( 5 )
_sections_unfolded = [ "Transform", "material" ]
source_md5="e448a825d68428f933f6271d26b2f4ca"
dest_md5="c17bedb4095d34ff0eb4bc347ea1d73a"
source_md5="a3f766e3b53dcc0b0633d03aab57f391"
dest_md5="5673ad68d13de6ec6759a00df35617ae"
source_md5="6994871f86c9629e92f6712ada42e298"
dest_md5="0ac81f486fe5fe66d5cfb348f960e6a7"
source_md5="f9016a351f0e9d7b6f15a92f46e21537"
dest_md5="b4d2796ef5291de1a5fb20e9301e26a1"
source_md5="0225ce317874d11307e6378024c11b8e"
dest_md5="bc79c78527409b7c1d6841c3541704ab"
source_md5="eaf070b3c469787b42f4c67262ed5515"
dest_md5="8f7e19379fa615fae5d218a1b22f4a04"
[gd_resource type="Environment" load_steps=2 format=2]
[sub_resource type="ProceduralSky" id=1]
radiance_size = 4
sky_top_color = Color( 0.647059, 0.839216, 0.945098, 1 )
sky_horizon_color = Color( 0.839216, 0.917647, 0.980392, 1 )
sky_curve = 0.09
sky_energy = 1.0
ground_bottom_color = Color( 0.156863, 0.184314, 0.211765, 1 )
ground_horizon_color = Color( 0.423529, 0.396078, 0.372549, 1 )
ground_curve = 0.02
ground_energy = 1.0
sun_color = Color( 1, 1, 1, 1 )
sun_latitude = 35.0
sun_longitude = 0.0
sun_angle_min = 1.0
sun_angle_max = 100.0
sun_curve = 0.05
sun_energy = 16.0
texture_size = 2
[resource]
background_mode = 2
background_sky = SubResource( 1 )
background_sky_custom_fov = 0.0
background_color = Color( 0, 0, 0, 1 )
background_energy = 1.0
background_canvas_max_layer = 0
ambient_light_color = Color( 0, 0, 0, 1 )
ambient_light_energy = 1.0
ambient_light_sky_contribution = 1.0
fog_enabled = false
fog_color = Color( 0.5, 0.6, 0.7, 1 )
fog_sun_color = Color( 1, 0.9, 0.7, 1 )
fog_sun_amount = 0.0
fog_depth_enabled = true
fog_depth_begin = 10.0
fog_depth_curve = 1.0
fog_transmit_enabled = false
fog_transmit_curve = 1.0
fog_height_enabled = false
fog_height_min = 0.0
fog_height_max = 100.0
fog_height_curve = 1.0
tonemap_mode = 0
tonemap_exposure = 1.0
tonemap_white = 1.0
auto_exposure_enabled = false
auto_exposure_scale = 0.4
auto_exposure_min_luma = 0.05
auto_exposure_max_luma = 8.0
auto_exposure_speed = 0.5
ss_reflections_enabled = false
ss_reflections_max_steps = 64
ss_reflections_fade_in = 0.15
ss_reflections_fade_out = 2.0
ss_reflections_depth_tolerance = 0.2
ss_reflections_roughness = true
ssao_enabled = false
ssao_radius = 1.0
ssao_intensity = 1.0
ssao_radius2 = 0.0
ssao_intensity2 = 1.0
ssao_bias = 0.01
ssao_light_affect = 0.0
ssao_color = Color( 0, 0, 0, 1 )
ssao_quality = 0
ssao_blur = 3
ssao_edge_sharpness = 4.0
dof_blur_far_enabled = false
dof_blur_far_distance = 10.0
dof_blur_far_transition = 5.0
dof_blur_far_amount = 0.1
dof_blur_far_quality = 1
dof_blur_near_enabled = false
dof_blur_near_distance = 2.0
dof_blur_near_transition = 1.0
dof_blur_near_amount = 0.1
dof_blur_near_quality = 1
glow_enabled = false
glow_levels/1 = false
glow_levels/2 = false
glow_levels/3 = true
glow_levels/4 = false
glow_levels/5 = true
glow_levels/6 = false
glow_levels/7 = false
glow_intensity = 0.8
glow_strength = 1.0
glow_bloom = 0.0
glow_blend_mode = 2
glow_hdr_threshold = 1.0
glow_hdr_scale = 2.0
glow_bicubic_upscale = false
adjustment_enabled = false
adjustment_brightness = 1.0
adjustment_contrast = 1.0
adjustment_saturation = 1.0
[gd_resource type="DynamicFont" load_steps=2 format=2]
[ext_resource path="res://fonts/CatV_6x12_9.ttf" type="DynamicFontData" id=1]
[resource]
size = 15
use_mipmaps = false
use_filter = false
font_data = ExtResource( 1 )
_sections_unfolded = [ "Extra Spacing", "Font", "Resource", "Settings" ]
[gd_resource type="Theme" load_steps=2 format=2]
[ext_resource path="res://fonts/catv_15.tres" type="DynamicFont" id=1]
[resource]
default_font = ExtResource( 1 )
_sections_unfolded = [ "Resource" ]
[gd_resource type="DynamicFont" load_steps=2 format=2]
[ext_resource path="res://fonts/CatV_6x12_9.ttf" type="DynamicFontData" id=1]
[resource]
size = 20
use_mipmaps = false
use_filter = false
font_data = ExtResource( 1 )
_sections_unfolded = [ "Extra Spacing", "Font", "Settings" ]
[gd_resource type="Theme" load_steps=2 format=2]
[ext_resource path="res://fonts/catv_20.tres" type="DynamicFont" id=1]
[resource]
default_font = ExtResource( 1 )
_sections_unfolded = [ "Resource" ]
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex"
[deps]
source_file="res://icon.png"
dest_files=[ "res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=true
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0
[gd_resource type="SpatialMaterial" format=2]
[resource]
render_priority = 0
flags_transparent = false
flags_unshaded = true
flags_vertex_lighting = false
flags_no_depth_test = false
flags_use_point_size = false
flags_world_triplanar = false
flags_fixed_size = false
flags_albedo_tex_force_srgb = false
flags_do_not_receive_shadows = false
flags_disable_ambient_light = false
flags_ensure_correct_normals = false
vertex_color_use_as_albedo = false
vertex_color_is_srgb = false
params_diffuse_mode = 0
params_specular_mode = 0
params_blend_mode = 0
params_cull_mode = 0
params_depth_draw_mode = 0
params_line_width = 1.0
params_point_size = 1.0
params_billboard_mode = 0
params_billboard_keep_scale = false
params_grow = false
params_use_alpha_scissor = false
albedo_color = Color( 1, 0.784314, 0.784314, 1 )
metallic = 0.0
metallic_specular = 0.5
metallic_texture_channel = 0
roughness = 1.0
roughness_texture_channel = 0
emission_enabled = false
normal_enabled = false
rim_enabled = false
clearcoat_enabled = false
anisotropy_enabled = false
ao_enabled = false
depth_enabled = false
subsurf_scatter_enabled = false
transmission_enabled = false
refraction_enabled = false
detail_enabled = false
uv1_scale = Vector3( 1, 1, 1 )
uv1_offset = Vector3( 0, 0, 0 )
uv1_triplanar = false
uv1_triplanar_sharpness = 1.0
uv2_scale = Vector3( 1, 1, 1 )
uv2_offset = Vector3( 0, 0, 0 )
uv2_triplanar = false
uv2_triplanar_sharpness = 1.0
proximity_fade_enable = false
distance_fade_mode = 0
_sections_unfolded = [ "Albedo", "Flags", "Parameters", "Vertex Color" ]
[gd_resource type="SpatialMaterial" format=2]
[resource]
render_priority = 0
flags_transparent = false
flags_unshaded = true
flags_vertex_lighting = false
flags_no_depth_test = false
flags_use_point_size = false
flags_world_triplanar = false
flags_fixed_size = false
flags_albedo_tex_force_srgb = false
flags_do_not_receive_shadows = false
flags_disable_ambient_light = false
flags_ensure_correct_normals = false
vertex_color_use_as_albedo = false
vertex_color_is_srgb = false
params_diffuse_mode = 0
params_specular_mode = 0
params_blend_mode = 0
params_cull_mode = 0
params_depth_draw_mode = 0
params_line_width = 1.0
params_point_size = 1.0
params_billboard_mode = 0
params_billboard_keep_scale = false
params_grow = false
params_use_alpha_scissor = false
albedo_color = Color( 0.784314, 1, 0.784314, 1 )
metallic = 0.0
metallic_specular = 0.5
metallic_texture_channel = 0
roughness = 1.0
roughness_texture_channel = 0
emission_enabled = false
normal_enabled = false
rim_enabled = false
clearcoat_enabled = false
anisotropy_enabled = false
ao_enabled = false
depth_enabled = false
subsurf_scatter_enabled = false
transmission_enabled = false
refraction_enabled = false
detail_enabled = false
uv1_scale = Vector3( 1, 1, 1 )
uv1_offset = Vector3( 0, 0, 0 )
uv1_triplanar = false
uv1_triplanar_sharpness = 1.0
uv2_scale = Vector3( 1, 1, 1 )
uv2_offset = Vector3( 0, 0, 0 )
uv2_triplanar = false
uv2_triplanar_sharpness = 1.0
proximity_fade_enable = false
distance_fade_mode = 0
_sections_unfolded = [ "Albedo", "Flags", "Parameters", "Vertex Color" ]
[gd_resource type="SpatialMaterial" format=2]
[resource]
render_priority = 0
flags_transparent = false
flags_unshaded = true
flags_vertex_lighting = false
flags_no_depth_test = false
flags_use_point_size = false
flags_world_triplanar = false
flags_fixed_size = false
flags_albedo_tex_force_srgb = false
flags_do_not_receive_shadows = false
flags_disable_ambient_light = false
flags_ensure_correct_normals = false
vertex_color_use_as_albedo = false
vertex_color_is_srgb = false
params_diffuse_mode = 0
params_specular_mode = 0
params_blend_mode = 0
params_cull_mode = 0
params_depth_draw_mode = 0
params_line_width = 1.0
params_point_size = 1.0
params_billboard_mode = 0
params_billboard_keep_scale = false
params_grow = false
params_use_alpha_scissor = false
albedo_color = Color( 0.784314, 0.784314, 1, 1 )
metallic = 0.0
metallic_specular = 0.5
metallic_texture_channel = 0
roughness = 1.0
roughness_texture_channel = 0
emission_enabled = false
normal_enabled = false
rim_enabled = false
clearcoat_enabled = false
anisotropy_enabled = false
ao_enabled = false
depth_enabled = false
subsurf_scatter_enabled = false
transmission_enabled = false
refraction_enabled = false
detail_enabled = false
uv1_scale = Vector3( 1, 1, 1 )
uv1_offset = Vector3( 0, 0, 0 )
uv1_triplanar = false
uv1_triplanar_sharpness = 1.0
uv2_scale = Vector3( 1, 1, 1 )
uv2_offset = Vector3( 0, 0, 0 )
uv2_triplanar = false
uv2_triplanar_sharpness = 1.0
proximity_fade_enable = false
distance_fade_mode = 0
_sections_unfolded = [ "Albedo", "Flags", "Parameters", "Vertex Color" ]
extends Node2D
var btn = null
var info = null
var info_pos = null
var info_pos_target = null
var sprites = []
var sa = 0
var sa_target = 0
func sprite_alpha( a ):
info.modulate.a = a
var ai = ( 1 + sin( -PI*0.5 + a * PI ) ) * 0.5
info.position = ( info_pos_target * ai ) + ( info_pos * ( 1 - ai ) )
for s in sprites:
s.modulate.a = ai
if not info.visible:
info.visible = true
func _ready():
btn = get_node( "info_btn" )
info = get_node( "info_content" )
if info:
info_pos = Vector2( -300,0 )
info_pos_target = Vector2( -300,0 )
sprites.append( get_node( "info_content/shivinteger" ) )
sprites.append( get_node( "info_content/preview" ) )
sprite_alpha( sa )
func _process(delta):
if info:
if sa < sa_target:
sa += delta * 2
if sa > sa_target:
sa = sa_target
elif sa > sa_target:
sa -= delta * 4
if sa < sa_target:
sa = sa_target
sprite_alpha( sa )
func _on_info_btn_pressed():
if sa_target == 0:
info_pos = Vector2( info.position.x, info.position.y )
info_pos_target = Vector2( 0,0 )
sa_target = 1
else:
info_pos = Vector2( -300,0 )
info_pos_target = Vector2( info.position.x, info.position.y )
sa_target = 0
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
; 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=3
_global_script_classes=[ ]
_global_script_class_icons={
}
[application]
config/name="UI"
run/main_scene="res://root.tscn"
config/icon="res://icon.png"
[rendering]
quality/filters/msaa=3
environment/default_environment="res://default_env.tres"
This diff is collapsed.
tool
extends Spatial
var y_speed = 0
var y_speed_target = 0.07
var mousepos = Vector2(0,0)
export(bool) var debug = false
export(float, -2, 2) var speed_horizontal = 1 setget sh
export(float, -2, 2) var speed_vertical = 1 setget sv
func sh(value):
speed_horizontal = value
func sv(value):
speed_vertical = value
func _ready():
pass # Replace with function body.
func _input(event):
if debug:
print( event )
#if (event is InputEventMouseButton and event.is_pressed() == true):
if (event is InputEventMouseMotion ):
if debug:
print( event.relative / OS.window_size )
var tmp = mousepos + (event.relative / OS.window_size)
mousepos += (tmp - mousepos) * 0.2
func _process(delta):
# y_speed += ( y_speed_target - y_speed ) * 0.1 * delta
rotate_x( mousepos.y * speed_vertical )
rotate_y( mousepos.x * speed_horizontal )
# mousepos *= 0.95
pass
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/shivinteger.jpg-3b38f126a6d203fc774d0847158f74c3.stex"
[deps]
source_file="res://textures/shivinteger.jpg"
dest_files=[ "res://.import/shivinteger.jpg-3b38f126a6d203fc774d0847158f74c3.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/normal_map=0
flags/repeat=0
flags/filter=true
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/smasher_customizer_preview_featured.jpg-0df7843a1652fd47812e82a3ee09fe7e.stex"
[deps]
source_file="res://textures/smasher_customizer_preview_featured.jpg"
dest_files=[ "res://.import/smasher_customizer_preview_featured.jpg-0df7843a1652fd47812e82a3ee09fe7e.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/normal_map=0
flags/repeat=0
flags/filter=true
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment