Git Product home page Git Product logo

moonstones's People

Contributors

beetrootmonkey avatar

Stargazers

Name avatar  avatar

Watchers

James Cloos avatar  avatar  avatar  avatar

Forkers

yangfu1000

moonstones's Issues

Some modifiers won't get applied to moonstones

Some modifiers (or maybe completely at random?) won't get applied to moonstones when awakening them, thus yielding a 'Moonstone (Weapons/Accessories)" without any prefix. When applied to an item, it will do nothing (except take away any modifier), which leads me to believe there wasn't any modifier on the moonstone to begin with.

Config missing

I didn't implement a way to configure the mod yet (= the drop rate of moonstones). Suppose I should find out how to read from a config file.

The Weapons moonstone will be unable to roll Legendary, Unreal, or Mythical.

Hello, again Beetrootmonkey,

Since I edited the mod the first time I encountered a few more problems.

As you may know, Terraria will not let you apply a modifier if the item does not have the respective stats like if you don't have a damage value on the item that is more than 5 you will not be able to get Legendary.

I found a solution.

In the MoonstoneWeapon.cs you should add the following lines inside the curly brackets of SetDefaults()

item.damage = 5;
item.knockBack = 5;
item.mana = 5;

If you make the item have a damage, knockback, and mana value, it will let it have modifiers that edit those values.

Terraria cant apply legendary to an item with less than 5 damage. It also can't apply a mana cost modifier to an item with less than 5 mana. Knockback at 5 is just for consistency.

This will let you get every weapon modifier on the weapons moonstone...

It will let accessory mods on it as well, so I suggest you add these lines inside the curly brackets of ChoosePrefix(UnifiedRandom rand)

byte roll = (byte)rand.Next(1, 83) >= 3 ? (byte)rand.Next(1, 61) : (byte)rand.Next(81, 84);
return roll;

It will exclude the accessory modifiers and still allow all the weapon ones.

As always I would prefer if I was given recognition for the code...

Thank you for your time,

Yangfu1000, The Shy Coder

Thorium incompatibility

The game crashes when I mouse over weapon moonstones with Thorium loaded. I went through some troubleshooting and it was the only mod in my list of ~45 that does this.
I wish I could help out further, but I've hardly gotten into modding.
image

Multiplayer only gives accessory moonstones

Hi Beetrootmonkey,

I was doing a modded multiplayer playthrough with some friends. I noticed that every single time anyone clicked the dormant moonstone, it would always give an accessory. So, a full stack of dormant moonstones later, there was not a singular weapon moonstone...

I'm also a coder, so I downloaded the mod files and did some debugging. I don't know if this is a mistake in the API or the mod but I found a solution to fix the bug.

In line 31 of MoonstoneBlank.cs I changed it to

if (Main.rand.Next(2) == 1)

instead of

if (Main.rand.Next(1) != 0)

That was the only change I found was needed.
I tested the edited code with another full stack of dormant moonstones just to see if it was a 50 50 chance to get a weapon or accessory. It seemed to be successful having about a 50 50 chance give or take a few.

I have not used this in Singleplayer, but I just wanted to let you know and give a suggestion how to fix it.

In the event that you accept my suggestion, I hope that it helps and possibly give me recognition?

Sincerely,

Yangfu1000- The Shy Coder

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.