Skip to content

Commit

Permalink
Update to 0.11.8.8
Browse files Browse the repository at this point in the history
  • Loading branch information
TheStachelfisch committed Mar 15, 2022
1 parent 182d1ef commit 13b701b
Show file tree
Hide file tree
Showing 17 changed files with 89 additions and 17 deletions.
10 changes: 5 additions & 5 deletions patches/64bit/Terraria.ModLoader.Engine/InstallVerifier.cs.patch
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,18 @@
+ steamAPIPath = "./steam_api64.dll";
- steamAPIHash = ToByteArray("7B857C897BC69313E4936DC3DCCE5193");
+ steamAPIHash = ToByteArray("8AFDE2D19C89D0BF1A9F6EC475AA0EBB".ToUpper());
gogHash = ToByteArray("6352ded8d64d0f67fdf10ff2a6f9e51f"); // Don't forget to update CheckExe in CheckGoG
steamHash = ToByteArray("201707bba92e27f09d05529e2f051c60");
gogHash = ToByteArray("0d4005c39a12a334d9bfd42dd5b656cc"); // Don't forget to update CheckExe in CheckGoG
steamHash = ToByteArray("5f321196521790a18a19d44fd066044e");
}
- else if (Platform.IsOSX) {
+ else if (PlatformUtilities.IsOSX) {
steamAPIPath = "osx/libsteam_api.dylib";
steamAPIHash = ToByteArray("4EECD26A0CDF89F90D4FF26ECAD37BE0");
gogHash = ToByteArray("7b8d96e0ef583164d565dc01be4b5627");
steamHash = ToByteArray("0b253fbe529ea3e2ac61a0658f43af94");
gogHash = ToByteArray("f483f6f795e5c045b73c330015e852a6");
steamHash = ToByteArray("c3b967ddc50f400dc1575de05979ee47");
}
- else if (Platform.IsLinux) {
+ else if (PlatformUtilities.IsLinux) {
steamAPIPath = "lib/libsteam_api.so";
steamAPIHash = ToByteArray("7B74FD4C207D22DB91B4B649A44467F6");
gogHash = ToByteArray("fa53f0a39be5698da7a15a1cc9e56689");
gogHash = ToByteArray("56794421993db33b7607d1be233b586d");
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using System;
using Terraria.DataStructures;

namespace Terraria.ModLoader.Default.Patreon
{
internal class Tantamount_Head : PatreonItem
{
public override string SetName => "Tantamount";
public override EquipType ItemEquipType => EquipType.Head;

public override void SetDefaults() {
base.SetDefaults();
item.width = 34;
item.height = 22;
}
}

// female sprite was pretty much the same and made it difficult to support, so ommitted.
internal class Tantamount_Body : PatreonItem
{
public override string SetName => "Tantamount";
public override EquipType ItemEquipType => EquipType.Body;

public override void SetDefaults() {
base.SetDefaults();
item.width = 42;
item.height = 24;
}
}

internal class Tantamount_Legs : PatreonItem
{
public override string SetName => "Tantamount";
public override EquipType ItemEquipType => EquipType.Legs;

public override void SetDefaults() {
base.SetDefaults();
item.width = 22;
item.height = 18;
}
}

internal class Tantamount_Wings : PatreonItem
{
public override string SetName => "Tantamount";
public override EquipType ItemEquipType => EquipType.Wings;

public override void SetDefaults() {
base.SetDefaults();
item.vanity = false;
item.width = 24;
item.height = 8;
item.accessory = true;
}

public override void UpdateAccessory(Player player, bool hideVisual) {
player.wingTimeMax = 150;
}
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ private void AddPatronSets() {
new PatreonItem[] { new Zeph_Head(), new Zeph_Body(), new Zeph_Legs(), new Zeph_Wings() },
new PatreonItem[] { new dschosen_Head(), new dschosen_Body(), new dschosen_Legs(), new dschosen_Wings() },
new PatreonItem[] { new AlejandroAkbal_Head(), new AlejandroAkbal_Body(), new AlejandroAkbal_Legs(), new AlejandroAkbal_Back() },
new PatreonItem[] { new Tantamount_Head(), new Tantamount_Body(), new Tantamount_Legs(), new Tantamount_Wings() },
};

foreach (var patronItem in PatronSets.SelectMany(x => x)) {
Expand Down
14 changes: 7 additions & 7 deletions patches/tModLoader/Terraria.ModLoader.Engine/InstallVerifier.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,20 +30,20 @@ static InstallVerifier()
if (Platform.IsWindows) {
steamAPIPath = "steam_api.dll";
steamAPIHash = ToByteArray("7B857C897BC69313E4936DC3DCCE5193");
gogHash = ToByteArray("6352ded8d64d0f67fdf10ff2a6f9e51f"); // Don't forget to update CheckExe in CheckGoG
steamHash = ToByteArray("201707bba92e27f09d05529e2f051c60");
gogHash = ToByteArray("0d4005c39a12a334d9bfd42dd5b656cc"); // Don't forget to update CheckExe in CheckGoG
steamHash = ToByteArray("5f321196521790a18a19d44fd066044e");
}
else if (Platform.IsOSX) {
steamAPIPath = "osx/libsteam_api.dylib";
steamAPIHash = ToByteArray("4EECD26A0CDF89F90D4FF26ECAD37BE0");
gogHash = ToByteArray("7b8d96e0ef583164d565dc01be4b5627");
steamHash = ToByteArray("0b253fbe529ea3e2ac61a0658f43af94");
gogHash = ToByteArray("f483f6f795e5c045b73c330015e852a6");
steamHash = ToByteArray("c3b967ddc50f400dc1575de05979ee47");
}
else if (Platform.IsLinux) {
steamAPIPath = "lib/libsteam_api.so";
steamAPIHash = ToByteArray("7B74FD4C207D22DB91B4B649A44467F6");
gogHash = ToByteArray("fa53f0a39be5698da7a15a1cc9e56689");
steamHash = ToByteArray("ab57cfd9076ab0c0eab9f46a412b8422");
gogHash = ToByteArray("56794421993db33b7607d1be233b586d");
steamHash = ToByteArray("b08ed3b4fe5417e7cd56e06ad99f2ab7");
}
else {
string message = Language.GetTextValue("tModLoader.UnknownVerificationOS");
Expand Down Expand Up @@ -122,7 +122,7 @@ private static bool CheckGoG()
IsGoG = true;

const string DefaultExe = "Terraria.exe";
string CheckExe = $"Terraria_1.4.3.2.exe"; // This should match the hashes. {Main.versionNumber}
string CheckExe = $"Terraria_1.4.3.6_B.exe"; // This should match the hashes. {Main.versionNumber}
string vanillaPath = File.Exists(CheckExe) ? CheckExe : DefaultExe;

// If .exe not present, check Terraria directory (Side-by-Side Manual Install)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,16 @@ private void AbortDownload(string filePath) {
}

private DownloadFile HandleResponse(WebResponse response, CancellationToken token) {
var contentLength = response.ContentLength;
bool isChunked = response.Headers["Transfer-Encoding"] == "chunked";
long contentLength = 100000000;
if (isChunked) {
string DropboxContentLengthHeader = response.Headers["X-Dropbox-Content-Length"];
if (DropboxContentLengthHeader != null)
contentLength = int.Parse(DropboxContentLengthHeader);
}
else {
contentLength = response.ContentLength;
}
if (contentLength < 0) {
var txt = $"Could not get a proper content length for DownloadFile[{DisplayText}]";
Logging.tML.Error(txt);
Expand Down
4 changes: 2 additions & 2 deletions patches/tModLoader/Terraria.ModLoader/ModContent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ private static void LoadModContent(CancellationToken token, Action<Mod> loadActi
int num = 0;
foreach (var mod in ModLoader.Mods) {
token.ThrowIfCancellationRequested();
Interface.loadMods.SetCurrentMod(num++, $"{mod.Name} v{mod.Version}");
Interface.loadMods.SetCurrentMod(num++, $"{mod.Name} ({mod.DisplayName}) v{mod.Version}");
try {
LoadingMod = mod;
loadAction(mod);
Expand Down Expand Up @@ -436,7 +436,7 @@ internal static void UnloadModContent() {
if (Main.dedServ)
Console.WriteLine($"Unloading {mod.DisplayName}...");
else
Interface.loadMods.SetCurrentMod(i++, mod.DisplayName);
Interface.loadMods.SetCurrentMod(i++, $"{mod.Name} ({mod.DisplayName}) v{mod.Version}");
mod.Close();
mod.UnloadContent();
}
Expand Down
2 changes: 1 addition & 1 deletion patches/tModLoader/Terraria.ModLoader/ModLoader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ namespace Terraria.ModLoader
/// </summary>
public static class ModLoader
{
public static readonly Version version = new Version(0, 11, 8, 6);
public static readonly Version version = new Version(0, 11, 8, 8);
// Stores the most recent version of tModLoader launched. Can be used for migration.
public static Version LastLaunchedTModLoaderVersion;
// public static bool ShowWhatsNew;
Expand Down
2 changes: 1 addition & 1 deletion patches/tModLoader/Terraria/Main.cs.patch
Original file line number Diff line number Diff line change
Expand Up @@ -3403,7 +3403,7 @@
playerDrawData.Add(value);
}
- else if (drawPlayer.head == 14 || drawPlayer.head == 56 || drawPlayer.head == 114 || drawPlayer.head == 158 || drawPlayer.head == 69 || drawPlayer.head == 180) {
+ else if (drawPlayer.head == 14 || drawPlayer.head == 56 || drawPlayer.head == 114 || drawPlayer.head == 158 || drawPlayer.head == 69 || drawPlayer.head == 180 || drawPlayer.head == ModLoader.Default.ModLoaderMod.Instance.GetEquipSlot("WitchDaggah_Head", EquipType.Head) || drawPlayer.head == ModLoader.Default.ModLoaderMod.Instance.GetEquipSlot("Elfinlocks_Head", EquipType.Head)) { // TODO: This probably needs a field or hook
+ else if (drawPlayer.head == 14 || drawPlayer.head == 56 || drawPlayer.head == 114 || drawPlayer.head == 158 || drawPlayer.head == 69 || drawPlayer.head == 180 || drawPlayer.head == ModLoader.Default.ModLoaderMod.Instance.GetEquipSlot("WitchDaggah_Head", EquipType.Head) || drawPlayer.head == ModLoader.Default.ModLoaderMod.Instance.GetEquipSlot("Elfinlocks_Head", EquipType.Head) || drawPlayer.head == ModLoader.Default.ModLoaderMod.Instance.GetEquipSlot("Tantamount_Head", EquipType.Head)) { // TODO: This probably needs a field or hook
Microsoft.Xna.Framework.Rectangle bodyFrame3 = drawPlayer.bodyFrame;
Vector2 origin2 = vector3;
if (drawPlayer.gravDir == 1f) {
Expand Down

0 comments on commit 13b701b

Please sign in to comment.