Skip to content

Commit

Permalink
Merge branch 'dev' into code-cleanup
Browse files Browse the repository at this point in the history
# Conflicts:
#	SmartHunter/bin/x64/Debug/SmartHunter.exe
  • Loading branch information
sir-wilhelm committed Jan 30, 2020
2 parents ee0b1c0 + 3b984e1 commit 6cd611f
Show file tree
Hide file tree
Showing 14 changed files with 254 additions and 102 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ A complete overlay for Monster Hunter: World on PC. Distributed on [Nexus Mods](

- Download `SmartHunter.exe` and `Newtonsoft.Json.dll` from here https://github.com/gabrielefilipp/SmartHunter/tree/master/SmartHunter/bin/x64/Debug.
- Place them in a new folder.
- IMPORTANT: If you are replacing the new `.exe` in the same folder of the old SmartHunter please REMEMBER to delete `Config.json`.
- IMPORTANT: If you are replacing the new `.exe` in the same folder of the old SmartHunter please just follow the instructions `## How to update`.
- You're ready for the hunt.

## How to use
Expand Down
7 changes: 6 additions & 1 deletion SmartHunter.sln
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.29613.14
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SmartHunter", "SmartHunter\SmartHunter.csproj", "{F5F99CEF-1C16-48E6-A88B-1A66D3B53998}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SmartHunter", "SmartHunter\SmartHunter.csproj", "{F5F99CEF-1C16-48E6-A88B-1A66D3B53998}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{2A20B067-F085-4EB5-8667-7E708ACE5755}"
ProjectSection(SolutionItems) = preProject
.editorconfig = .editorconfig
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Expand Down
28 changes: 28 additions & 0 deletions SmartHunter/Game/Config/LocalizationConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ public class LocalizationConfig
{ "LOC_PART_LEGS_ICE", "Legs Ice" },
{ "LOC_PART_TAIL_ICE", "Tail Ice" },

{ "LOC_PART_HEAD_ROCK", "Head Rock" },
{ "LOC_PART_NECK_LEFT_ROCK", "Left Neck Rock" },
{ "LOC_PART_NECK_RIGHT_ROCK", "Right Right Rock" },
{ "LOC_PART_TAIL_ROCK", "Tail Rock" },
Expand Down Expand Up @@ -162,9 +163,13 @@ public class LocalizationConfig
{ "LOC_STATUS_EFFECT_MOUNT", "Mount" },
{ "LOC_STATUS_EFFECT_EXHAUST", "Exhaust" },
{ "LOC_STATUS_EFFECT_STUN", "Stun" },
{ "LOC_STATUS_EFFECT_KO", "KO" },
{ "LOC_STATUS_EFFECT_TRANQUILIZE", "Tranquilize" },
{ "LOC_STATUS_EFFECT_FLASH", "Flash" },
{ "LOC_STATUS_EFFECT_DUNG", "Dung" },
{ "LOC_STATUS_EFFECT_KNOW_DOWN", "Kown Down" },
{ "LOC_STATUS_EFFECT_SMOKING", "Smoking" },
{ "LOC_STATUS_EFFECT_VIOLATED", "Violated" },

//To test monster parts
{ "LOC_PART_0", "0" },
Expand All @@ -183,6 +188,26 @@ public class LocalizationConfig
{ "LOC_PART_13", "13" },
{ "LOC_PART_14", "14" },
{ "LOC_PART_15", "15" },
{ "LOC_PART_16", "16" },
{ "LOC_PART_17", "17" },
{ "LOC_PART_18", "18" },
{ "LOC_PART_19", "19" },
{ "LOC_PART_20", "20" },
{ "LOC_PART_21", "21" },
{ "LOC_PART_22", "22" },
{ "LOC_PART_23", "23" },
{ "LOC_PART_24", "24" },
{ "LOC_PART_25", "25" },
{ "LOC_PART_26", "26" },
{ "LOC_PART_27", "27" },
{ "LOC_PART_28", "28" },
{ "LOC_PART_29", "29" },
{ "LOC_PART_30", "30" },
{ "LOC_PART_31", "31" },
{ "LOC_PART_32", "32" },

//statuses
{ "LOC_STATUS_0", "Status 0" },

// Hunting Horn
{ "LOC_STATUS_EFFECT_SELF_IMPROVEMENT", "Self-improvement" },
Expand Down Expand Up @@ -309,8 +334,10 @@ public class LocalizationConfig

{ "LOC_EQUIPMENT_ASSASSINS_HOOD", "Assassin's Hood" },
{ "LOC_MONSTER_LESHEN", "Leshen" },
{ "LOC_MONSTER_ANCIENT_LESHEN", "Ancient Leshen" },
{ "LOC_REMOVABLE_PART_ANTLER_LEFT", "Removable Left Antler" },
{ "LOC_REMOVABLE_PART_ANTLER_RIGHT", "Removable Right Antler" },
{ "LOC_JAGRAS_SUMMONER", "Jagras Summoner" },

{ "LOC_STATUS_EFFECT_RAGE", "Rage" },
{ "LOC_STATUS_EFFECT_STAMINA", "Stamina" },
Expand All @@ -319,6 +346,7 @@ public class LocalizationConfig

public LocalizationConfig()
{

}
}
}
14 changes: 3 additions & 11 deletions SmartHunter/Game/Config/MemoryConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,24 +28,16 @@ public class MemoryConfig
public BytePatternConfig MonsterPattern = new BytePatternConfig(
"MonsterPattern",
/*"48 8B 05 ?? ?? ?? ?? 8B 48 ?? 89 8F ?? ?? ?? ??",*/
"48 8b 0d ?? ?? ?? ?? B2 01 E8 ?? ?? ?? ?? C6 83 ?? ?? ?? ?? ?? 48 8b 0d",
"140000000",
"163B0A000",
WindowsApi.RegionPageProtection.PAGE_READONLY
);

public BytePatternConfig MonsterOffsetPattern = new BytePatternConfig(
"MonsterOffsetPattern",
/*"48 8B 8B ?? ?? ?? ?? 48 8B 01 FF 50 ?? 48 8B 8B ?? ?? ?? ?? E8 ?? ?? ?? ?? 48 8B 8B ?? ?? ?? ?? B2 01 E8 ?? ?? ?? ??",*/
"48 8B 8B ?? ?? ?? ?? 48 89 4A ?? 48 89 42 ?? 4C 8D 9C 24",
"48 8B 0D ?? ?? ?? ?? B2 01 E8 ?? ?? ?? ?? C6 83 ?? ?? ?? ?? ?? 48 8B 0D",
"140000000",
"163B0A000",
WindowsApi.RegionPageProtection.PAGE_READONLY
);

public BytePatternConfig PlayerBuffPattern = new BytePatternConfig(
"PlayerBuffPattern",
"48 8B 05 ?? ?? ?? ?? 41 8B 94 00 ?? ?? ?? ?? 89 51 ??",
//"48 8B 05 ?? ?? ?? ?? 41 8B 94 00 ?? ?? ?? ?? 89 51 ??",
"48 8B 05 ?? ?? ?? ?? 41 8B 94 00 ?? ?? ?? ?? 89 57 ??",
"140000000",
"163B0A000",
WindowsApi.RegionPageProtection.PAGE_READONLY
Expand Down
4 changes: 3 additions & 1 deletion SmartHunter/Game/Config/MonsterConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ public class MonsterConfig
public float BaseSize;
public float ScaleModifier = 1f;
public MonsterCrownConfig Crowns;
public bool isElder = false;

public MonsterConfig(string nameStringId, MonsterPartConfig[] parts, float baseSize, float scaleModifier, MonsterCrownConfig crowns)
public MonsterConfig(string nameStringId, MonsterPartConfig[] parts, float baseSize, float scaleModifier, MonsterCrownConfig crowns, bool elder = false)
{
NameStringId = nameStringId;
//Parts = parts;
Expand All @@ -32,6 +33,7 @@ public MonsterConfig(string nameStringId, MonsterPartConfig[] parts, float baseS
BaseSize = baseSize;
ScaleModifier = scaleModifier;
Crowns = crowns;
isElder = elder;
}
}
}
114 changes: 96 additions & 18 deletions SmartHunter/Game/Config/MonsterDataConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_LEGS")
},
536.26f, 1f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand Down Expand Up @@ -213,7 +214,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_WINGS")
},
1913.13f, 0.85f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand All @@ -230,7 +232,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL")
},
1828.69f, 0.85f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand All @@ -247,7 +250,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL")
},
1790.15f, 0.85f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{
Expand Down Expand Up @@ -590,7 +594,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL")
},
1848.12f, 1f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand All @@ -611,7 +616,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL")
},
1848.12f, 1f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand All @@ -632,7 +638,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL")
},
4509.1f, 1f,
null
null,
true
)
},
{ // true
Expand All @@ -657,7 +664,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_WEAK_SHELL_RIGHT")
},
25764.59f, 1f,
null
null,
true
)
},
{ // true
Expand Down Expand Up @@ -882,7 +890,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_WINGS")
},
2095.4f, 0.9f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand All @@ -902,7 +911,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_WINGS")
},
2095.4f, 0.9f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand Down Expand Up @@ -946,7 +956,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL_RIGHT_GOLD")
},
4573.25f, 1f,
null
null,
true
)
},
{ // true
Expand Down Expand Up @@ -1014,7 +1025,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL")
},
3423.65f, 1f,
null
null,
true
)
},
{ // true
Expand Down Expand Up @@ -1071,7 +1083,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL_ICE")
},
2596.05f, 0.85f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand All @@ -1088,7 +1101,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_WINGS")
},
2048.25f, 1f,
new MonsterCrownConfig(CrownPreset.Standard)
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
Expand All @@ -1114,7 +1128,8 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_TAIL")
},
2910.91f, 1f,
new MonsterCrownConfig(CrownPreset.Alternate)
new MonsterCrownConfig(CrownPreset.Alternate),
true
)
},
{ // true
Expand All @@ -1127,14 +1142,38 @@ public class MonsterDataConfig
new MonsterPartConfig("Part", "LOC_PART_HEAD"),
new MonsterPartConfig("Part", "LOC_PART_BODY"),
new MonsterPartConfig("Part", "LOC_PART_LEGS"),
new MonsterPartConfig("Part", "LOC_PART_ARMS")
new MonsterPartConfig("Part", "LOC_PART_ARMS"),
new MonsterPartConfig("Part", "LOC_4"),
new MonsterPartConfig("Part", "LOC_5"),
new MonsterPartConfig("Part", "LOC_JAGRAS_SUMMONER")
},
549.70f, 1f,
null
new MonsterCrownConfig(CrownPreset.Standard),
true
)
},
{ // true
"em127_01",
new MonsterConfig("LOC_MONSTER_ANCIENT_LESHEN",
new MonsterPartConfig[]
{
new MonsterPartConfig("Removable", "LOC_REMOVABLE_PART_ANTLER_LEFT", true),
new MonsterPartConfig("Removable", "LOC_REMOVABLE_PART_ANTLER_RIGHT", true),
new MonsterPartConfig("Part", "LOC_PART_HEAD"),
new MonsterPartConfig("Part", "LOC_PART_BODY"),
new MonsterPartConfig("Part", "LOC_PART_LEGS"),
new MonsterPartConfig("Part", "LOC_PART_ARMS"),
new MonsterPartConfig("Part", "LOC_4"),
new MonsterPartConfig("Part", "LOC_5"),
new MonsterPartConfig("Part", "LOC_JAGRAS_SUMMONER")
},
633.81f, 1f,
new MonsterCrownConfig(CrownPreset.Standard),
true
)
}
};

/*
public MonsterStatusEffectConfig[] StatusEffects =
{
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_POISON", "08", "15C", "178", "17C", "1A4", "1A8"),
Expand All @@ -1146,12 +1185,51 @@ public class MonsterDataConfig
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_STUN", "38", "15C", "178", "17C", "1A4", "1A8"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_TRANQUILIZE", "40", "15C", "178", "17C", "1A4", "1A8"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_FLASH", "48", "15C", "178", "17C", "1A4", "1A8"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_KNOW_DOWN", "48", "15C", "178", "17C", "1A4", "1A8"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_DUNG", "58", "15C", "178", "17C", "1A4", "1A8"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_SHOCK_TRAP", "68", "15C", "178", "17C", "1A4", "1A8"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_PITFALL_TRAP", "70", "15C", "178", "17C", "1A4", "1A8"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_ELDERSEAL", "88", "15C", "178", "17C", "1A4", "1A8"),
new MonsterStatusEffectConfig("Rage", "LOC_STATUS_EFFECT_RAGE", null, "190", "180", "1A0", "18C", "198"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_FATIGUE", null, "42C", "420", "424", "430", null, true)
};
*/

public MonsterStatusEffectConfig[] StatusEffects =
{
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_0"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_POISON"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_PARALYSIS"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_SLEEP"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_BLAST"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_MOUNT"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_EXHAUST"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_STUN"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_TRANQUILIZE"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_FLASH"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_10"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_KNOW_DOWN"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_12"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_13"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_SHOCK_TRAP"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_PITFALL_TRAP"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_16"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_17"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_ELDERSEAL"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_SMOKING"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_20"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_21"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_22"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_STATUS_EFFECT_VIOLATED"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_24"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_25"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_26"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_27"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_28"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_29"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_30"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_31"),
new MonsterStatusEffectConfig("StatusEffect", "LOC_PART_32")
};
}
}
Loading

0 comments on commit 6cd611f

Please sign in to comment.