NightmareSans
Terrarian
Guys someone can help!Becouse i missing a file in .../common/Terraria/Content/Images/UI/Sort_0.xnb and im sure that i missing multiple files.
I dont know if its allowed to Upload Terraria Files in the Forum C:Guys someone can help!Becouse i missing a file in .../common/Terraria/Content/Images/UI/Sort_0.xnb and im sure that i missing multiple files.
Go to Steam - Rigthclick on Terraria - Properties - Lokal Data - Search for ErrorsI dont know if its allowed to Upload Terraria Files in the Forum C:
public override void AI()
{
Player player = Main.player[projectile.owner];
projectile.ai[1]++;
if (projectile.ai[1] >= 0)
{
NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("BossV1"));
Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0);
projectile.ai[1] = -30;
}
}
I dont know if its allowed to Upload Terraria Files in the Forum C:
Yeah i think so...(I don't know either)
You should be able to run tModLoader servers the same way you run vanilla servers.I need help! Im trying to set up a modded server but I have no idea what i'm doing! What do I do?
Update to the most recent tModLoader.Hey anyone have the bug for npc's dissapearing on tmod servers?/ know how to fix it?
Hm, that's odd. Can I see the full projectile code?I've been told how to fix modded multiplayer bosses, that being I should use a projectile to synchronize my request with the server. I'm not too sure how to do that though. I gave this a shot, but this didn't have any effect in multiplayer, though it did work in single player. I assume because NPC.SpawnOnPlayer itself has problems with server sync... Anyway, if I could get a quick hand, that would be amazing!
Code:public override void AI() { Player player = Main.player[projectile.owner]; projectile.ai[1]++; if (projectile.ai[1] >= 0) { NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("BossV1")); Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0); projectile.ai[1] = -30; } }
On an unrelated note, how difficult would it be to have an enemy run on lava?
Here's the full projectile.cs, names and all.Snip
using System;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace ThoriumMod.Projectiles.Spawn
{
public class JellyFishSpawn : ModProjectile
{
public override void SetDefaults()
{
projectile.name = "Jellyfish Spawn";
projectile.width = 6;
projectile.height = 6;
projectile.aiStyle = 1;
projectile.hostile = true;
projectile.scale = 1f;
projectile.penetrate = 1;
projectile.light = 0.5f;
projectile.timeLeft = 20;
projectile.tileCollide = false;
aiType = ProjectileID.Bullet;
}
public override void AI()
{
Player player = Main.player[projectile.owner];
projectile.ai[1]++;
if (projectile.ai[1] >= 0)
{
if(!NPC.AnyNPCs(mod.NPCType("Diverman")))
{
NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("QueenJelly"));
Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0);
}
else
{
NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("QueenJellyDiverless"));
Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0);
}
projectile.ai[1] = -30;
}
}
}
}
Hello someone can help with the tmodloader becouse i missing the files in the Content/Images folder can anyone send this files some how? I tried Every single thing i can do.
Hm, for projectiles spawning the NPC I was mostly talking about the Thunder Bird (since it looks like you need to fire the projectile anyways in order to summon it). This is still a weird problem though. Can you add some Main.NewText statements to tell whether certain pieces of code are being called? The server version of Main.NewText is:Here's the full projectile.cs, names and all.
Code:using System; using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Graphics; using Terraria; using Terraria.ID; using Terraria.ModLoader; namespace ThoriumMod.Projectiles.Spawn { public class JellyFishSpawn : ModProjectile { public override void SetDefaults() { projectile.name = "Jellyfish Spawn"; projectile.width = 6; projectile.height = 6; projectile.aiStyle = 1; projectile.hostile = true; projectile.scale = 1f; projectile.penetrate = 1; projectile.light = 0.5f; projectile.timeLeft = 20; projectile.tileCollide = false; aiType = ProjectileID.Bullet; } public override void AI() { Player player = Main.player[projectile.owner]; projectile.ai[1]++; if (projectile.ai[1] >= 0) { if(!NPC.AnyNPCs(mod.NPCType("Diverman"))) { NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("QueenJelly")); Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0); } else { NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("QueenJellyDiverless")); Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0); } projectile.ai[1] = -30; } } } }
I figured enemy lava walking wouldn't be easy, but using npc.lavaWet to decrease its Y Velocity gave me a suitable effect. Kinda like the lava slimes...
if (Main.netMode == 2)
{
NetMessage.SendData(25, -1, -1, "message", 255, 255, 255, 255);
}
Nope, with this code, no message occurs. Hopefully I just dun' goofed somewhere?Snip
using System;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace ThoriumMod.Projectiles.Spawn
{
public class JellyFishSpawn : ModProjectile
{
public override void SetDefaults()
{
projectile.name = "Jellyfish Spawn";
projectile.width = 6;
projectile.height = 6;
projectile.aiStyle = 1;
projectile.hostile = true;
projectile.scale = 1f;
projectile.penetrate = 1;
projectile.light = 0.5f;
projectile.timeLeft = 20;
projectile.tileCollide = false;
aiType = ProjectileID.Bullet;
}
public override void AI()
{
Player player = Main.player[projectile.owner];
projectile.ai[1]++;
if (projectile.ai[1] >= 0)
{
if(!NPC.AnyNPCs(mod.NPCType("Diverman")))
{
NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("QueenJelly"));
Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0);
if (Main.netMode == 2)
{
NetMessage.SendData(25, -1, -1, "Yo", 255, 255, 255, 255);
}
}
else
{
NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("QueenJellyDiverless"));
Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0);
if (Main.netMode == 2)
{
NetMessage.SendData(25, -1, -1, "Yo", 255, 255, 255, 255);
}
}
projectile.ai[1] = -30;
}
}
}
}
Hm, does any message appear when you move it directly into the "if (projectile.ai[1] >= 0)" block? Also if you just put it at the beginning of the AI?Nope, with this code, no message occurs. Hopefully I just dun' goofed somewhere?Code:using System; using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Graphics; using Terraria; using Terraria.ID; using Terraria.ModLoader; namespace ThoriumMod.Projectiles.Spawn { public class JellyFishSpawn : ModProjectile { public override void SetDefaults() { projectile.name = "Jellyfish Spawn"; projectile.width = 6; projectile.height = 6; projectile.aiStyle = 1; projectile.hostile = true; projectile.scale = 1f; projectile.penetrate = 1; projectile.light = 0.5f; projectile.timeLeft = 20; projectile.tileCollide = false; aiType = ProjectileID.Bullet; } public override void AI() { Player player = Main.player[projectile.owner]; projectile.ai[1]++; if (projectile.ai[1] >= 0) { if(!NPC.AnyNPCs(mod.NPCType("Diverman"))) { NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("QueenJelly")); Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0); if (Main.netMode == 2) { NetMessage.SendData(25, -1, -1, "Yo", 255, 255, 255, 255); } } else { NPC.SpawnOnPlayer(player.whoAmI, mod.NPCType("QueenJellyDiverless")); Main.PlaySound(15, (int)player.position.X, (int)player.position.Y, 0); if (Main.netMode == 2) { NetMessage.SendData(25, -1, -1, "Yo", 255, 255, 255, 255); } } projectile.ai[1] = -30; } } } }
Nope, both have no effect. Looks like my proj ai isn't reaching the server, right? Could aiType = ProjectileID.Bullet possibly be ignoring my attempts because it wouldn't normally do that? I doubt its that, but I don't know for sure.Hm, does any message appear when you move it directly into the "if (projectile.ai[1] >= 0)" block? Also if you just put it at the beginning of the AI?
Hm, the aiType shouldn't mess with the AI hook. And it does work on singleplayer, right?Nope, both have no effect. Looks like my proj ai isn't reaching the server, right? Could aiType = ProjectileID.Bullet possibly be ignoring my attempts because it wouldn't normally do that? I doubt its that, but I don't know for sure.
Aaaaaay, it works! Thanks as always Blue, I'm sure most of us would be lost without you.Hm, the aiType shouldn't mess with the AI hook. And it does work on singleplayer, right?
Wait a minute, is the projectile hostile? Hostile projectiles can't be sent from the client to the server, so probably the projectile just doesn't exist on the server.
Without him we whould need to use the Prism Mod Loader C:Aaaaaay, it works! Thanks as always Blue, I'm sure most of us would be lost without you.
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace Pack.NPCs
{
public class ModGlobalNPC : GlobalNPC
{
public override void NPCLoot(NPC npc)
{
if (Main.rand.Next(4) == 0 && zoneTemple)
{
Item.NewItem((int)npc.position.X, (int)npc.position.Y, npc.width, npc.height, mod.ItemType("TempliteIngot"), 3);
}
}
}
}
Maybe the problem is you haven't updated vanilla Terraria to 1.3.1.(since that is what updates the image files you are missing) Steam usually does it automatically, but maybe you are in offline mode or something.Hello someone can help with the tmodloader becouse i missing the files in the Content/Images folder can anyone send this files some how? I tried Every single thing i can do.
Well.. i found out it's done via item.backSlot and item.frontSlot in vanilla.. but it's sbyte.. so i can't really give it what i want.
EDIT: Also, my accesory uses both front and back textures (draws both).