-
Notifications
You must be signed in to change notification settings - Fork 97
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
180 additions
and
0 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
package calamityofeshu | ||
|
||
import ( | ||
"github.com/genshinsim/gcsim/pkg/core" | ||
"github.com/genshinsim/gcsim/pkg/core/attacks" | ||
"github.com/genshinsim/gcsim/pkg/core/attributes" | ||
"github.com/genshinsim/gcsim/pkg/core/combat" | ||
"github.com/genshinsim/gcsim/pkg/core/info" | ||
"github.com/genshinsim/gcsim/pkg/core/keys" | ||
"github.com/genshinsim/gcsim/pkg/core/player/character" | ||
"github.com/genshinsim/gcsim/pkg/modifier" | ||
) | ||
|
||
func init() { | ||
core.RegisterWeaponFunc(keys.CalamityOfEshu, NewWeapon) | ||
} | ||
|
||
type Weapon struct { | ||
Index int | ||
} | ||
|
||
func (w *Weapon) SetIndex(idx int) { w.Index = idx } | ||
func (w *Weapon) Init() error { return nil } | ||
|
||
func NewWeapon(c *core.Core, char *character.CharWrapper, p info.WeaponProfile) (info.Weapon, error) { | ||
w := &Weapon{} | ||
r := float64(p.Refine) | ||
|
||
m := make([]float64, attributes.EndStatType) | ||
m[attributes.DmgP] = 0.15 + 0.05*r | ||
m[attributes.CR] = 0.06 + 0.02*r | ||
char.AddAttackMod(character.AttackMod{ | ||
Base: modifier.NewBase("calamityofeshu", -1), | ||
Amount: func(atk *combat.AttackEvent, t combat.Target) ([]float64, bool) { | ||
if !c.Player.Shields.CharacterIsShielded(char.Index, c.Player.Active()) { | ||
return nil, false | ||
} | ||
if atk.Info.AttackTag != attacks.AttackTagNormal && atk.Info.AttackTag != attacks.AttackTagExtra { | ||
return nil, false | ||
} | ||
return m, true | ||
}, | ||
}) | ||
|
||
return w, nil | ||
} |
25 changes: 25 additions & 0 deletions
25
internal/weapons/sword/calamityofeshu/calamityofeshu_gen.go
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package_name: calamityofeshu | ||
genshin_id: 11432 | ||
key: calamityofeshu |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
id: 11432 | ||
key: "calamityofeshu" | ||
rarity: 4 | ||
weapon_class: WEAPON_SWORD_ONE_HAND | ||
image_name: "UI_EquipIcon_Sword_SacrificialNgombe" | ||
base_stats: { | ||
base_props: { | ||
prop_type: FIGHT_PROP_BASE_ATTACK | ||
initial_value: 43.7349 | ||
curve: GROW_CURVE_ATTACK_202 | ||
} | ||
base_props: { | ||
prop_type: FIGHT_PROP_ATTACK_PERCENT | ||
initial_value: 0.06 | ||
curve: GROW_CURVE_CRITICAL_201 | ||
} | ||
promo_data: { | ||
max_level: 20 | ||
} | ||
promo_data: { | ||
max_level: 40 | ||
add_props: { | ||
prop_type: FIGHT_PROP_BASE_ATTACK | ||
value: 25.9 | ||
} | ||
} | ||
promo_data: { | ||
max_level: 50 | ||
add_props: { | ||
prop_type: FIGHT_PROP_BASE_ATTACK | ||
value: 51.9 | ||
} | ||
} | ||
promo_data: { | ||
max_level: 60 | ||
add_props: { | ||
prop_type: FIGHT_PROP_BASE_ATTACK | ||
value: 77.8 | ||
} | ||
} | ||
promo_data: { | ||
max_level: 70 | ||
add_props: { | ||
prop_type: FIGHT_PROP_BASE_ATTACK | ||
value: 103.7 | ||
} | ||
} | ||
promo_data: { | ||
max_level: 80 | ||
add_props: { | ||
prop_type: FIGHT_PROP_BASE_ATTACK | ||
value: 129.7 | ||
} | ||
} | ||
promo_data: { | ||
max_level: 90 | ||
add_props: { | ||
prop_type: FIGHT_PROP_BASE_ATTACK | ||
value: 155.6 | ||
} | ||
} | ||
} | ||
name_text_hash_map: 590019915 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
title: Calamity of Eshu | ||
--- | ||
|
||
import AoETable from "@site/src/components/AoE/AoETable"; | ||
import IssuesTable from "@site/src/components/Issues/IssuesTable"; | ||
import NamesList from "@site/src/components/Names/NamesList"; | ||
import ParamsTable from "@site/src/components/Params/ParamsTable"; | ||
import FieldsTable from "@site/src/components/Fields/FieldsTable"; | ||
|
||
## AoE Data | ||
|
||
<AoETable item_key="calamityofeshu" data_src="weapon" /> | ||
|
||
## Known issues | ||
|
||
<IssuesTable item_key="calamityofeshu" data_src="weapon" /> | ||
|
||
## Names | ||
|
||
<NamesList item_key="calamityofeshu" data_src="weapon" /> | ||
|
||
## Params | ||
|
||
<ParamsTable item_key="calamityofeshu" data_src="weapon" /> | ||
|
||
## Fields | ||
|
||
<FieldsTable item_key="calamityofeshu" data_src="weapon" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters