Standalone [1.3] tModLoader - A Modding API

jopojelly

Retinazer
tModLoader
22/12/2015 16:38:14
System.DllNotFoundException: Unable to load DLL 'CSteamworks': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
at Steamworks.NativeMethods.SteamAPI_RestartAppIfNecessary(AppId_t unOwnAppID)
at Terraria.Social.Steam.CoreSocialModule.Initialize()
at Terraria.Social.SocialAPI.Initialize(Nullable`1 mode)
at Terraria.Program.LaunchGame(String[] args)
got that when i opened the new terraria
Do you have the steam version of Terraria?

I downloaded the Example Mod, and put the files in the folders as directed, but when I try to compile it, I get this error:

error CS0006: Metadata file 'TerrariaMac.exe' could not be found

the strange thing is... I'm running on linux! (through crossover)
What is happening???
-Doom24

I'm not sure how crossover works, so that complicates helping find your problem. Did you click the setup mod environment button? Did you try just downloading a compiled mod from the browser?
 

Gyku

Duke Fishron
Do you have the steam version of Terraria?



I'm not sure how crossover works, so that complicates helping find your problem. Did you click the setup mod environment button? Did you try just downloading a compiled mod from the browser?
i dont want a mod i want my normal terraria
 

jopojelly

Retinazer
tModLoader
to unistalle it and open vanilla terraria
Ok, you don't need to uninstall to open vanilla, you can just open the Terraria_v1.3.0.8.exe in the install folder (should be in C:\Program Files (x86)\Steam\steamapps\common\terraria)

If you want to uninstall, either run the installer again and click the uninstall button, or replace Terraria.exe with the Terraria_v1.3.0.8.exe
 

blushiemagic

Retinazer
tModLoader
22/12/2015 16:38:14
System.DllNotFoundException: Unable to load DLL 'CSteamworks': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
at Steamworks.NativeMethods.SteamAPI_RestartAppIfNecessary(AppId_t unOwnAppID)
at Terraria.Social.Steam.CoreSocialModule.Initialize()
at Terraria.Social.SocialAPI.Initialize(Nullable`1 mode)
at Terraria.Program.LaunchGame(String[] args)
got that when i opened the new terraria
Just to make sure, you're running the exe from your Terraria's Steam folder, right?

I downloaded the Example Mod, and put the files in the folders as directed, but when I try to compile it, I get this error:

error CS0006: Metadata file 'TerrariaMac.exe' could not be found

the strange thing is... I'm running on linux! (through crossover)
What is happening???
-Doom24
You made sure to install the Linux version of tModLoader, right?

How do you do a rainbow rarity item?
Or an amber rarity one?
The rainbow "rarity" isn't actually a rarity. Just set item.expert to true.
 

raptor722

Terrarian
I have problem : the laser i was doind is good but the animation is wierd because the little dusts i created are randomly rotated so it look like explosions of red dots what should i do
 

wch

Terrarian
Code:
        public override void SetDefaults()
        {
            npc.name = "Guard";
            npc.townNPC = true;
            npc.friendly = true;
            npc.width = 18;
            npc.height = 40;
            npc.aiStyle = 7;
            npc.damage = 10;
            npc.defense = 45;
            npc.lifeMax = 250;
            npc.soundHit = 1;
            npc.soundKilled = 1;
            npc.knockBackResist = 0.5f;
            Main.npcFrameCount[npc.type] = 26;
            NPCID.Sets.ExtraFramesCount[npc.type] = 9;
            NPCID.Sets.AttackFrameCount[npc.type] = 4;
            NPCID.Sets.DangerDetectRange[npc.type] = 200;
            NPCID.Sets.AttackType[npc.type] = 3;
            NPCID.Sets.AttackTime[npc.type] = 20;
            NPCID.Sets.AttackAverageChance[npc.type] = 30;
            animationType = NPCID.Guide;
        }

        public override void DrawTownAttackSwing(ref Texture2D item, ref int itemSize, ref float scale, ref Vector2 offset)
        {
            scale = 1f;
            item = Main.itemTexture[ItemID.IronBroadsword];
            itemSize = 36;
            offset.X = 10;
        }

        public override void TownNPCAttackSwing(ref int itemWidth, ref int itemHeight)
        {
            itemWidth = 36;
            itemHeight = 36;
        }
Well, I'm making this NPC "Guard". Anyways, it is a melee-attack-type NPC. So I set its attack type to 3, and add the texture, size whatever.
But its attacking behavior looks super wired. What's wrong? Maybe I should set it like the Dye Trader, but it seems that I can't find the codes.

NOTE: By this "behavior", I mean there are some problems with its attacking texture, but not the AI. The sword are being swinged with a very odd looking. No idea whether you guys will misunderstand my ambiguous words, so make it more detailed.
 

wch

Terrarian
So now first ignore my guard issues, let me focus on some projectiles.
I'm trying to make myself a kind of bullet, maybe some sorta Purification Bullet, I guess.
Basically it will create a purification powder when it hits tiles.
I do it like this, in OnTileCollide hook:
Code:
            Projectile.NewProjectile(projectile.position.X, projectile.position.Y, projectile.velocity.X, projectile.velocity.Y, 10, (int)((double)projectile.damage * 0.1), 0f, projectile.owner, ProjectileID.PurificationPowder);
It works fine both on damage and purifiaction function, but there is still something wrong with the projectile. When the purification powder reaches the end, it will stay there and keep doing damage for up to 20 times. I guess this may have something to do with the timeLeft of the projectile, maybe the lasting time of purification is longer than the usual. So, how can I change lating time of a New Projectile? Or just how should I fix this?
By the way, upon this function, is it possible to adjust the purification range? The purification range seems to have nothing to do with the actual projectile.
 
Top Bottom