It's Cow Game! Version 2.04!
This commit is contained in:
commit
a9e1ed9ddd
3148 changed files with 95332 additions and 0 deletions
19
Skills/XpPopups/XpPopup.gd
Normal file
19
Skills/XpPopups/XpPopup.gd
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
extends Control
|
||||
|
||||
var lifeSpan = 1
|
||||
|
||||
func _process(delta):
|
||||
global_position += Vector2(0, -32)*delta
|
||||
|
||||
lifeSpan -= delta
|
||||
if lifeSpan <= 0:
|
||||
queue_free()
|
||||
|
||||
func set_amount(amount):
|
||||
var labelText = "+"
|
||||
labelText += XpDisplayUtils.xpFormater(amount)
|
||||
labelText += " XP"
|
||||
$MarginContainer/XPLabel.text = labelText
|
||||
|
||||
func set_sprite(sprite):
|
||||
$SkillIcon.texture = sprite
|
||||
29
Skills/XpPopups/XpPopup.tscn
Normal file
29
Skills/XpPopups/XpPopup.tscn
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://crx7mmxnu1tre"]
|
||||
|
||||
[ext_resource type="Script" path="res://Skills/XpPopups/XpPopup.gd" id="1_ihtiy"]
|
||||
[ext_resource type="Texture2D" uid="uid://bmdajtat8imuu" path="res://Skills/Gardening/gardeningIcon.png" id="1_u0t71"]
|
||||
|
||||
[node name="XpPopup" type="HSplitContainer"]
|
||||
z_index = 50
|
||||
offset_left = -44.0
|
||||
offset_top = -11.0
|
||||
offset_right = 43.0
|
||||
offset_bottom = 15.0
|
||||
dragger_visibility = 2
|
||||
script = ExtResource("1_ihtiy")
|
||||
|
||||
[node name="SkillIcon" type="TextureRect" parent="."]
|
||||
layout_mode = 2
|
||||
texture = ExtResource("1_u0t71")
|
||||
expand_mode = 2
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="."]
|
||||
layout_mode = 2
|
||||
theme_override_constants/margin_left = 5
|
||||
|
||||
[node name="XPLabel" type="Label" parent="MarginContainer"]
|
||||
layout_mode = 2
|
||||
theme_override_colors/font_color = Color(0.380392, 0.976471, 0.0431373, 1)
|
||||
theme_override_colors/font_outline_color = Color(0, 0, 0, 1)
|
||||
theme_override_constants/outline_size = 8
|
||||
text = "+0.2 XP"
|
||||
Loading…
Add table
Add a link
Reference in a new issue