Skills system (#247)

* init basic skill system

* add skill requirement to advanced melee weapon

* working hard

* more hard work

* shot skill issue

* Now the skills give you the components

* add job special autolearning skills

* traits recreating

* some tweaks

* remove bg and components for now

* sharpening now require skills

* add alchemist role on maps

* pestle skill issue
This commit is contained in:
Ed
2024-06-15 16:55:04 +03:00
committed by GitHub
parent 39bb249eb3
commit c5a8e96dca
39 changed files with 937 additions and 239 deletions

View File

@@ -1,8 +1,8 @@
- type: traitCategory
id: Disabilities
name: trait-category-disabilities
- type: traitCategory
id: SpeechTraits
name: trait-category-speech
maxTraitPoints: 2
#- type: traitCategory
# id: Disabilities
# name: trait-category-disabilities
#
#- type: traitCategory
# id: SpeechTraits
# name: trait-category-speech
# maxTraitPoints: 2

View File

@@ -1,91 +1,92 @@
- type: trait
id: Blindness
name: trait-blindness-name
description: trait-blindness-desc
traitGear: WhiteCane
category: Disabilities
whitelist:
components:
- Blindable
components:
- type: PermanentBlindness
- type: trait
id: PoorVision
name: trait-poor-vision-name
description: trait-poor-vision-desc
traitGear: ClothingEyesGlasses
category: Disabilities
whitelist:
components:
- Blindable
components:
- type: PermanentBlindness
blindness: 4
- type: trait
id: Narcolepsy
name: trait-narcolepsy-name
description: trait-narcolepsy-desc
category: Disabilities
components:
- type: Narcolepsy
timeBetweenIncidents: 300, 600
durationOfIncident: 10, 30
- type: trait
id: Pacifist
name: trait-pacifist-name
description: trait-pacifist-desc
category: Disabilities
components:
- type: Pacified
- type: trait
id: Unrevivable
name: trait-unrevivable-name
description: trait-unrevivable-desc
category: Disabilities
components:
- type: Unrevivable
- type: trait
id: Muted
name: trait-muted-name
description: trait-muted-desc
category: Disabilities
blacklist:
components:
- BorgChassis
components:
- type: Muted
- type: trait
id: LightweightDrunk
name: trait-lightweight-name
description: trait-lightweight-desc
category: Disabilities
components:
- type: LightweightDrunk
boozeStrengthMultiplier: 2
- type: trait
id: Paracusia
name: trait-paracusia-name
description: trait-paracusia-desc
category: Disabilities
components:
- type: Paracusia
minTimeBetweenIncidents: 0.1
maxTimeBetweenIncidents: 300
maxSoundDistance: 7
sounds:
collection: Paracusia
- type: trait
id: Snoring
name: trait-snoring-name
description: trait-snoring-desc
category: Disabilities
components:
- type: Snoring
#- type: trait
# id: Blindness
# name: trait-blindness-name
# description: trait-blindness-desc
# traitGear: WhiteCane
# category: Disabilities
# whitelist:
# components:
# - Blindable
# components:
# - type: PermanentBlindness
#
#- type: trait
# id: PoorVision
# name: trait-poor-vision-name
# description: trait-poor-vision-desc
# traitGear: ClothingEyesGlasses
# category: Disabilities
# whitelist:
# components:
# - Blindable
# components:
# - type: PermanentBlindness
# blindness: 4
#
#- type: trait
# id: Narcolepsy
# name: trait-narcolepsy-name
# description: trait-narcolepsy-desc
# category: Disabilities
# components:
# - type: Narcolepsy
# timeBetweenIncidents: 300, 600
# durationOfIncident: 10, 30
#
#- type: trait
# id: Pacifist
# name: trait-pacifist-name
# description: trait-pacifist-desc
# category: Disabilities
# components:
# - type: Pacified
#
#- type: trait
# id: Unrevivable
# name: trait-unrevivable-name
# description: trait-unrevivable-desc
# category: Disabilities
# components:
# - type: Unrevivable
#
#- type: trait
# id: Muted
# name: trait-muted-name
# description: trait-muted-desc
# category: Disabilities
# blacklist:
# components:
# - BorgChassis
# components:
# - type: Muted
#
#- type: trait
# id: LightweightDrunk
# name: trait-lightweight-name
# description: trait-lightweight-desc
# category: Disabilities
# components:
# - type: LightweightDrunk
# boozeStrengthMultiplier: 2
#
#- type: trait
# id: Paracusia
# name: trait-paracusia-name
# description: trait-paracusia-desc
# category: Disabilities
# components:
# - type: Paracusia
# minTimeBetweenIncidents: 0.1
# maxTimeBetweenIncidents: 300
# maxSoundDistance: 7
# sounds:
# collection: Paracusia
#
#- type: trait
# id: Snoring
# name: trait-snoring-name
# description: trait-snoring-desc
# category: Disabilities
# components:
# - type: Snoring
#

View File

@@ -1,88 +1,89 @@
# Free
- type: trait
id: Accentless
name: trait-accentless-name
description: trait-accentless-desc
category: SpeechTraits
components:
- type: Accentless
removes:
- type: LizardAccent
- type: MothAccent
- type: ReplacementAccent
accent: dwarf
# 1 Cost
- type: trait
id: SouthernAccent
name: trait-southern-name
description: trait-southern-desc
category: SpeechTraits
cost: 1
components:
- type: SouthernAccent
- type: trait
id: PirateAccent
name: trait-pirate-accent-name
description: trait-pirate-accent-desc
category: SpeechTraits
cost: 1
components:
- type: PirateAccent
- type: trait
id: CowboyAccent
name: trait-cowboy-name
description: trait-cowboy-desc
category: SpeechTraits
cost: 1
components:
- type: ReplacementAccent
accent: cowboy
- type: trait
id: ItalianAccent
name: trait-italian-name
description: trait-italian-desc
category: SpeechTraits
cost: 1
components:
- type: ReplacementAccent
accent: italian
- type: trait
id: Liar
name: trait-liar-name
description: trait-liar-desc
category: SpeechTraits
cost: 1
components:
- type: ReplacementAccent
accent: liar
# 2 Cost
- type: trait
id: SocialAnxiety
name: trait-socialanxiety-name
description: trait-socialanxiety-desc
category: SpeechTraits
cost: 2
components:
- type: StutteringAccent
matchRandomProb: 0.1
fourRandomProb: 0
threeRandomProb: 0
cutRandomProb: 0
- type: trait
id: FrontalLisp
name: trait-frontal-lisp-name
description: trait-frontal-lisp-desc
category: SpeechTraits
cost: 2
components:
- type: FrontalLisp
## Free
#
#- type: trait
# id: Accentless
# name: trait-accentless-name
# description: trait-accentless-desc
# category: SpeechTraits
# components:
# - type: Accentless
# removes:
# - type: LizardAccent
# - type: MothAccent
# - type: ReplacementAccent
# accent: dwarf
#
## 1 Cost
#
#- type: trait
# id: SouthernAccent
# name: trait-southern-name
# description: trait-southern-desc
# category: SpeechTraits
# cost: 1
# components:
# - type: SouthernAccent
#
#- type: trait
# id: PirateAccent
# name: trait-pirate-accent-name
# description: trait-pirate-accent-desc
# category: SpeechTraits
# cost: 1
# components:
# - type: PirateAccent
#
#- type: trait
# id: CowboyAccent
# name: trait-cowboy-name
# description: trait-cowboy-desc
# category: SpeechTraits
# cost: 1
# components:
# - type: ReplacementAccent
# accent: cowboy
#
#- type: trait
# id: ItalianAccent
# name: trait-italian-name
# description: trait-italian-desc
# category: SpeechTraits
# cost: 1
# components:
# - type: ReplacementAccent
# accent: italian
#
#- type: trait
# id: Liar
# name: trait-liar-name
# description: trait-liar-desc
# category: SpeechTraits
# cost: 1
# components:
# - type: ReplacementAccent
# accent: liar
#
## 2 Cost
#
#- type: trait
# id: SocialAnxiety
# name: trait-socialanxiety-name
# description: trait-socialanxiety-desc
# category: SpeechTraits
# cost: 2
# components:
# - type: StutteringAccent
# matchRandomProb: 0.1
# fourRandomProb: 0
# threeRandomProb: 0
# cutRandomProb: 0
#
#- type: trait
# id: FrontalLisp
# name: trait-frontal-lisp-name
# description: trait-frontal-lisp-desc
# category: SpeechTraits
# cost: 2
# components:
# - type: FrontalLisp
#

View File

@@ -7,6 +7,20 @@
components:
- type: SpawnPoint
job_id: CP14Adventurer
- type: Sprite
layers:
- state: green
- state: zookeeper #TODO Replace
- type: entity
id: CP14SpawnPointAlchemist
parent: SpawnPointJobBase
name: alchemist
categories:
- Spawner
components:
- type: SpawnPoint
job_id: CP14Alchemist
- type: Sprite
layers:
- state: green

View File

@@ -291,6 +291,7 @@
Asphyxiation: -1.0
- type: FireVisuals
alternateState: Standing #TODO - custom visuals
- type: CP14SkillsStorage
- type: entity
save: false

View File

@@ -84,6 +84,10 @@
sprite: _CP14/Objects/Specific/Alchemy/mortar_pestle.rsi
state: pestle
- type: CP14Pestle
- type: CP14SkillRequirement
fuckupChance: 0.05
requiredSkills:
- Alchemy
- type: entity
id: CP14Mortar

View File

@@ -24,4 +24,9 @@
- !type:DoActsBehavior
acts: ["Destruction"]
- type: CP14SharpeningStone
sharpnessHeal: 0.1
sharpnessHeal: 0.1
- type: CP14SkillRequirement
fuckupChance: 0.6
requiredSkills:
- Warcraft
- Blacksmith

View File

@@ -43,4 +43,8 @@
- type: HeldSpeedModifier
- type: MeleeThrowOnHit
lifetime: 0.05
speed: 5
speed: 5
- type: CP14SkillRequirement
fuckupChance: 0.5
requiredSkills:
- Warcraft

View File

@@ -43,4 +43,8 @@
- type: ClothingSpeedModifier
walkModifier: 0.9
sprintModifier: 0.8
- type: HeldSpeedModifier
- type: HeldSpeedModifier
- type: CP14SkillRequirement
fuckupChance: 0.5
requiredSkills:
- Warcraft

View File

@@ -18,4 +18,8 @@
whitelist:
tags:
- SpeedLoaderRifle
proto: CartridgeRifle # TODO custom projectiles
proto: CartridgeRifle # TODO custom projectiles
- type: CP14SkillRequirement
fuckupChance: 0.55
requiredSkills:
- Firearms

View File

@@ -26,6 +26,10 @@
proto: CP14CartridgeBulletRifle
- type: UseDelay
delay: 2
- type: CP14SkillRequirement
fuckupChance: 0.85
requiredSkills:
- Firearms
- type: entity
name: crush

View File

@@ -42,4 +42,9 @@
sharpnessHeal: 0.1
targetDamage:
types:
blunt: 0.5
blunt: 0.5
- type: CP14SkillRequirement
fuckupChance: 0.5
requiredSkills:
- Warcraft
- Blacksmith

View File

@@ -33,3 +33,4 @@
- type: StationJobs
availableJobs:
CP14Adventurer: [ -1, -1 ]
CP14Alchemist: [ -1, -1 ]

View File

@@ -6,6 +6,10 @@
startingGear: CP14AdventurerGear
icon: "CP14JobIconAdventurer"
supervisors: cp14-job-supervisors-command
special:
- !type:CP14AddSkillSpecial
skills:
- Warcraft
- type: job
id: CP14Alchemist
@@ -15,6 +19,10 @@
startingGear: CP14AdventurerGear #TODO
icon: "CP14JobIconAlchemist"
supervisors: cp14-job-supervisors-command
special:
- !type:CP14AddSkillSpecial
skills:
- Alchemy
- type: startingGear
id: CP14AdventurerGear

View File

@@ -0,0 +1,19 @@
- type: CP14Skill
id: Alchemy
name: cp14-skill-name-alchemy
desc: cp14-skill-desc-alchemy
- type: CP14Skill
id: Blacksmith
name: cp14-skill-name-blacksmith
desc: cp14-skill-desc-blacksmith
- type: CP14Skill
id: Warcraft
name: cp14-skill-name-warcraft
desc: cp14-skill-desc-warcraft
- type: CP14Skill
id: Firearms
name: cp14-skill-name-firearms
desc: cp14-skill-desc-firearms

View File

@@ -0,0 +1,21 @@
#- type: trait
# id: CP14BackgroundSoldier
# name: cp14-trait-bg-soldier-name
# description: cp14-trait-bg-soldier-desc
# traitGear: CP14BaseTwoHandedSword
# cost: 1
# category: CP14Background
# components:
# - type: CP14AutoAddSkill
# skills:
# - Warcraft
#
#- type: trait
# id: CP14BackgroundEntertainer
# name: cp14-trait-bg-entertainer-name
# description: cp14-trait-bg-entertainer-desc
# traitGear: AcousticGuitarInstrument
# cost: 1
# category: CP14Background
# components:
# - type: CP14AutoAddSkill

View File

@@ -0,0 +1,14 @@
- type: traitCategory
id: CP14PhysicalTraits
name: cp14-trait-category-physical
maxTraitPoints: 1
- type: traitCategory
id: CP14Background
name: cp14-trait-category-background
maxTraitPoints: 1
- type: traitCategory
id: CP14Speech
name: cp14-trait-category-speech
maxTraitPoints: 2

View File

@@ -0,0 +1,62 @@
# -2
- type: trait
id: CP14Blindness
name: cp14-trait-blindness-name
description: cp14-trait-blindness-desc
#traitGear: WhiteCane
category: CP14PhysicalTraits
cost: -2
whitelist:
components:
- Blindable
components:
- type: PermanentBlindness
# -1
- type: trait
id: CP14PoorVision
name: cp14-trait-poor-vision-name
description: cp14-trait-poor-vision-desc
#traitGear: ClothingEyesGlasses
category: CP14PhysicalTraits
cost: -1
whitelist:
components:
- Blindable
components:
- type: PermanentBlindness
blindness: 4
- type: trait
id: CP14Narcolepsy
name: cp14-trait-narcolepsy-name
description: cp14-trait-narcolepsy-desc
category: CP14PhysicalTraits
cost: -1
components:
- type: Narcolepsy
timeBetweenIncidents: 300, 600
durationOfIncident: 10, 30
- type: trait
id: CP14Muted
name: cp14-trait-muted-name
description: cp14-trait-muted-desc
cost: -1
category: CP14PhysicalTraits
components:
- type: Muted
# 0
- type: trait
id: CP14Snoring
name: cp14-trait-snoring-name
description: cp14-trait-snoring-desc
category: CP14PhysicalTraits
components:
- type: Snoring
# 1