Weapon/Armor Randomization

I thought you said it wasn't working all together, not just not working with Aftermath! I already a snippet for compatibility there on uh... page 2.

It goes W/A, Aftermath, Fix

module BattleManager def self.gain_drop_items drops = [] $game_troop.make_drop_items.each do |item| if RANDOM_ENEMY_DROPS if item.is_a?(RPG::Weapon) item = $game_party.add_weapon(item.id, 1) elsif item.is_a?(RPG::Armor) item = $game_party.add_armor(item.id, 1) else $game_party.gain_item(item, 1) end else $game_party.gain_item(item, 1) end drops.push(item) end SceneManager.scene.show_victory_spoils($game_troop.gold_total, drops) set_victory_text(@victory_actor, :drops) wait_for_message endendAs for the other thing, that came with the update earlier today. There's an option (false by default (at least now it is)) that makes the event commands trigger a popup.
Awesome. Thank you so much! I suppose sometime I should read all scripts I use and figure out what edits what. DO you know if there is a wiki or something that has all the ACE system/core stuff? Like Game.Events (or w/e it is)

Keep up the good work, and thank you again!
I'm unaware of any such wiki 🙁
Sorry to bother you again with this script but only 1 last time! (I hope)

Can you explain in detail what this does:

#If true, then weapons and armors dropped by enemies will be randomized

RANDOM_ENEMY_DROPS = true

Because I'm not too sure. I have tried making it do it randomly. But I thin I misunderstood what this line actually does.
It makes the drops from battle (weapons,armors,items) get affixes when they drop if applicable. Set it to true, even if using Aftermath + Fix.
Ah, so in this case with the extra drops no matter how many weapons/armors/items I put in there it will all be able to roll its respective affixes?
Hypothetically!
Thanks for the Icon update, you are hella diligent!
I just had a thought about how I would like prefixes and suffixes to work.

Say I have a prefix of these:

Bronze

Diamond

Legendary

suffix:

+1

+2

+3

