-
Notifications
You must be signed in to change notification settings - Fork 3
/
PokeWorld.cs
23 lines (20 loc) · 1020 Bytes
/
PokeWorld.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
using PokeModBlue.Items.Weapons;
using Terraria;
using Terraria.ModLoader;
namespace PokeModBlue {
public class PokeWorld : ModWorld {
public PokemonWeapon pokemon;
// used to debug what information the server knows, essentially nothing, only the item owner actually saves and loads the stats of the item
// so there is no central authoritative server for item information, so I cannot ask the server to tell everyone the stats of the pokemon, and only the server is allowed to send info
public override void PostUpdate() {
if (Main.netMode == 2) {
for (int i = 0; i < Main.player.Length - 1; i++) {
if (Main.player[i] != null) {
pokemon = Main.player[i].inventory[Main.player[i].selectedItem].modItem as PokemonWeapon;
ErrorLogger.Log(Main.player[i].name + " " + pokemon.ToString() + " " + pokemon.item.toolTip);
}
}
}
}
}
}