Skip to content

Commit b871508

Browse files
authored
Merge pull request #264 from Arthri/update
Update OTAPI and initial issue fixes
2 parents 2b81ac7 + 6370958 commit b871508

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

TerrariaServerAPI.Tests/TileGenerateTests.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@ public void Generate_Small(ICollection<ITile> provider)
2424
Main.tile = provider;
2525

2626
WorldGen.generatingWorld = true;
27-
Main.rand = new UnifiedRandom(9999);
28-
WorldGen.gen = true;
27+
Main.ActiveWorldFileData.SetSeed("seeeeeeeeeed");
28+
Main.rand = new UnifiedRandom(Main.ActiveWorldFileData.Seed);
2929
Main.menuMode = 888;
3030

3131
WorldGen.clearWorld();
3232

33-
WorldGen.GenerateWorld(9999);
33+
WorldGen.GenerateWorld();
3434
}
3535

3636
[Test]

TerrariaServerAPI/TerrariaApi.Server/Hooking/ItemHooks.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ public static void AttachTo(HookManager hookManager)
1515
{
1616
_hookManager = hookManager;
1717

18-
HookEvents.Terraria.Item.SetDefaults_Int32_Boolean_ItemVariant += OnSetDefaults;
18+
HookEvents.Terraria.Item.SetDefaults += OnSetDefaults;
1919
HookEvents.Terraria.Item.netDefaults += OnNetDefaults;
2020

2121
Hooks.Chest.QuickStack += OnQuickStack;
@@ -28,7 +28,7 @@ private static void OnNetDefaults(Item item, HookEvents.Terraria.Item.netDefault
2828
args.ContinueExecution = false;
2929
}
3030

31-
private static void OnSetDefaults(Item item, HookEvents.Terraria.Item.SetDefaults_Int32_Boolean_ItemVariantEventArgs args)
31+
private static void OnSetDefaults(Item item, HookEvents.Terraria.Item.SetDefaultsEventArgs args)
3232
{
3333
if (!args.ContinueExecution) return;
3434
if (_hookManager.InvokeItemSetDefaultsInt(ref args.Type, item, args.variant))

TerrariaServerAPI/TerrariaServerAPI.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,6 @@
2323
<ItemGroup>
2424
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
2525
<PackageReference Include="System.Diagnostics.PerformanceCounter" Version="9.0.0" />
26-
<PackageReference Include="OTAPI.Upcoming" Version="3.2.4" />
26+
<PackageReference Include="OTAPI.Upcoming" Version="3.3.5" />
2727
</ItemGroup>
2828
</Project>

0 commit comments

Comments
 (0)