Skip to content

Commit

Permalink
Merge branch 'master' into hunter_strikeResetFix
Browse files Browse the repository at this point in the history
  • Loading branch information
ncberman authored Jan 12, 2025
2 parents b59ff6b + ad5e73a commit 6a71c78
Show file tree
Hide file tree
Showing 44 changed files with 1,281 additions and 256 deletions.
Binary file modified assets/database/db.bin
Binary file not shown.
126 changes: 63 additions & 63 deletions assets/database/db.json

Large diffs are not rendered by default.

Binary file modified assets/database/leftover_db.bin
Binary file not shown.
4 changes: 2 additions & 2 deletions assets/database/leftover_db.json
Original file line number Diff line number Diff line change
Expand Up @@ -1488,8 +1488,8 @@
{"effectId":63,"spellId":13538,"name":"Enchant Chest - Lesser Absorption","type":5,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":66,"spellId":7457,"name":"Enchant Bracer - Minor Stamina","type":6,"stats":[0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":66,"spellId":7863,"name":"Enchant Boots - Minor Stamina","type":10,"stats":[0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":241,"spellId":13503,"name":"Enchant Weapon - Lesser Striking","type":13,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":241,"spellId":7745,"name":"Enchant 2H Weapon - Minor Impact","type":13,"enchantType":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":241,"spellId":13503,"name":"Enchant Weapon - Lesser Striking","type":13,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":242,"spellId":7748,"name":"Enchant Chest - Lesser Health","type":5,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,15,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":243,"spellId":7766,"name":"Enchant Bracer - Minor Spirit","type":6,"stats":[0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":2},
{"effectId":246,"spellId":7776,"name":"Enchant Chest - Lesser Mana","type":5,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":2},
Expand Down Expand Up @@ -1564,8 +1564,8 @@
{"effectId":929,"itemId":16217,"spellId":20017,"name":"Enchant Shield - Greater Stamina","type":13,"enchantType":2,"stats":[0,0,7,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":930,"spellId":13947,"name":"Enchant Gloves - Riding Skill","type":7,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":2},
{"effectId":931,"spellId":13948,"name":"Enchant Gloves - Minor Haste","type":7,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":943,"spellId":13693,"name":"Enchant Weapon - Striking","type":13,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":943,"spellId":13529,"name":"Enchant 2H Weapon - Lesser Impact","type":13,"enchantType":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":943,"spellId":13693,"name":"Enchant Weapon - Striking","type":13,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":963,"spellId":13937,"name":"Enchant 2H Weapon - Greater Impact","type":13,"enchantType":1,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":1},
{"effectId":1483,"itemId":11622,"spellId":15340,"name":"Lesser Arcanum of Rumination","type":1,"extraTypes":[9],"enchantType":3,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,150,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"quality":2},
{"effectId":1503,"itemId":11642,"spellId":15389,"name":"Lesser Arcanum of Constitution","type":1,"extraTypes":[9],"enchantType":3,"stats":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,100,0,0,0,0,0,0,0,0,0],"quality":2},
Expand Down
120 changes: 92 additions & 28 deletions assets/db_inputs/atlasloot_db.json

Large diffs are not rendered by default.

15 changes: 9 additions & 6 deletions proto/common.proto
Original file line number Diff line number Diff line change
Expand Up @@ -127,15 +127,16 @@ enum Stat {
// between the UI and backend.
//
// It's also OK to include things here which aren't in the PseudoStats struct.
// NextIndex: 32
// NextIndex: 34
enum PseudoStat {
PseudoStatMainHandDps = 0;
PseudoStatOffHandDps = 1;
PseudoStatRangedDps = 2;
PseudoStatBlockValueMultiplier = 3;
PseudoStatDodge = 4;
PseudoStatParry = 5;
BonusPhysicalDamage = 31;
PseudoStatDodge = 4 [deprecated = true];
PseudoStatParry = 5 [deprecated = true];
PseudoStatBonusPhysicalDamage = 31;
PseudoStatThornsDamage = 32;

// Melee Weapon Skill
PseudoStatUnarmedSkill = 6;
Expand Down Expand Up @@ -170,7 +171,8 @@ enum PseudoStat {
PseudoStatBlockValuePerStrength = 29;

// Special Pseudostats
TimewornBonus = 30;
PseudoStatTimewornBonus = 30;
PseudoStatSanctifiedBonus = 33;
}

message UnitStats {
Expand Down Expand Up @@ -941,7 +943,7 @@ message SimDatabase {
}

// Contains only the Item info needed by the sim.
// NextIndex: 21
// NextIndex: 22
message SimItem {
int32 id = 1;
int32 requires_level = 16;
Expand All @@ -966,6 +968,7 @@ message SimItem {
repeated double weapon_skills = 15;

bool timeworn = 19;
bool sanctified = 21;
}

// Extra enum for describing which items are eligible for an enchant, when
Expand Down
3 changes: 2 additions & 1 deletion proto/ui.proto
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ message UIFaction {
// Contains all information about an Item needed by the UI.
// Generally this will include everything needed by the sim, plus some
// additional data for displaying / filtering.
// NextIndex: 32
// NextIndex: 33
message UIItem {
int32 id = 1;
string name = 2;
Expand Down Expand Up @@ -73,6 +73,7 @@ message UIItem {
bool unique = 19;
bool heroic = 20;
bool timeworn = 30;
bool sanctified = 32;

// Classes that are allowed to use the item. Empty indicates no special class restrictions.
repeated Class class_allowlist = 21;
Expand Down
30 changes: 20 additions & 10 deletions sim/common/sod/enchant_effects.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,21 @@ func init() {
})

// Sharpened Chitin Armor Kit
// Permanently cause an item worn on the chest, legs, hands or feet to cause 20 Nature damage to the attacker when struck in combat.
// Only usable on items level 45 and above.
core.NewEnchantEffect(7649, func(agent core.Agent) {
character := agent.GetCharacter()
actionID := core.ActionID{SpellID: 1213833}
actionID := core.ActionID{ItemID: 233803}

damage := 20.0
numEnchants := 0
for _, item := range character.Equipment {
if item.Enchant.EffectID == 7649 {
numEnchants++
}
}

character.PseudoStats.ThornsDamage += damage * float64(numEnchants)

procSpell := character.RegisterSpell(core.SpellConfig{
ActionID: actionID,
Expand All @@ -102,22 +114,20 @@ func init() {
ThreatMultiplier: 1,

ApplyEffects: func(sim *core.Simulation, target *core.Unit, spell *core.Spell) {
spell.CalcAndDealDamage(sim, target, 20, spell.OutcomeMagicHit)
spell.CalcAndDealDamage(sim, target, damage, spell.OutcomeMagicHit)
},
})

character.GetOrRegisterAura(core.Aura{
Label: "Thorns +20",
Duration: core.NeverExpires,
OnReset: func(aura *core.Aura, sim *core.Simulation) {
aura.Activate(sim)
},
core.MakePermanent(character.GetOrRegisterAura(core.Aura{
Label: "Thorns +20",
OnSpellHitTaken: func(aura *core.Aura, sim *core.Simulation, spell *core.Spell, result *core.SpellResult) {
if result.Landed() && spell.ProcMask.Matches(core.ProcMaskMelee) {
procSpell.Cast(sim, spell.Unit)
for i := 0; i < numEnchants; i++ {
procSpell.Cast(sim, spell.Unit)
}
}
},
})
}))
})

// Obsidian Scope
Expand Down
Loading

0 comments on commit 6a71c78

Please sign in to comment.