Merge branch 'main' of https://github.com/MarcEricMartel/MAD
This commit is contained in:
commit
eaee26025c
@ -7,14 +7,11 @@ public partial class player : Camera3D
|
||||
//private Camera3D _cam;
|
||||
[Export]
|
||||
private Label _con;
|
||||
private Vector2 _screen;
|
||||
private bool _mUp, _mDown, _mLeft, _mRight, _wIn, _wOut;
|
||||
|
||||
// Called when the node enters the scene tree for the first time.
|
||||
public override void _Ready()
|
||||
{
|
||||
//_cam = GetNode<Camera3D>(_path + "Camera3D");
|
||||
//_con = GetNode<Label>(_path + "Camera3D/Label");
|
||||
}
|
||||
|
||||
// Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
@ -23,6 +20,15 @@ public partial class player : Camera3D
|
||||
Vector3 rot = this.Rotation;
|
||||
bool zin = true, zout = true;
|
||||
|
||||
if (Input.IsActionPressed("CamNorth"))
|
||||
_mUp = true;
|
||||
if (Input.IsActionPressed("CamSouth"))
|
||||
_mDown = true;
|
||||
if (Input.IsActionPressed("CamEast"))
|
||||
_mRight = true;
|
||||
if (Input.IsActionPressed("CamWest"))
|
||||
_mLeft = true;
|
||||
|
||||
this.Rotation -= rot;
|
||||
if (this.Position.Y < 5)
|
||||
zin = false;
|
||||
@ -67,5 +73,6 @@ public partial class player : Camera3D
|
||||
else if (mousebtn.ButtonIndex == MouseButton.WheelDown)
|
||||
_wOut = true;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -24,3 +24,30 @@ window/size/mode=3
|
||||
[dotnet]
|
||||
|
||||
project/assembly_name="Mad"
|
||||
|
||||
[input]
|
||||
|
||||
CamNorth={
|
||||
"deadzone": 0.5,
|
||||
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":87,"key_label":0,"unicode":0,"echo":false,"script":null)
|
||||
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194320,"key_label":0,"unicode":0,"echo":false,"script":null)
|
||||
]
|
||||
}
|
||||
CamSouth={
|
||||
"deadzone": 0.5,
|
||||
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":83,"key_label":0,"unicode":115,"echo":false,"script":null)
|
||||
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194322,"key_label":0,"unicode":0,"echo":false,"script":null)
|
||||
]
|
||||
}
|
||||
CamWest={
|
||||
"deadzone": 0.5,
|
||||
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":65,"key_label":0,"unicode":97,"echo":false,"script":null)
|
||||
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194319,"key_label":0,"unicode":0,"echo":false,"script":null)
|
||||
]
|
||||
}
|
||||
CamEast={
|
||||
"deadzone": 0.5,
|
||||
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":68,"key_label":0,"unicode":100,"echo":false,"script":null)
|
||||
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194321,"key_label":0,"unicode":0,"echo":false,"script":null)
|
||||
]
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user