Setup melee. Add Zweichender (#34)
* Setup melee. Add Zweichender * Update base.yml * Update base.yml
@@ -113,6 +113,11 @@ public sealed partial class MeleeWeaponComponent : Component
|
||||
[ViewVariables(VVAccess.ReadWrite), DataField]
|
||||
public bool SwingLeft;
|
||||
|
||||
/// <summary>
|
||||
/// CrystallPunk Melee improvment. Allows each attack to take turns being either left or right
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public bool CPSwingBeverage = true;
|
||||
|
||||
// Sounds
|
||||
|
||||
|
||||
@@ -428,6 +428,11 @@ public abstract class SharedMeleeWeaponSystem : EntitySystem
|
||||
var attackEv = new MeleeAttackEvent(weaponUid);
|
||||
RaiseLocalEvent(user, ref attackEv);
|
||||
|
||||
//CrystallPun melee improvment
|
||||
if (weapon.CPSwingBeverage)
|
||||
weapon.SwingLeft = !weapon.SwingLeft;
|
||||
//CrystallPun melee improvment end
|
||||
|
||||
weapon.Attacking = true;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
# Simple melee weapons
|
||||
|
||||
# Battle Staff
|
||||
# Mace
|
||||
# Stick
|
||||
# Dagger
|
||||
# Spear
|
||||
# Light Hammer
|
||||
# Throwing spear
|
||||
# Hand axe
|
||||
# Sickle
|
||||
|
||||
# Military melee weapons
|
||||
|
||||
# Halberd
|
||||
# Battle pick
|
||||
# Warhammer
|
||||
# Battle axe
|
||||
# Glaive
|
||||
|
||||
- type: entity
|
||||
name: двуручный меч
|
||||
abstract: true
|
||||
parent: BaseItem
|
||||
id: CPBaseTwoHandedSword
|
||||
description: Мощное оружие, требующее огромной силы и умения для эффективного использования.
|
||||
components:
|
||||
- type: Sharp
|
||||
- type: MeleeWeapon
|
||||
attackRate: 0.75
|
||||
damage:
|
||||
types:
|
||||
Slash: 10
|
||||
Structural: 5
|
||||
soundHit:
|
||||
collection: MetalThud
|
||||
- type: Wieldable
|
||||
- type: IncreaseDamageOnWield
|
||||
damage:
|
||||
types:
|
||||
Slash: 30
|
||||
Structural: 5
|
||||
- type: Item
|
||||
size: Ginormous
|
||||
|
||||
# Long spear
|
||||
# Long sword
|
||||
# Whip
|
||||
# Short sword
|
||||
# Hammer
|
||||
# Morgenstern
|
||||
# Pika
|
||||
# Rapier
|
||||
# Axe
|
||||
# Scimitar
|
||||
# Trident
|
||||
# Chain
|
||||
@@ -0,0 +1,17 @@
|
||||
|
||||
- type: entity
|
||||
name: цвайхендер
|
||||
parent: CPBaseTwoHandedSword
|
||||
id: CPZweichender
|
||||
components:
|
||||
- type: MeleeWeapon
|
||||
wideAnimationRotation: 225
|
||||
- type: Sprite
|
||||
sprite: CrystallPunk/Objects/Weapons/Melee/zweichhender.rsi
|
||||
state: icon
|
||||
- type: Clothing
|
||||
sprite: CrystallPunk/Objects/Weapons/Melee/zweichhender.rsi
|
||||
quickEquip: false
|
||||
slots:
|
||||
- back
|
||||
#TODO двуручный хват требует перчаток чтобы не получать урона самому
|
||||
@@ -0,0 +1,14 @@
|
||||
# Simple ranged weapon
|
||||
|
||||
# Crossbow
|
||||
# Dart
|
||||
# Short bow
|
||||
# Slingshot
|
||||
|
||||
# Military ranged weapon
|
||||
|
||||
# Handheld crossbow
|
||||
# Heavy Crossbow
|
||||
# Longbow
|
||||
# Blowpipe
|
||||
# Net
|
||||
|
Before Width: | Height: | Size: 700 B After Width: | Height: | Size: 639 B |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 780 B |
|
After Width: | Height: | Size: 802 B |
|
After Width: | Height: | Size: 785 B |
@@ -0,0 +1,34 @@
|
||||
{
|
||||
"version": 1,
|
||||
"license": "CC-BY-NC-SA-3.0",
|
||||
"copyright": "Created by Hemo (Discord) for CrystallPunk",
|
||||
"size": {
|
||||
"x": 32,
|
||||
"y": 32
|
||||
},
|
||||
"states": [
|
||||
{
|
||||
"name": "icon"
|
||||
},
|
||||
{
|
||||
"name": "inhand-left",
|
||||
"directions": 4
|
||||
},
|
||||
{
|
||||
"name": "inhand-right",
|
||||
"directions": 4
|
||||
},
|
||||
{
|
||||
"name": "wielded-inhand-left",
|
||||
"directions": 4
|
||||
},
|
||||
{
|
||||
"name": "wielded-inhand-right",
|
||||
"directions": 4
|
||||
},
|
||||
{
|
||||
"name": "equipped-BACKPACK",
|
||||
"directions": 4
|
||||
}
|
||||
]
|
||||
}
|
||||
|
After Width: | Height: | Size: 586 B |
|
After Width: | Height: | Size: 598 B |