I would only want the Bronze to have a +1, the diamond to be able to roll +1 and +2 and the Legendary to roll all three of the suffixes. Is this possible to do? I could go into more detail about what I'd like to do, but the system I'm working on is not quite finished yet and I only need to know if this is possible before I even attempt what I'm trying to do.
As it stands, that wouldn't be quite possible to do.
For the minus stats, features! 21 is paramaters, for example: [21,2,0.5] would half the players attack! (Not as desired however.. I'll have to look into -stats)


Whee, okay. When rarity pool is true, each affix is given the same number of tickets into the hat as the rarity in the notetags, and then one ticket is pulled from the hat and that's the affix, it gives them all a chance. With it false, it goes through the list of affixes and the first one that passes the random number under 100 test wins. If you wanted to make it rarer to get legendaries I'd say keep rarity pool off and make a sandwich: Bronze 50, Diamond 25, Legendary 1, Bronze 100. The sandwich is just so you don't get an unaffixed item. That example has a <0.5% of getting a Legendary. And it gets worse as you add more affixes.


Element Rate is elemental resist, Atk Element is for elemental damage.


Element Rate is set up like: [11, element_id, float] or (using element 2 as an example, and as a resist) [11, 2, 0.5] #Half damage!


Atk Element is even easier: (Again element 2) [31,2,0] #Done!
For the minus stats, features! 21 is paramaters, for example: [21,2,0.5] would half the players attack! (Not as desired however.. I'll have to look into -stats)

Whee, okay. When rarity pool is true, each affix is given the same number of tickets into the hat as the rarity in the notetags, and then one ticket is pulled from the hat and that's the affix, it gives them all a chance. With it false, it goes through the list of affixes and the first one that passes the random number under 100 test wins. If you wanted to make it rarer to get legendaries I'd say keep rarity pool off and make a sandwich: Bronze 50, Diamond 25, Legendary 1, Bronze 100. The sandwich is just so you don't get an unaffixed item. That example has a <0.5% of getting a Legendary. And it gets worse as you add more affixes.

Element Rate is elemental resist, Atk Element is for elemental damage.

Element Rate is set up like: [11, element_id, float] or (using element 2 as an example, and as a resist) [11, 2, 0.5] #Half damage!

Atk Element is even easier: (Again element 2) [31,2,0] #Done!
Okay thats I thought most of it worked, aside the -stats. I only needed it for broken and and cracked anyways. Also I thought both the element things were attack for some reason. Lol.

And thank you for being detailed with that explanation. I couldn't tell if the pool rarity worked the opposite way or not.
Kinda crazy...as I want to change my gameplay to http://forums.rpgmakerweb.com/index.php?/topic/16085-gubids-tactical-battle-system-v2-for-ace/ but the drops won't work with it. LoL een though my heart was kinda set on the change, I refuse to do any project that doesn't include this random items script...that's how much I love your work here.

So if any chance you have free time to look over their demo to see if you can compatabilize it, would be awesom...if not it's truly okay =)
***POSSIBLE COMPATIBILITY ISSUE***

I have found that when using this script with Individual Equipment from Fomar, I get an error.

Does anyone else have this problem?
***POSSIBLE COMPATIBILITY ISSUE***

I have found that when using this script with Individual Equipment from Fomar, I get an error.

Does anyone else have this problem?
Fomars script will not work this script unless one or the other makes a fix for this.

There is a reason for this, They both edit the id of the items/equipment. Fomars actually creates a whole different thing while this one does as well. I don't know if you can actually fix this quite easily as I'm not a scripter, well not a good one anyways. But unless Fomar or Vlue make a fix for this, or your script your own, it is not going to work.

What you could try is put fomars script first then W/A, then switch it, if it doesn;t work you need a fix.

Goodluck!
Hello, im a fan of you scripts thanks Vlue!

Im new to your community but, I signed up because I have an idea that may come in handy. 

Would it at all be possible to set Descriptions and associate it with an item Suffix or Prefix?

I think it would add a lot of depth and allow a full and complete set up of items down to tool-tips of a Simple base item.

I.e. A "Sword" is the base and has no description.

    - It rolls the Fire Prefix and is now a "Fire Sword"

    - it description Would read "Adds fire Damage" in first row description.

    - Prefix's could be second row.

    - This may even be cosmetic and add flavor to Classes of items

Thanks
***POSSIBLE COMPATIBILITY ISSUE***

I have found that when using this script with Individual Equipment from Fomar, I get an error.

Does anyone else have this problem?
Actually with this script you don't require any other script to make individual equipment, as long as the parameters are randomized enough it'll create a different instance of the item....if the stats happen to roll the same it'll stack em (best of both worlds).
Kinda crazy...as I want to change my gameplay to http://forums.rpgmakerweb.com/index.php?/topic/16085-gubids-tactical-battle-system-v2-for-ace/ but the drops won't work with it. LoL een though my heart was kinda set on the change, I refuse to do any project that doesn't include this random items script...that's how much I love your work here.

So if any chance you have free time to look over their demo to see if you can compatabilize it, would be awesom...if not it's truly okay =)
Aww, that is sad! Here you go: (Hopefully) ((It goes below it all.. probably under the patch section I guess))

Spoiler
class Scene_Battle_TBS def show_item_gain(treasures) #no item to show => abort return if treasures.empty? show_tbs_info_sprite(TBS_Treasure_Sprite.new(treasures)) #do item gain and reset temp treasures #add items even if they are not shown for item in treasures if item.is_a?(RPG::Item) $game_party.add_item(item.id,1) elsif item.is_a?(RPG::Weapon) $game_party.add_weapon(item.id,1) elsif item.is_a?(RPG::Armor) $game_party.add_armor(item.id,1) end end endendclass Game_Battler def secret_hunt_results(user, skill) if dead? and @result.hp_damage > 0 and user.actor? and self.enemy? if GTBS.skill_has_secret_hunt?(skill.id) itemlist = GTBS.secret_hunt_result?(self.enemy_id) perc = rand(100) for i in -(itemlist.size-1)..0 item = itemlist if item != [] next if !(perc < item[2]) case item[0] when 0 #item _item = $data_items[item[1]] next if _item.nil? $game_party.add_item(_item.id,1) when 1 #weapon _item = $data_weapons[item[1]] next if _item.nil? $game_party.add_weapon(_item.id,1) when 2 #armor _item = $data_armors[item[1]] next if _item.nil? $game_party.add_armor(_item.id,1) end $game_message.add(sprintf(Vocab:😮btainItem, _item.name)) break; end end end end endend
***POSSIBLE COMPATIBILITY ISSUE***

I have found that when using this script with Individual Equipment from Fomar, I get an error.

Does anyone else have this problem?
I certainly haven't had that problem! Though I've never used the script. If you link it I can take a look and tell you what can be done.

Hello, im a fan of you scripts thanks Vlue!

Im new to your community but, I signed up because I have an idea that may come in handy. 

Would it at all be possible to set Descriptions and associate it with an item Suffix or Prefix?

I think it would add a lot of depth and allow a full and complete set up of items down to tool-tips of a Simple base item.

I.e. A "Sword" is the base and has no description.

    - It rolls the Fire Prefix and is now a "Fire Sword"

    - it description Would read "Adds fire Damage" in first row description.

    - Prefix's could be second row.

    - This may even be cosmetic and add flavor to Classes of items

Thanks
Welcome! While it looks like description's have two rows, it's really just one long string with escape characters, but I did update the pastebin so affixes can rewrite the description of an item completely. Hopefully that's good enough! (The command is :desc for setting up your affixes.)
Thanks for the update on that, this system is insanely fun.
Haha it's not too sad, just your script provides the extra awesomeness of replayability and mystery and decent RPG requires most days now.

Oh and yes you are still awesome! 🤘 😮 🤘

Original thread: https://forums.rpgmakerweb.com/threads/weapon-armor-randomization.14771/