Endershot355
Steampunker
What.
Item Antibiotics uses an old UpdateAccessory hook
at Terraria.ModLoader.Mod.AddItem(String name, ModItem item, String texture)
at Terraria.ModLoader.Mod.AutoloadItem(Type type)
at Terraria.ModLoader.Mod.Autoload()
at Terraria.ModLoader.ModLoader.do_Load(Object threadContext)
Item Antibiotics uses an old UpdateAccessory hook
at Terraria.ModLoader.Mod.AddItem(String name, ModItem item, String texture)
at Terraria.ModLoader.Mod.AutoloadItem(Type type)
at Terraria.ModLoader.Mod.Autoload()
at Terraria.ModLoader.ModLoader.do_Load(Object threadContext)
Eldrazi
Eater of Worlds
The Update accessory hook has been changed. First it was:What.
Item Antibiotics uses an old UpdateAccessory hook
at Terraria.ModLoader.Mod.AddItem(String name, ModItem item, String texture)
at Terraria.ModLoader.Mod.AutoloadItem(Type type)
at Terraria.ModLoader.Mod.Autoload()
at Terraria.ModLoader.ModLoader.do_Load(Object threadContext)
Code:
public override void UpdateAccessory(Player player)
Code:
public override void UpdateAccessory(Player player, bool hideVisual)
Iroh The Dragon
Terrarian
Okay this is my only problem now at the moment
its say that the Addmapentry doesnt exsist
using System;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using Terraria.ObjectData;
using Microsoft.Xna.Framework;
namespace DarkArmorReforged.Tiles
{
public class CobaltAnvil : ModTile
{
public override void SetDefaults()
{
Main.tileSolidTop[Type] = false;
Main.tileFrameImportant[Type] = true;
Main.tileNoAttach[Type] = true;
Main.tileLavaDeath[Type] = true;
TileObjectData.newTile.CopyFrom(TileObjectData.Style2x1);
TileObjectData.newTile.CoordinateHeights = new int[] { 16, 16, 16 };
TileObjectData.newTile.CoordinateWidth = 16;
TileObjectData.newTile.CoordinatePadding = 2;
TileObjectData.addTile(Type);
adjTiles = new int[] { TileID.Anvils };
AddToArray(ref TileID.Sets.RoomNeeds.CountsAsTorch);
AddMapEntry(new Color(255, 255, 255), "CobaltAnvil");
}
public override void KillMultiTile(int i, int j, int frameX, int frameY)
{
Item.NewItem(i * 16, j * 16, 48, 48, mod.ItemType("CobaltAnvil"));
}
}
}
its say that the Addmapentry doesnt exsist
using System;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using Terraria.ObjectData;
using Microsoft.Xna.Framework;
namespace DarkArmorReforged.Tiles
{
public class CobaltAnvil : ModTile
{
public override void SetDefaults()
{
Main.tileSolidTop[Type] = false;
Main.tileFrameImportant[Type] = true;
Main.tileNoAttach[Type] = true;
Main.tileLavaDeath[Type] = true;
TileObjectData.newTile.CopyFrom(TileObjectData.Style2x1);
TileObjectData.newTile.CoordinateHeights = new int[] { 16, 16, 16 };
TileObjectData.newTile.CoordinateWidth = 16;
TileObjectData.newTile.CoordinatePadding = 2;
TileObjectData.addTile(Type);
adjTiles = new int[] { TileID.Anvils };
AddToArray(ref TileID.Sets.RoomNeeds.CountsAsTorch);
AddMapEntry(new Color(255, 255, 255), "CobaltAnvil");
}
public override void KillMultiTile(int i, int j, int frameX, int frameY)
{
Item.NewItem(i * 16, j * 16, 48, 48, mod.ItemType("CobaltAnvil"));
}
}
}
baumpaladin
Terrarian
also someone know what mod is currently bugging ?
Framesteel
Terrarian
I did some looking around but couldn't find where I'd edit these things, any help would be appreciated.I have had that issue as well. Try fiddling around with npc.life and npc.lifeMax that solved it for me.
RunicPixels🧚🌳
Empress of Light
Change these options within theI did some looking around but couldn't find where I'd edit these things, any help would be appreciated.
public override void SetDefaults()
Framesteel
Terrarian
I wouldn't have any issue actually editing the file(s) once I find them, I just can't find themChange these options within the
public override void SetDefaults()
Sin Costan
Eye of Cthulhu
You can't change it from the tmod file itself, instead, you should probably pursuit what mod npc it is, then report it on here so the developer of the mod can see it.I wouldn't have any issue actually editing the file(s) once I find them, I just can't find them. I don't think it's the mod file itself because it's in some sort of language that Notepad++ can't work with.
Framesteel
Terrarian
He stated something that vaguely sounded like he was editing a file somewhere and found a way to fix it/work around it. The NPC's are the wolves and undead enemies in the Tremor Mod.You can't change it from the tmod file itself, instead, you should probably pursuit what mod npc it is, then report it on here so the developer of the mod can see it.
He was talking about fixing the mod he wrote.He stated something that vaguely sounded like he was editing a file somewhere and found a way to fix it/work around it. The NPC's are the wolves and undead enemies in the Tremor Mod.
imkSushi
Eater of Worlds
What is the difference between Terraria.Player.statLifeMax and Terraria.Player.statLifeMax2
Sin Costan
Eye of Cthulhu
statLifeMax is the player's actual max health while statLifeMax2 is the extra health gained from effects. Usually these two are set at the same amount, however when you want to change the players health only when a certain equipment is on for example, you use statLifeMax2, otherwise you change both of these.What is the difference between Terraria.Player.statLifeMax and Terraria.Player.statLifeMax2
imkSushi
Eater of Worlds
Thanks.statLifeMax is the player's actual max health while statLifeMax2 is the extra health gained from effects. Usually these two are set at the same amount, however when you want to change the players health only when a certain equipment is on for example, you use statLifeMax2, otherwise you change both of these.
What is a static object reference thingy an error message talks about?
Sin Costan
Eye of Cthulhu
Usually it means that a certain thing isn't "static". What the term "static" means usually refers to things like a static variable where you can use it anywhere, sometimes it gets really confusing on what the problem is, maybe show us the error message?What is a static object reference thingy an error message talks about?
imkSushi
Eater of Worlds
Usually it means that a certain thing isn't "static". What the term "static" means usually refers to things like a static variable where you can use it anywhere, sometimes it gets really confusing on what the problem is, maybe show us the error message?
Sin Costan
Eye of Cthulhu
Can I see the code too by any chance?
imkSushi
Eater of Worlds
public override void Load()
{
RegisterHotKey("________", "R");
}
public override void HotKeyPressed(string name)
{
if (name == "________")
{
Player.statLife = Player.statLifeMax;
}
}
{
RegisterHotKey("________", "R");
}
public override void HotKeyPressed(string name)
{
if (name == "________")
{
Player.statLife = Player.statLifeMax;
}
}
This means you are trying to change Player.statLife, which is an instance variable and not a static variable, so you'd need to reference the variable from an instance of the class, not the class name itself. Usually in the hooks an instance of the Player class is passed in and named player.
Edit: in your case, replace Player with Main.player[Main.myPlayer]
imkSushi
Eater of Worlds
How do I do that?This means you are trying to change Player.statLife, which is an instance variable and not a static variable, so you'd need to reference the variable from an instance of the class, not the class name itself. Usually in the hooks an instance of the Player class is passed in and named player.
Edit: in your case, replace Player with Main.player[Main.myPlayer]How do I do that?
Similar threads
- Replies
- 40
- Views
- 24K
- Replies
- 5
- Views
- 1K
- Replies
- 893
- Views
- 892K
- Sticky
- Replies
- 270
- Views
- 266K
- Locked
- Replies
- 234
- Views
- 49K
-
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.