mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2025-04-14 14:04:38 -04:00
Added a getHeroStats function stub.
This commit is contained in:
parent
6efcbc5ead
commit
dc48cab6d1
1 changed files with 25 additions and 0 deletions
|
@ -304,6 +304,31 @@ module.exports = class ThangType extends CocoModel
|
|||
return [heroClass] if heroClass = @get 'heroClass'
|
||||
['Warrior', 'Ranger', 'Wizard']
|
||||
|
||||
getHeroStats: ->
|
||||
return unless heroClass = @get('heroClass')
|
||||
|
||||
return switch heroClass
|
||||
when 'Warrior' then {
|
||||
attack: 0.8
|
||||
health: 0.85
|
||||
speed: 0.6
|
||||
skills: []
|
||||
}
|
||||
|
||||
when 'Ranger' then {
|
||||
attack: 0.6
|
||||
health: 0.7
|
||||
speed: 0.8
|
||||
skills: []
|
||||
}
|
||||
|
||||
when 'Wizard' then {
|
||||
attack: 0.5
|
||||
health: 0.45
|
||||
speed: 0.25
|
||||
skills: []
|
||||
}
|
||||
|
||||
getFrontFacingStats: ->
|
||||
components = @get('components') or []
|
||||
unless itemConfig = _.find(components, original: LevelComponent.ItemID)?.config
|
||||
|
|
Loading…
Add table
Reference in a new issue