.
This commit is contained in:
parent
e5d3a862e1
commit
daaadb62ca
7 changed files with 142 additions and 0 deletions
37
CameraMove.gd
Normal file
37
CameraMove.gd
Normal file
|
|
@ -0,0 +1,37 @@
|
|||
extends Camera2D
|
||||
|
||||
|
||||
# Called when the node enters the scene tree for the first time.
|
||||
func _ready() -> void:
|
||||
pass
|
||||
|
||||
|
||||
|
||||
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
func _process(delta: float) -> void:
|
||||
var mouse: = get_viewport().get_mouse_position()
|
||||
var size: = get_viewport().get_visible_rect().size
|
||||
if (mouse.x < (0.10*size.x)):
|
||||
position.x -= 3
|
||||
elif (mouse.x > (0.90*size.x)):
|
||||
position.x += 3
|
||||
|
||||
if (mouse.y < (0.10*size.y)):
|
||||
position.y -= 3
|
||||
elif (mouse.y > (0.90*size.y)):
|
||||
position.y += 3
|
||||
|
||||
func _input(event):
|
||||
if event is InputEventMouseButton:
|
||||
if event.button_index == MOUSE_BUTTON_WHEEL_UP and event.pressed:
|
||||
|
||||
zoom.x +=1
|
||||
zoom.y +=1
|
||||
|
||||
elif event.button_index == MOUSE_BUTTON_WHEEL_DOWN and event.pressed:
|
||||
|
||||
zoom.x -=1
|
||||
zoom.y -=1
|
||||
|
||||
|
||||
|
||||
1
CameraMove.gd.uid
Normal file
1
CameraMove.gd.uid
Normal file
|
|
@ -0,0 +1 @@
|
|||
uid://ws5ruc64db3v
|
||||
BIN
Map/EHAP_map.png
(Stored with Git LFS)
Normal file
BIN
Map/EHAP_map.png
(Stored with Git LFS)
Normal file
Binary file not shown.
40
Map/EHAP_map.png.import
Normal file
40
Map/EHAP_map.png.import
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://bntb4uxiugjq3"
|
||||
path="res://.godot/imported/EHAP_map.png-b029a0a0b09d67741377398e7d614575.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Map/EHAP_map.png"
|
||||
dest_files=["res://.godot/imported/EHAP_map.png-b029a0a0b09d67741377398e7d614575.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
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/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
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
|
||||
BIN
currency/EHAP_map.png
(Stored with Git LFS)
Normal file
BIN
currency/EHAP_map.png
(Stored with Git LFS)
Normal file
Binary file not shown.
40
currency/EHAP_map.png.import
Normal file
40
currency/EHAP_map.png.import
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://8lqq14trnf5u"
|
||||
path="res://.godot/imported/EHAP_map.png-b1025cc065bdc97d744b65efd6468a03.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://currency/EHAP_map.png"
|
||||
dest_files=["res://.godot/imported/EHAP_map.png-b1025cc065bdc97d744b65efd6468a03.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
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/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
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
|
||||
18
map.tscn
Normal file
18
map.tscn
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
[gd_scene format=3 uid="uid://bdk1r2u8clllr"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://bntb4uxiugjq3" path="res://Map/EHAP_map.png" id="1_c7s6e"]
|
||||
[ext_resource type="Script" uid="uid://ws5ruc64db3v" path="res://CameraMove.gd" id="2_wijl4"]
|
||||
|
||||
[node name="Node2D" type="Node2D" unique_id=575553336]
|
||||
|
||||
[node name="EhapMap" type="Sprite2D" parent="." unique_id=26962123]
|
||||
position = Vector2(966, -28)
|
||||
texture = ExtResource("1_c7s6e")
|
||||
|
||||
[node name="Camera2D" type="Camera2D" parent="." unique_id=1974259721]
|
||||
position = Vector2(582, 1260)
|
||||
limit_left = 6
|
||||
limit_top = -1648
|
||||
limit_right = 1926
|
||||
limit_bottom = 1592
|
||||
script = ExtResource("2_wijl4")
|
||||
Loading…
Add table
Reference in a new issue