forked from team-sg/hero-mark-2
initial android export experiments
This commit is contained in:
parent
a2b9da421a
commit
8452ebce66
30 changed files with 755 additions and 1 deletions
14
autoloads/touch_controls.gd
Normal file
14
autoloads/touch_controls.gd
Normal file
|
@ -0,0 +1,14 @@
|
|||
extends CanvasLayer
|
||||
|
||||
export var opacity = 0.5
|
||||
|
||||
func _ready():
|
||||
if !OS.has_feature("mobile"):
|
||||
visible = false
|
||||
$CanvasModulate.color = Color(1.0, 1.0, 1.0, opacity)
|
||||
_reposition()
|
||||
get_tree().connect("screen_resized", self, "_reposition")
|
||||
|
||||
func _reposition():
|
||||
$Directions.position = Vector2(0.0, get_viewport().size.y)
|
||||
$Actions.position = get_viewport().size
|
Loading…
Add table
Add a link
Reference in a new issue