diff --git a/Runtime/Procedural/Assets/Grass/Windy Grass Shader.gdshader b/Runtime/Procedural/Assets/Grass/Windy Grass Shader.gdshader index b35cbbc..31a7e9b 100644 --- a/Runtime/Procedural/Assets/Grass/Windy Grass Shader.gdshader +++ b/Runtime/Procedural/Assets/Grass/Windy Grass Shader.gdshader @@ -6,10 +6,14 @@ render_mode blend_mix, depth_draw_opaque, cull_back, diffuse_burley, specular_sc #include "res://addons/rokojori_action_library/Runtime/Shading/Library/Math.gdshaderinc" #include "res://addons/rokojori_action_library/Runtime/Shading/Library/Transform.gdshaderinc" #include "res://addons/rokojori_action_library/Runtime/Shading/Library/Noise.gdshaderinc" - +#include "res://addons/rokojori_action_library/Runtime/Shading/Library/Colors.gdshaderinc" uniform vec4 albedo : source_color; +uniform vec4 hslVariation; +uniform float hslVariationUVScale; +uniform vec2 hslVariationUVOffset; uniform sampler2D texture_albedo : source_color, filter_linear_mipmap, repeat_enable; +varying vec3 albedoColor; uniform float roughness : hint_range(0.0, 1.0); uniform sampler2D texture_metallic : hint_default_white, filter_linear_mipmap, repeat_enable; @@ -46,12 +50,25 @@ void vertex() { UV = UV * uv1_scale.xy + uv1_offset.xy; + vec3 worldVertex = localToWorld( VERTEX, MODEL_MATRIX ).xyz; + vec2 worldUV = worldVertex.xz * hslVariationUVScale; + + float hslAmountValue = ( 2.0 * texture( windNoise, mod( worldUV, vec2( 1,1 ) ) ).r - 1.0 ); + + vec3 albedoHSL = RGBtoHSL( albedo.rgb ) + hslAmountValue * hslVariation.xyz; + //albedoHSL = RGBtoHSL( albedo.rgb ); + //albedoHSL.y *= 1.0; + albedoHSL.x = mod( albedoHSL.x, 1 ); + albedoHSL = clamp( albedoHSL, vec3( 0,0,0 ), vec3( 1,1,1 ) ); + albedoColor = mix( albedo.rgb, HSLtoRGB( albedoHSL ), hslVariation.w ); + + + if ( windEnabled ) { float windAmount = normalizeToRange01( VERTEX.y, windStart, windEnd ); float rawWindAmount = windAmount; - windAmount = mix( windAmount, windAmount * windAmount, windWeightCurve ); - vec3 worldVertex = localToWorld( VERTEX, MODEL_MATRIX ).xyz; + windAmount = mix( windAmount, windAmount * windAmount, windWeightCurve ); vec2 windUV = TIME * windSpeed + worldVertex.xz * windScale; float angle = texture( windNoise, windUV + windNoiseAngleOffset).r * PI * 2.0; float strength = texture( windNoise, windUV + windNoiseStrengthOffset ).r * windStrength; @@ -69,7 +86,7 @@ void fragment() vec2 base_uv = UV; vec4 albedo_tex = texture(texture_albedo, base_uv); - ALBEDO = albedo.rgb * albedo_tex.rgb; + ALBEDO = albedoColor * albedo_tex.rgb; float metallic_tex = dot(texture(texture_metallic, base_uv), metallic_texture_channel); diff --git a/Runtime/Procedural/Textures/TextureCombiner/Layers/TextureCombinerTilerLayer.cs b/Runtime/Procedural/Textures/TextureCombiner/Layers/TextureCombinerTilerLayer.cs new file mode 100644 index 0000000..fdbf94d --- /dev/null +++ b/Runtime/Procedural/Textures/TextureCombiner/Layers/TextureCombinerTilerLayer.cs @@ -0,0 +1,64 @@ +using System.Collections; +using System.Collections.Generic; +using Godot; +using System; +using System.Threading; +using System.Threading.Tasks; + + +namespace Rokojori +{ + [Tool] + [GlobalClass] + public partial class TextureCombinerTilerLayer:TextureCombinerLayer + { + [Export] + public Texture2D texture; + + [Export] + public Vector2 start = Vector2.Zero; + + [Export] + public Vector2 end = Vector2.Zero; + + [Export] + public Vector2 fading = Vector2.Zero; + + [Export] + public bool updateTexture = true; + + TextureCombinerBuffer textureBuffer; + + public override async Task Process( TextureCombinerProcessingRect processingRect ) + { + var time = Async.StartTimer(); + + if ( updateTexture || textureBuffer == null ) + { + textureBuffer = TextureCombinerBuffer.From( texture ); + + time = await Async.WaitIfExceeded( time ); + } + + + for ( int i = 0; i < processingRect.processingWidth; i++ ) + { + for ( int j = 0; j < processingRect.processingHeight; j++ ) + { + var uv = processingRect.GetRelativeUV( i, j ); + + // uv *= tiling; + // uv += offset; + + uv = uv.PosMod( 1f ); + + var color = textureBuffer.SampleBilinearUV( uv ); + + processingRect.SetOutputRelative( i, j, color ); + } + } + + return; + } + } +} \ No newline at end of file diff --git a/Runtime/Procedural/Textures/TextureCombiner/Layers/TextureCombinerTilerLayer.cs.uid b/Runtime/Procedural/Textures/TextureCombiner/Layers/TextureCombinerTilerLayer.cs.uid new file mode 100644 index 0000000..d8a2f1f --- /dev/null +++ b/Runtime/Procedural/Textures/TextureCombiner/Layers/TextureCombinerTilerLayer.cs.uid @@ -0,0 +1 @@ +uid://ce4x5axe2rq5c diff --git a/Runtime/Rendering/SilhouetteOutlines/SilhouetteOutlineCompositer.cs b/Runtime/Rendering/SilhouetteOutlines/SilhouetteOutlineCompositer.cs new file mode 100644 index 0000000..b20015b --- /dev/null +++ b/Runtime/Rendering/SilhouetteOutlines/SilhouetteOutlineCompositer.cs @@ -0,0 +1,61 @@ + +using System.Diagnostics; +using System.Collections; +using System.Collections.Generic; +using System; +using Godot; + + +// https://github.com/jamesdimick/godot-compositor-effect-csharp-test/blob/main/TestCompositorEffect.cs +// https://github.com/txnsor/godot-datamosher/blob/main/shaders/datamosher.glsl +// https://github.com/DevPoodle/godot-compositor-outline/blob/main/outline_effect.gd + +namespace Rokojori +{ + [Tool] + [GlobalClass] + public partial class SilhouetteOutlineCompositer:CompositorEffect + { + RenderingDevice renderingDevice; + Rid frameBuffer; + + public void _Init() + { + EffectCallbackType = EffectCallbackTypeEnum.PostOpaque; + renderingDevice = RenderingServer.GetRenderingDevice(); + + } + + public override void _Notification(int what) + { + + } + + public override void _RenderCallback( int effectCallbackType, RenderData renderData ) + { + if ( renderingDevice == null || effectCallbackType != (int) EffectCallbackTypeEnum.PostOpaque ) + { + return; + } + + var renderBuffers = (RenderSceneBuffersRD) renderData.GetRenderSceneBuffers(); + + if ( renderBuffers == null ) + { + return; + } + + var size = renderBuffers.GetInternalSize(); + + if ( size.X == 0 || size.Y == 0 ) + { + return; + } + + var groups = new Vector3((size.X - 1.0f) / 8.0f + 1.0f, (size.Y - 1.0f) / 8.0f + 1.0f, 1.0f).Floor(); + + + } + } + +} \ No newline at end of file diff --git a/Runtime/Rendering/SilhouetteOutlines/SilhouetteOutlineCompositer.cs.uid b/Runtime/Rendering/SilhouetteOutlines/SilhouetteOutlineCompositer.cs.uid new file mode 100644 index 0000000..c61e815 --- /dev/null +++ b/Runtime/Rendering/SilhouetteOutlines/SilhouetteOutlineCompositer.cs.uid @@ -0,0 +1 @@ +uid://3awb3ydcy1vh diff --git a/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Middle.tres b/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Middle.tres index 1abc20c..c9ce177 100644 --- a/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Middle.tres +++ b/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Middle.tres @@ -1,10 +1,10 @@ [gd_resource type="Resource" script_class="MouseButtonSensor" load_steps=2 format=3 uid="uid://b8u374emi528p"] -[ext_resource type="Script" path="res://addons/rokojori_action_library/Runtime/Sensors/MouseButtonSensor.cs" id="1_baalg"] +[ext_resource type="Script" uid="uid://buajgl5pnktwj" path="res://addons/rokojori_action_library/Runtime/Sensors/MouseButtonSensor.cs" id="1_baalg"] [resource] script = ExtResource("1_baalg") -button = 3 +button = 2 ctrlHold = 2 altHold = 2 shiftHold = 2 diff --git a/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Right.tres b/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Right.tres index a66cdc2..a4700db 100644 --- a/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Right.tres +++ b/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Right.tres @@ -1,10 +1,10 @@ [gd_resource type="Resource" script_class="MouseButtonSensor" load_steps=2 format=3 uid="uid://cbqyav0cnehoq"] -[ext_resource type="Script" path="res://addons/rokojori_action_library/Runtime/Sensors/MouseButtonSensor.cs" id="1_4clle"] +[ext_resource type="Script" uid="uid://buajgl5pnktwj" path="res://addons/rokojori_action_library/Runtime/Sensors/MouseButtonSensor.cs" id="1_4clle"] [resource] script = ExtResource("1_4clle") -button = 2 +button = 3 ctrlHold = 2 altHold = 2 shiftHold = 2 diff --git a/Runtime/Shading/Library/Cameras.gdshaderinc b/Runtime/Shading/Library/Cameras.gdshaderinc new file mode 100644 index 0000000..8dc43c1 --- /dev/null +++ b/Runtime/Shading/Library/Cameras.gdshaderinc @@ -0,0 +1,11 @@ +bool cameraContainsLayerIndex( int layerIndex, uint _CAMERA_VISIBLE_LAYERS ) +{ + uint layer = uint( 1 << ( layerIndex - 1 ) ); + return ( _CAMERA_VISIBLE_LAYERS & layer ) == layer; +} + +bool cameraHasOnlyLayerIndex( int layerIndex, uint _CAMERA_VISIBLE_LAYERS ) +{ + uint layer = uint( 1 << ( layerIndex - 1 ) ); + return _CAMERA_VISIBLE_LAYERS == layer; +} \ No newline at end of file diff --git a/Runtime/Shading/Library/Cameras.gdshaderinc.uid b/Runtime/Shading/Library/Cameras.gdshaderinc.uid new file mode 100644 index 0000000..dfa5ab8 --- /dev/null +++ b/Runtime/Shading/Library/Cameras.gdshaderinc.uid @@ -0,0 +1 @@ +uid://dc5ehaal4lyid diff --git a/Runtime/Shading/Library/Transform.gdshaderinc b/Runtime/Shading/Library/Transform.gdshaderinc index 6624dfe..617d56c 100644 --- a/Runtime/Shading/Library/Transform.gdshaderinc +++ b/Runtime/Shading/Library/Transform.gdshaderinc @@ -31,6 +31,11 @@ vec3 localToWorldDirection( vec3 _VERTEX, mat4 _MODEL_MATRIX ) return ( mw * vec4( _VERTEX, 1.0 ) ).xyz; } +vec3 localToView( vec3 _VERTEX, mat4 _MODELVIEW_MATRIX ) +{ + return ( _MODELVIEW_MATRIX * vec4( _VERTEX, 1.0 ) ).xyz; +} + vec3 worldToLocal( vec3 _VERTEX, mat4 _MODEL_MATRIX ) { return ( inverse( _MODEL_MATRIX ) * vec4( _VERTEX, 1.0 ) ).xyz; diff --git a/Runtime/Viewports/CopyViewportSize.cs b/Runtime/Viewports/CopyViewportSize.cs new file mode 100644 index 0000000..d01b57d --- /dev/null +++ b/Runtime/Viewports/CopyViewportSize.cs @@ -0,0 +1,31 @@ + +using System.Diagnostics; +using System.Collections; +using System.Collections.Generic; +using System; +using Godot; + + +namespace Rokojori +{ + [Tool] + [GlobalClass] + public partial class CopyViewportSize:Action + { + [Export] + public SubViewport target; + + protected override void _OnTrigger() + { + var size = DisplayServer.WindowGetSize(); + + if ( target.Size == size ) + { + return; + } + + target.Size = size; + } + } + +} \ No newline at end of file diff --git a/Runtime/Viewports/CopyViewportSize.cs.uid b/Runtime/Viewports/CopyViewportSize.cs.uid new file mode 100644 index 0000000..42b96aa --- /dev/null +++ b/Runtime/Viewports/CopyViewportSize.cs.uid @@ -0,0 +1 @@ +uid://c6muxlaciyifn diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/MouseEditorCamera Default Inputs.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/MouseEditorCamera Default Inputs.tres new file mode 100644 index 0000000..007ca30 --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/MouseEditorCamera Default Inputs.tres @@ -0,0 +1,42 @@ +[gd_resource type="Resource" script_class="MouseEditorCameraInputSettings" load_steps=12 format=3 uid="uid://dgxeibp77r1wy"] + +[ext_resource type="Resource" uid="uid://o55y4n73ivh5" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Back.tres" id="1_thixm"] +[ext_resource type="Resource" uid="uid://t5no1o63fjr5" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Down.tres" id="2_jknb0"] +[ext_resource type="Resource" uid="uid://df6lrugctcuel" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Forward.tres" id="3_bmph5"] +[ext_resource type="Resource" uid="uid://csuggvbd1w2a4" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Left.tres" id="4_nn62x"] +[ext_resource type="Resource" uid="uid://c7msoe5b0k5bp" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Mouse Orbit Button.tres" id="5_thixm"] +[ext_resource type="Resource" uid="uid://cshqmy08jhmrp" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Mouse Pan Button.tres" id="6_jknb0"] +[ext_resource type="Resource" uid="uid://da2q51p05qdyy" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Right.tres" id="7_r8nl0"] +[ext_resource type="Script" uid="uid://dfihqotugioar" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCameraInputSettings.cs" id="8_thixm"] +[ext_resource type="Resource" uid="uid://4mbw74ka5aln" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Upward.tres" id="9_sydsp"] +[ext_resource type="Resource" uid="uid://b73j0lq2sqck7" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Zoom In.tres" id="10_phpwm"] +[ext_resource type="Resource" uid="uid://b3o3ht1b2llnh" path="res://addons/rokojori_action_library/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Zoom Out.tres" id="11_2c0d3"] + +[resource] +script = ExtResource("8_thixm") +yawButtonsSpeed = 1.0 +pitchButtonsSpeed = 1.0 +zoomStepInPercentage = 10.0 +zoomInButton = ExtResource("10_phpwm") +zoomInModifierButtons = [] +zoomOutButton = ExtResource("11_2c0d3") +zoomOutModifierButtons = [] +continousZoomStepInPercentage = 1.0 +forwardButton = ExtResource("3_bmph5") +backwardsButton = ExtResource("1_thixm") +leftButton = ExtResource("4_nn62x") +rightButton = ExtResource("7_r8nl0") +upButton = ExtResource("9_sydsp") +downButton = ExtResource("2_jknb0") +moveSpeed = 1.0 +mouseMovementEnabled = true +minimizeDistanceOnMovement = true +mouseMovementYawSpeed = 0.2 +mouseMovementPitchSpeed = 0.2 +mouseMovementOrbitButton = ExtResource("5_thixm") +mouseMovementOrbitModifierButtons = [] +mouseMovementPanSpeedX = 0.001 +mouseMovementPanSpeedY = 0.001 +mouseMovementPanButton = ExtResource("6_jknb0") +mouseMovementPanModifierButtons = [] +metadata/_custom_type_script = "uid://dfihqotugioar" diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Mouse Orbit Button.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Mouse Orbit Button.tres new file mode 100644 index 0000000..8de0c3f --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Mouse Orbit Button.tres @@ -0,0 +1,18 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=3 format=3 uid="uid://c7msoe5b0k5bp"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_1j1kl"] +[ext_resource type="Resource" uid="uid://b8u374emi528p" path="res://addons/rokojori_action_library/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Middle.tres" id="2_e3b12"] + +[resource] +script = ExtResource("1_1j1kl") +sensors = [ExtResource("2_e3b12")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 +metadata/_custom_type_script = "uid://eid0qnlvq4n1" diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Mouse Pan Button.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Mouse Pan Button.tres new file mode 100644 index 0000000..e9f2b2e --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Mouse Pan Button.tres @@ -0,0 +1,18 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=3 format=3 uid="uid://cshqmy08jhmrp"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_h68ww"] +[ext_resource type="Resource" uid="uid://cbqyav0cnehoq" path="res://addons/rokojori_action_library/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Button Right.tres" id="2_m8eqt"] + +[resource] +script = ExtResource("1_h68ww") +sensors = [ExtResource("2_m8eqt")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 +metadata/_custom_type_script = "uid://eid0qnlvq4n1" diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Back.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Back.tres new file mode 100644 index 0000000..d739e03 --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Back.tres @@ -0,0 +1,78 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=10 format=3 uid="uid://o55y4n73ivh5"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_ikub8"] +[ext_resource type="Script" uid="uid://bjo1usdu525m" path="res://addons/rokojori_action_library/Runtime/Sensors/KeySensor.cs" id="2_dx1wq"] +[ext_resource type="Script" uid="uid://cb81s7ud1de7h" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadAxisSensor.cs" id="3_1wc0w"] +[ext_resource type="Script" uid="uid://0ji11kv86cpk" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadButtonSensor.cs" id="4_wj7li"] + +[sub_resource type="Resource" id="Resource_jlvht"] +script = ExtResource("2_dx1wq") +key = 83 +keyLocation = 0 +ctrlHold = 2 +altHold = 2 +shiftHold = 2 +modifiersMode = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_75e6s"] +script = ExtResource("1_ikub8") +sensors = [SubResource("Resource_jlvht")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_gmj7t"] +script = ExtResource("3_1wc0w") +axis = 1 +type = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_687xx"] +script = ExtResource("4_wj7li") +button = 12 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_unhue"] +script = ExtResource("1_ikub8") +sensors = [SubResource("Resource_gmj7t"), SubResource("Resource_687xx")] +showOnlyVisibleIcons = true +numVisible = 1 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[resource] +script = ExtResource("1_ikub8") +sensors = [SubResource("Resource_75e6s"), SubResource("Resource_unhue")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Down.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Down.tres new file mode 100644 index 0000000..32e6829 --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Down.tres @@ -0,0 +1,67 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=8 format=3 uid="uid://t5no1o63fjr5"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_e8w3r"] +[ext_resource type="Script" uid="uid://bjo1usdu525m" path="res://addons/rokojori_action_library/Runtime/Sensors/KeySensor.cs" id="2_elgr4"] +[ext_resource type="Script" uid="uid://0ji11kv86cpk" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadButtonSensor.cs" id="3_pyik4"] + +[sub_resource type="Resource" id="Resource_1iwsh"] +script = ExtResource("2_elgr4") +key = 69 +keyLocation = 0 +ctrlHold = 2 +altHold = 2 +shiftHold = 2 +modifiersMode = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_jvxvp"] +script = ExtResource("1_e8w3r") +sensors = [SubResource("Resource_1iwsh")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_3ovg5"] +script = ExtResource("3_pyik4") +button = 10 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_yhdev"] +script = ExtResource("1_e8w3r") +sensors = [SubResource("Resource_3ovg5")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[resource] +script = ExtResource("1_e8w3r") +sensors = [SubResource("Resource_jvxvp"), SubResource("Resource_yhdev")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Forward.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Forward.tres new file mode 100644 index 0000000..3053b73 --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Forward.tres @@ -0,0 +1,78 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=10 format=3 uid="uid://df6lrugctcuel"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_r4ul7"] +[ext_resource type="Script" uid="uid://bjo1usdu525m" path="res://addons/rokojori_action_library/Runtime/Sensors/KeySensor.cs" id="2_rofew"] +[ext_resource type="Script" uid="uid://0ji11kv86cpk" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadButtonSensor.cs" id="3_dyhbp"] +[ext_resource type="Script" uid="uid://cb81s7ud1de7h" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadAxisSensor.cs" id="3_nh2m3"] + +[sub_resource type="Resource" id="Resource_8h6fq"] +script = ExtResource("2_rofew") +key = 87 +keyLocation = 0 +ctrlHold = 2 +altHold = 2 +shiftHold = 2 +modifiersMode = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_nj1ud"] +script = ExtResource("1_r4ul7") +sensors = [SubResource("Resource_8h6fq")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_mxixb"] +script = ExtResource("3_nh2m3") +axis = 1 +type = 1 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_c1vyq"] +script = ExtResource("3_dyhbp") +button = 11 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_vhtjx"] +script = ExtResource("1_r4ul7") +sensors = [SubResource("Resource_mxixb"), SubResource("Resource_c1vyq")] +showOnlyVisibleIcons = true +numVisible = 1 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[resource] +script = ExtResource("1_r4ul7") +sensors = [SubResource("Resource_nj1ud"), SubResource("Resource_vhtjx")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Left.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Left.tres new file mode 100644 index 0000000..08dcde1 --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Left.tres @@ -0,0 +1,78 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=10 format=3 uid="uid://csuggvbd1w2a4"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_w0cyl"] +[ext_resource type="Script" uid="uid://bjo1usdu525m" path="res://addons/rokojori_action_library/Runtime/Sensors/KeySensor.cs" id="2_umtky"] +[ext_resource type="Script" uid="uid://cb81s7ud1de7h" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadAxisSensor.cs" id="3_ushvr"] +[ext_resource type="Script" uid="uid://0ji11kv86cpk" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadButtonSensor.cs" id="4_53tr6"] + +[sub_resource type="Resource" id="Resource_jlvht"] +script = ExtResource("2_umtky") +key = 65 +keyLocation = 0 +ctrlHold = 2 +altHold = 2 +shiftHold = 2 +modifiersMode = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_qts7v"] +script = ExtResource("1_w0cyl") +sensors = [SubResource("Resource_jlvht")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_gmj7t"] +script = ExtResource("3_ushvr") +axis = 0 +type = 1 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_687xx"] +script = ExtResource("4_53tr6") +button = 13 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_0hx40"] +script = ExtResource("1_w0cyl") +sensors = [SubResource("Resource_gmj7t"), SubResource("Resource_687xx")] +showOnlyVisibleIcons = true +numVisible = 1 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[resource] +script = ExtResource("1_w0cyl") +sensors = [SubResource("Resource_qts7v"), SubResource("Resource_0hx40")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Right.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Right.tres new file mode 100644 index 0000000..0a5579a --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Right.tres @@ -0,0 +1,78 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=10 format=3 uid="uid://da2q51p05qdyy"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_vdwin"] +[ext_resource type="Script" uid="uid://bjo1usdu525m" path="res://addons/rokojori_action_library/Runtime/Sensors/KeySensor.cs" id="2_prxyq"] +[ext_resource type="Script" uid="uid://cb81s7ud1de7h" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadAxisSensor.cs" id="3_4antj"] +[ext_resource type="Script" uid="uid://0ji11kv86cpk" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadButtonSensor.cs" id="4_ucs5r"] + +[sub_resource type="Resource" id="Resource_jlvht"] +script = ExtResource("2_prxyq") +key = 68 +keyLocation = 0 +ctrlHold = 2 +altHold = 2 +shiftHold = 2 +modifiersMode = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_d1suo"] +script = ExtResource("1_vdwin") +sensors = [SubResource("Resource_jlvht")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_c7ebh"] +script = ExtResource("3_4antj") +axis = 0 +type = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_md70b"] +script = ExtResource("4_ucs5r") +button = 14 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_fhaor"] +script = ExtResource("1_vdwin") +sensors = [SubResource("Resource_c7ebh"), SubResource("Resource_md70b")] +showOnlyVisibleIcons = true +numVisible = 1 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[resource] +script = ExtResource("1_vdwin") +sensors = [SubResource("Resource_d1suo"), SubResource("Resource_fhaor")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Upward.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Upward.tres new file mode 100644 index 0000000..739c4a6 --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Move Upward.tres @@ -0,0 +1,67 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=8 format=3 uid="uid://4mbw74ka5aln"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_5263n"] +[ext_resource type="Script" uid="uid://bjo1usdu525m" path="res://addons/rokojori_action_library/Runtime/Sensors/KeySensor.cs" id="2_g8pg7"] +[ext_resource type="Script" uid="uid://0ji11kv86cpk" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadButtonSensor.cs" id="3_ejsq1"] + +[sub_resource type="Resource" id="Resource_jt01w"] +script = ExtResource("2_g8pg7") +key = 81 +keyLocation = 0 +ctrlHold = 2 +altHold = 2 +shiftHold = 2 +modifiersMode = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_pqldp"] +script = ExtResource("1_5263n") +sensors = [SubResource("Resource_jt01w")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_ivi7v"] +script = ExtResource("3_ejsq1") +button = 9 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[sub_resource type="Resource" id="Resource_0uxqa"] +script = ExtResource("1_5263n") +sensors = [SubResource("Resource_ivi7v")] +showOnlyVisibleIcons = true +numVisible = 1 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[resource] +script = ExtResource("1_5263n") +sensors = [SubResource("Resource_pqldp"), SubResource("Resource_0uxqa")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Zoom In.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Zoom In.tres new file mode 100644 index 0000000..708d1ec --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Zoom In.tres @@ -0,0 +1,28 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=5 format=3 uid="uid://b73j0lq2sqck7"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_lnrk8"] +[ext_resource type="Resource" uid="uid://chwstub7bnlpp" path="res://addons/rokojori_action_library/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Wheel Down.tres" id="2_tuiuf"] +[ext_resource type="Script" uid="uid://cb81s7ud1de7h" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadAxisSensor.cs" id="3_5t03r"] + +[sub_resource type="Resource" id="Resource_rjqry"] +script = ExtResource("3_5t03r") +axis = 5 +type = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[resource] +script = ExtResource("1_lnrk8") +sensors = [ExtResource("2_tuiuf"), SubResource("Resource_rjqry")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 diff --git a/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Zoom Out.tres b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Zoom Out.tres new file mode 100644 index 0000000..8fe0bb2 --- /dev/null +++ b/Runtime/VirtualCameras/MouseEditorCamera/Inputs/Sensors/Zoom Out.tres @@ -0,0 +1,28 @@ +[gd_resource type="Resource" script_class="CombineSensor" load_steps=5 format=3 uid="uid://b3o3ht1b2llnh"] + +[ext_resource type="Script" uid="uid://eid0qnlvq4n1" path="res://addons/rokojori_action_library/Runtime/Sensors/CombineSensor.cs" id="1_w21si"] +[ext_resource type="Resource" uid="uid://b52horrdbgyaa" path="res://addons/rokojori_action_library/Runtime/Sensors/Default-Sensors/Keyboard & Mouse/Mouse/Mouse-Wheel Up.tres" id="2_dk7mn"] +[ext_resource type="Script" uid="uid://cb81s7ud1de7h" path="res://addons/rokojori_action_library/Runtime/Sensors/GamePadAxisSensor.cs" id="3_pu70j"] + +[sub_resource type="Resource" id="Resource_aybyw"] +script = ExtResource("3_pu70j") +axis = 4 +type = 0 +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 + +[resource] +script = ExtResource("1_w21si") +sensors = [ExtResource("2_dk7mn"), SubResource("Resource_aybyw")] +showOnlyVisibleIcons = false +numVisible = 0 +inputIcons = [] +useInputIconsFromSensors = true +continous = false +_value = 0.0 +_wasActive = false +_active = false +_activeTreshold = 0.5 diff --git a/Runtime/VirtualCameras/MouseEditorCamera.cs b/Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCamera.cs similarity index 100% rename from Runtime/VirtualCameras/MouseEditorCamera.cs rename to Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCamera.cs diff --git a/Runtime/VirtualCameras/MouseEditorCamera.cs.uid b/Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCamera.cs.uid similarity index 100% rename from Runtime/VirtualCameras/MouseEditorCamera.cs.uid rename to Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCamera.cs.uid diff --git a/Runtime/VirtualCameras/MouseEditorCameraInputSettings.cs b/Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCameraInputSettings.cs similarity index 100% rename from Runtime/VirtualCameras/MouseEditorCameraInputSettings.cs rename to Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCameraInputSettings.cs diff --git a/Runtime/VirtualCameras/MouseEditorCameraInputSettings.cs.uid b/Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCameraInputSettings.cs.uid similarity index 100% rename from Runtime/VirtualCameras/MouseEditorCameraInputSettings.cs.uid rename to Runtime/VirtualCameras/MouseEditorCamera/MouseEditorCameraInputSettings.cs.uid