Added projectile sprites

This commit is contained in:
Logan 2020-07-19 16:11:22 -05:00
parent 1a7fdfb310
commit 0a74ba1a45
21 changed files with 172 additions and 93 deletions

5
WandClass.gd Normal file
View file

@ -0,0 +1,5 @@
extends Sprite
class_name Wand
func fire(projectile, effect):

Binary file not shown.

Before

Width:  |  Height:  |  Size: 200 B

After

Width:  |  Height:  |  Size: 285 B

BIN
art/MineProjectile.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 179 B

View file

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/MineProjectile.png-04c7c0f942ff2570fe207ea05c50db50.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://art/MineProjectile.png"
dest_files=[ "res://.import/MineProjectile.png-04c7c0f942ff2570fe207ea05c50db50.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
stream=false
size_limit=0
detect_3d=false
svg/scale=1.0

BIN
art/PhantomProjectile.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 114 B

View file

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/PhantomProjectile.png-920953235b3fd826065feb9e4ceff381.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://art/PhantomProjectile.png"
dest_files=[ "res://.import/PhantomProjectile.png-920953235b3fd826065feb9e4ceff381.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
stream=false
size_limit=0
detect_3d=false
svg/scale=1.0

Binary file not shown.

Before

Width:  |  Height:  |  Size: 170 B

After

Width:  |  Height:  |  Size: 166 B

BIN
art/WaveProjectile.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 130 B

View file

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/WaveProjectile.png-c1dd38bdaf21fb47c906fd45756d877f.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://art/WaveProjectile.png"
dest_files=[ "res://.import/WaveProjectile.png-c1dd38bdaf21fb47c906fd45756d877f.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
stream=false
size_limit=0
detect_3d=false
svg/scale=1.0

BIN
art/ecoprojectile.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 160 B

View file

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/ecoprojectile.png-f2afcd9ee7a1ca96391bf5fdacb6ae71.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://art/ecoprojectile.png"
dest_files=[ "res://.import/ecoprojectile.png-f2afcd9ee7a1ca96391bf5fdacb6ae71.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
stream=false
size_limit=0
detect_3d=false
svg/scale=1.0

View file

@ -85,7 +85,7 @@ drag_margin_bottom = 0.0
script = ExtResource( 4 )
[node name="WandManager" type="Position2D" parent="."]
position = Vector2( 0, -7 )
position = Vector2( 0, -8 )
script = ExtResource( 7 )
[node name="Sprite" type="Sprite" parent="."]

View file

@ -2,7 +2,6 @@
[ext_resource path="res://art/BouncingWand.png" type="Texture" id=1]
[node name="BouncyWand" type="Sprite"]
rotation = 1.5708
texture = ExtResource( 1 )

View file

@ -3,7 +3,7 @@
[ext_resource path="res://art/Wand.png" type="Texture" id=2]
[node name="ChargedWand" type="Sprite"]
position = Vector2( 7, 0 )
position = Vector2( 9, 0 )
rotation = 1.5708
texture = ExtResource( 2 )

View file

@ -1,30 +0,0 @@
[gd_scene load_steps=5 format=2]
[ext_resource path="res://script/Projectile.gd" type="Script" id=1]
[ext_resource path="res://art/WhiteProjectile.png" type="Texture" id=2]
[sub_resource type="CircleShape2D" id=1]
radius = 4.0
[sub_resource type="Environment" id=2]
background_mode = 4
glow_enabled = true
glow_intensity = 0.25
glow_bloom = 0.15
glow_blend_mode = 0
glow_hdr_threshold = 3.29
glow_bicubic_upscale = true
[node name="WhiteProjectile" type="KinematicBody2D"]
collision_layer = 8
collision_mask = 2
script = ExtResource( 1 )
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
shape = SubResource( 1 )
[node name="WhiteProjectile" type="Sprite" parent="."]
texture = ExtResource( 2 )
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
environment = SubResource( 2 )

View file

@ -1,30 +0,0 @@
[gd_scene load_steps=5 format=2]
[ext_resource path="res://script/Projectile.gd" type="Script" id=1]
[ext_resource path="res://art/WhiteProjectile.png" type="Texture" id=2]
[sub_resource type="CircleShape2D" id=1]
radius = 4.0
[sub_resource type="Environment" id=2]
background_mode = 4
glow_enabled = true
glow_intensity = 0.25
glow_bloom = 0.15
glow_blend_mode = 0
glow_hdr_threshold = 3.29
glow_bicubic_upscale = true
[node name="WhiteProjectile" type="KinematicBody2D"]
collision_layer = 8
collision_mask = 2
script = ExtResource( 1 )
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
shape = SubResource( 1 )
[node name="WhiteProjectile" type="Sprite" parent="."]
texture = ExtResource( 2 )
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
environment = SubResource( 2 )

View file

@ -23,17 +23,23 @@ _global_script_classes=[ {
"class": "StateMachine",
"language": "GDScript",
"path": "res://script/StateMachine.gd"
}, {
"base": "Sprite",
"class": "Wand",
"language": "GDScript",
"path": "res://WandClass.gd"
} ]
_global_script_class_icons={
"Collectable": "",
"Projectile": "",
"StateMachine": ""
"StateMachine": "",
"Wand": ""
}
[application]
config/name="Gamejam"
run/main_scene="res://Title/Tilte.tscn"
run/main_scene="res://levels/test.tscn"
config/icon="res://icon.png"
[autoload]
@ -43,6 +49,10 @@ IconLoaderGithub="*res://addons/github-integration/scripts/IconLoaderGithub.gd"
RestHandler="*res://addons/github-integration/scripts/RestHandler.gd"
Globals="*res://script/globals.gd"
[debug]
settings/fps/force_fps=60
[display]
window/size/width=320
@ -78,47 +88,32 @@ texture={
"stream": false,
"svg/scale": 1.0
}
wav={
"compress/mode": 0,
"edit/loop": true,
"edit/normalize": false,
"edit/trim": false,
"force/8_bit": false,
"force/max_rate": false,
"force/max_rate_hz": 44100,
"force/mono": false
}
[input]
up={
"deadzone": 0.5,
"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":32,"unicode":0,"echo":false,"script":null)
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":87,"unicode":0,"echo":false,"script":null)
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777232,"unicode":0,"echo":false,"script":null)
]
}
down={
"deadzone": 0.5,
"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":83,"unicode":0,"echo":false,"script":null)
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777234,"unicode":0,"echo":false,"script":null)
]
}
left={
"deadzone": 0.5,
"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":65,"unicode":0,"echo":false,"script":null)
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777231,"unicode":0,"echo":false,"script":null)
]
}
right={
"deadzone": 0.5,
"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":68,"unicode":0,"echo":false,"script":null)
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777233,"unicode":0,"echo":false,"script":null)
]
}
shoot={
"deadzone": 0.5,
"events": [ Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"button_mask":0,"position":Vector2( 0, 0 ),"global_position":Vector2( 0, 0 ),"factor":1.0,"button_index":1,"pressed":false,"doubleclick":false,"script":null)
"events": [ Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"button_mask":0,"position":Vector2( 0, 0 ),"global_position":Vector2( 0, 0 ),"factor":1.0,"button_index":1,"pressed":false,"doubleclick":false,"script":null)
]
}
inventory={
@ -129,11 +124,14 @@ inventory={
[layer_names]
2d_render/layer_1="Player"
2d_physics/layer_1="Player"
2d_render/layer_2="World"
2d_physics/layer_2="World"
2d_physics/layer_3="Enemy"
2d_physics/layer_4="Projectiles"
[rendering]
quality/driver/fallback_to_gles2=true
environment/default_environment="res://default_env.tres"

View file

@ -72,21 +72,21 @@ func add_item(index):
Effect4.visible = true
func _on_Conduit1_toggled():
if Conduit1.is_visible():
if Conduit1.is_visible() and active_conduit != Globals.Magic[Globals.Conduit1]:
active_conduit = Globals.Magic[Globals.Conduit1]
parent.WandManager.set_current_conduit(active_conduit)
func _on_Conduit2_toggled():
if Conduit2.is_visible():
if Conduit2.is_visible() and active_conduit != Globals.Magic[Globals.Conduit2]:
active_conduit = Globals.Magic[Globals.Conduit2]
parent.WandManager.set_current_conduit(active_conduit)
func _on_Conduit3_toggled():
if Conduit3.is_visible():
if Conduit3.is_visible() and active_conduit != Globals.Magic[Globals.Conduit3]:
active_conduit = Globals.Magic[Globals.Conduit3]
parent.WandManager.set_current_conduit(active_conduit)
func _on_Conduit4_toggled():
if Conduit4.is_visible():
if Conduit4.is_visible() and active_conduit != Globals.Magic[Globals.Conduit4]:
active_conduit = Globals.Magic[Globals.Conduit4]
parent.WandManager.set_current_conduit(active_conduit)

View file

@ -12,7 +12,7 @@ var conduit2_ps = preload("res://magic/Wands/TripleWand.tscn")
var conduit3_ps = preload("res://magic/Wands/BouncyWand.tscn")
var conduit4_ps = preload("res://magic/Wands/PrismWand.tscn")
var projectile1_ps = preload("res://magic/projectiles/Projectile1.tscn")
var projectile1_ps
var projectile2_ps
var projectile3_ps
var projectile4_ps

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

View file

@ -54,9 +54,10 @@ texture = ExtResource( 1 )
[node name="Conduit1" type="TextureButton" parent="Inventory/Conduits"]
light_mask = -2147483647
margin_left = -80.0
margin_top = -16.0
margin_right = -66.0
margin_left = -79.0
margin_top = -17.9699
margin_right = -65.0
margin_bottom = 0.0300903
action_mode = 0
texture_normal = ExtResource( 3 )
expand = true
@ -68,9 +69,9 @@ __meta__ = {
[node name="Conduit2" type="TextureButton" parent="Inventory/Conduits"]
light_mask = -2147483647
margin_left = -58.0
margin_top = -18.0
margin_top = -19.0
margin_right = -39.0
margin_bottom = 4.0
margin_bottom = 3.0
action_mode = 0
texture_normal = ExtResource( 4 )
expand = true
@ -96,9 +97,9 @@ __meta__ = {
[node name="Conduit4" type="TextureButton" parent="Inventory/Conduits"]
light_mask = -2147483647
margin_left = -58.0
margin_top = 7.0
margin_top = 5.0
margin_right = -40.0
margin_bottom = 29.0
margin_bottom = 27.0
action_mode = 0
texture_normal = ExtResource( 6 )
expand = true