Skip to content
This repository was archived by the owner on Sep 3, 2022. It is now read-only.

Commit c40c71b

Browse files
committed
Even more changes
1 parent 322b525 commit c40c71b

File tree

6 files changed

+10
-11
lines changed

6 files changed

+10
-11
lines changed

Content/LeagueSandbox-Default

GameServerCore/Content/HashFunctions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ public static uint HashStringSdbm(string data)
2323
uint hash = 0;
2424
foreach (var c in data)
2525
{
26-
hash = char.ToLower(c) + 65599 * hash;
26+
hash = char.ToLowerInvariant(c) + 65599 * hash;
2727
}
2828

2929
return hash;

GameServerLib/Content/ContentManager.cs

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
1-
using System;
2-
using System.Collections.Generic;
1+
using System.Collections.Generic;
32
using System.IO;
43
using System.IO.Compression;
54
using System.Linq;
65
using IniParser.Model;
76
using LeagueSandbox.GameServer.Logging;
87
using log4net;
98
using LeagueSandbox.GameServer.Exceptions;
10-
using Newtonsoft.Json.Linq;
119

1210
namespace LeagueSandbox.GameServer.Content
1311
{
@@ -41,8 +39,8 @@ public string GetMapConfigPath(int mapId)
4139

4240
return possibilities.FirstOrDefault(path => Content.ContainsKey(path))
4341
?? throw new ContentNotFoundException(
44-
$"Map configuration for Map {mapId} was not found in the content."
45-
);
42+
$"Map configuration for Map {mapId} was not found in the content."
43+
);
4644
}
4745

4846
public string GetUnitStatPath(string model)

GameServerLib/Items/ItemData.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ public class ItemData : StatsModifier, IItemData
1818
public float SellBackModifier { get; private set; }
1919

2020
// Recipe
21-
public int[] RecipeItems { get; private set; } = new int[4];
21+
public int[] RecipeItems { get; private set; } = new int[8];
2222

2323
// Not from data
2424
public ItemRecipe Recipe { get; private set; }
@@ -107,7 +107,7 @@ public static ItemData Load(ItemManager owner, ContentFile content, int itemId)
107107
}
108108
};
109109

110-
for (var i = 0; i < 4; i++)
110+
for (var i = 0; i < 8; i++)
111111
{
112112
result.RecipeItems[i] = content.GetInt("Data", $"RecipeItem{i + 1}", -1);
113113
}

GameServerLib/Items/ItemRecipe.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,9 @@ public List<ItemData> GetItems()
4343
private void FindRecipeItems(ItemManager itemManager)
4444
{
4545
// TODO: Figure out how to refactor this.
46-
_items = new ItemData[4];
46+
_items = new ItemData[8];
4747

48-
for (var i = 0; i < 4; i++)
48+
for (var i = 0; i < 8; i++)
4949
{
5050
_items[i] = itemManager.SafeGetItemType(_owner.RecipeItems[i]);
5151
}

GameServerLib/Program.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
using System;
12
using LeagueSandbox.GameServer.Logging;
23
using log4net;
34
using LeagueSandbox.GameServer.Items;

0 commit comments

Comments
 (0)