player.direction. 1 = right, -1 = left.Hello! Simple question:
Does anyone know how to check when the player is facing right or left?
I've tried using player.direction, but I can't figure out what it returns.
Thanks in advance!
Do you have any mods installed and enabled?I've been working on trying to get this fixed but I'm not having luck.
Uninstalled, deleted Terraria folder, reinstalled.
Game played unmodded.
Installed Tmodloader - game crashes when I try to open start my world.
This is the error bellow and game crash.
After this initial error and crash, the game will lock after the Terraria flash screen, requiring a system reboot.
View attachment 269175
That's really odd, what version are you using? 32 of 64 bit ?System.MissingMethodException: Method not found: 'Void.Relogic.OSPlatform.SetWindowUniformCode.(Microsoft.Xna.Framework.
GameWindow, System.String)
at Terraria.main.SetTitle0
at Terraria.main.Initialize0
at Microsoft.Xna.Framework.Game.RunGame(Boolean
useBlockingRun)
at Terraria.Program.LaunchGame(String[] args, Boolean monoArgs)
any time i open it up, it says this. Any help? I've tried to delete all the files, and reinstall them, nothing. all my files that i deleted were there. I really want to play 1.4 when it comes out.
Verifying integrity of game files didn't work.
In NPCLoot, simply check Main.LocalPlayer.life < Main.LocalPlayer.lifeMax * 0.5f or somethingHow do i make it so an enemy can drop an item only if the player's health is under 50%?
i'm using 64 bit. I removed the main program (the boreal tree logo) and it didn't work. Brought it back again and only the 64 bit version works...That's really odd, what version are you using? 32 of 64 bit ?
and the loading screen takes forever so that's why i got rid of it.i'm using 64 bit. I removed the main program (the boreal tree logo) and it didn't work. Brought it back again and only the 64 bit version works...
I heard things before of the 64 bit install bricking the 32 bit install, you may have to do some investigating therei'm using 64 bit. I removed the main program (the boreal tree logo) and it didn't work. Brought it back again and only the 64 bit version works...
nevermind, i fixed it and im so happyI heard things before of the 64 bit install bricking the 32 bit install, you may have to do some investigating there
It works, thanksIn NPCLoot, simply check Main.LocalPlayer.life < Main.LocalPlayer.lifeMax * 0.5f or something
namespace YourModName but in the photo it's YourModnamecan you help? (it is to do with my custom dust)
error CS1001: Identifier expected warnings
CODE:
using System;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ModLoader;
namespace YourModName.Dust
{
public class DustName : ModDust
{
public override void onSpawn(Dust dust)
{
dust.color = new Color(80, 244, 255);
dust.alpha = 1;
dust.scale = 1.3f;
dust.velocity = 1.4f;
dust.noGravity = true;
dust.noLight = false;
}
public override bool Update(Dust dust)
{
dust.position += dust.velocity;
dust.rotation += dust.velocity.X * 0.15f;
dust.scale *= 0.99f;
float light = 0.35f * dust.scale;
Lighting.AddLight(dust.position, light, light, light);
if (dust.scale < 0.5f)
{
dust.active = false;
}
}
}
}