Weapon/Armor Randomization

Vlue, here is the script

http://pastebin.com/raw.php?i=P5G1jUr9

If you could get your WA Random script to work with that one it would be amazing. I appreciate it either way! I need these 2 scripts to work in order for me to use the

"Equip Levels" add on script to Individual Equipment.

Here is the link for Equipment Levels just in case.

http://pastebin.com/raw.php?i=VFRfmB6w

Thanks!

P.S. Regarding your "Sleek Item Popup" script...

Is it possible to display color on the popups? For example: The player finds a "Steel Sword of Flames" and I have the color on 1 of the affixes set to say, purple. Can that color be displayed on the popup?

P.S.S. Can you explain how rarity works in your WA Random script? I'm not sure I understand the purpose of it. I'm talking about the :rarity symbol

Thanks again! You're definitely the best Ace scripter and certainly most active and helpful!

P.S.S. Regarding the latest update... You missed a comma on line 137 that causes an error.

Another error...Attached

WA_Random_Script_ERROR.png
You just enable the sleek popup in the W/A script, it will show the color.

Rarity pool off is first come first serve down the list, pool rarit on is it does it all at once (meaning every affix has a chance)

Change that affic, to affix.

I can't get those two scripts to work, I'm not good enough for that, but I'm sure he could.
You just enable the sleek popup in the W/A script, it will show the color.

Rarity pool off is first come first serve down the list, pool rarit on is it does it all at once (meaning every affix has a chance)

Change that affic, to affix.

I can't get those two scripts to work, I'm not good enough for that, but I'm sure he could.
I have it enabled, shows no color.

The rarity I'm talking about is the :rarity symbol you put on affixes. I'm wondering what's the point of putting a rarity in the affix, when you set it in the Weapon/Armor Database notetag

Also, I can't test the game because I keep getting a weird error.

Weird_ERROR.png

EDIT: I found out what was causing the error, there was a missing comma on the previous line.
Oh, I never noticed the :rarity, now I'm interested in that too. I'll give you a example (also it won't show some colors.) Like there are certain grays it won't show.

Here is a working sample piece straight from my game:

Spoiler
1 => { :name => "Broken ",
                   :Satk => 0,
                   :color => Color.new(119,119,119),},
            2 => { :name => "Cracked ",
                   :Satk => 1,
                   :color => Color.new(119,119,119),},
            3 => { :name => "Bronze ",
                   :Satk => 3,
                   :SatkP => 1,
                   :color => Color.new(0,255,0),},
            4 => { :name => "Copper ",
                   :Satk => 5,
                   :SatkP => 2,
                   :color => Color.new(0,255,0),},
            5 => { :name => "Tin ",
                   :Satk => 7,
                   :SatkP => 3,
                   :color => Color.new(0,255,0),},
            6 => { :name => "Iron ",
                   :Satk => 9,
                   :SatkP => 4,
                   :color => Color.new(0,255,0),},
            7 => { :name => "Steel ",
                   :Satk => 11,
                   :SatkP => 5,
                   :color => Color.new(0,0,255),},
            8 => { :name => "Gemmed ",
                   :Satk => 13,
                   :SatkP => 6,
                   :color => Color.new(0,0,255),},
            9 => { :name => "Crystal ",
                   :Satk => 15,
                   :SatkP => 7,
                   :color => Color.new(0,0,255),},      
            10 => { :name => "Diamond ",
                    :Satk => 17,
                    :SatkP => 8,
                    :color => Color.new(0,0,255),},
            11 => { :name => "Legendary Bronze ",
                    :Satk => 22,
                    :SatkP => 10,
                    :color => Color.new(238,118,0),},
            12 => { :name => "Legendary Copper ",
                    :Satk => 27,
                    :SatkP => 12,
                    :color => Color.new(238,118,0),},
            13 => { :name => "Legendary Tin ",
                    :Satk => 32,
                    :SatkP => 14,
                    :color => Color.new(238,118,0),},
            14 => { :name => "Legendary Iron ",
                    :Satk => 37,
                    :SatkP => 16,
                    :color => Color.new(238,118,0),},      
            15 => { :name => "Legendary Steel ",
                    :Satk => 42,
                    :SatkP => 18,
                    :color => Color.new(238,118,0),},
            16 => { :name => "Legendary Gemmed ",
                    :Satk => 47,
                    :SatkP => 20,
                    :color => Color.new(238,118,0),},      
            17 => { :name => "Legendary Crystal ",
                    :Satk => 52,
                    :SatkP => 22,
                    :color => Color.new(238,118,0),},      
            18 => { :name => "Legendary Diamond ",
                    :Satk => 57,
                    :SatkP => 24,
                    :color => Color.new(238,118,0),},
Those colors work for me 100%. Also you will have to take fomars scripts out until he makes a fix (if he can). Fomars scripts will tamper with the popups too. Also, can you show me the event'events were they are supposed to pop up?
I've taken the Individual Equipment script out. 

The Colors work in the inventory

Colors_In_Menu.png

Here is the popup

Colorless_Popup.png

Here is the event I'm using to add a piece of equipment.

Event_adding_armor.png

Thanks for any help you can provide!
I have had a problem were one color would show up in the menues but it wouldn't show up in the popup, and vice versa. Try my colors.

the

119,119,119 (Gray)

0, 0, 255 (Blue)

0, 255, 0 (Green)

238,118,0 (Orange)

Try those. If it still doesn't work, I'm not too sure. You can send me your project and I can take a look at it. 
I tried the colors, I even isolated the 2 scripts in a completely new project, and it still only shows White.

Not sure what the problem is. But I'm confident Vlue can figure it out.

Vlue, you also have some errors to correct in the script. Just a couple minor things. 

A missing comma on Affix 12

The word "affic" instead of "affix" on line 359

Also, the Affixes need spaces between the quotation marks.
It works. I'm using the exact same scripts you are, I had to fix those problems too. That is a bit weird though. Let me look through the scripts to see if I can find something for you. If I can't fix it for I'll leave Vlue to it.

EDIT: Also can you post both of your scripts. Sleek pop up and W/A
How do I put the spoiler thing on here? The scripts are long so...
do (spoiler)(/spolier) only with [ and ] instead of ()
Try this.

Turn this to true:

#Whether to use a custom or default font
PU_USE_CUSTOM_FONT =

I also use multiple lines = false but I don't think that would ruin how you have it.

Also the Prefixes are pretty hard to read, for future reference, if you plan on changing them make them a bit easier to read. Such as making everything one line. It just makes it easier to edit when need be.

I think the way you have it set-up could be the problem. Though you did say it worked in the menu so perhaps not. If that doesn't work I don't know what else there is. So I hope that is the problem. Good luck!

edit actually do this too:

#True for single line, false for multi line
PU_SINGLE_LINE =

Yours is true, change that to false. I'm not too sure if that has a color effect on it. But it might.

EDIT: Oh also put the popup script UNDER the W/A Script. At least thats what I did.
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
Spoiler


This works fine in creating the new equipment, but it seems the tag info for the battle system doesn't transfer to the new item (i.e. range, movement commands, etc..), example would be the hand ax( database item ) in the demo has a range of 2 when used to attack, but a hand ax of legend (after affix is applied) only defaults to normal range.

What was that quote for? Lol?
Try this.

Turn this to true:

#Whether to use a custom or default font

PU_USE_CUSTOM_FONT =

I also use multiple lines = false but I don't think that would ruin how you have it.

Also the Prefixes are pretty hard to read, for future reference, if you plan on changing them make them a bit easier to read. Such as making everything one line. It just makes it easier to edit when need be.

I think the way you have it set-up could be the problem. Though you did say it worked in the menu so perhaps not. If that doesn't work I don't know what else there is. So I hope that is the problem. Good luck!

edit actually do this too:

#True for single line, false for multi line

PU_SINGLE_LINE =

Yours is true, change that to false. I'm not too sure if that has a color effect on it. But it might.

EDIT: Oh also put the popup script UNDER the W/A Script. At least thats what I did.
Unfortunately, none of your suggestions worked. 

Could you please show me it working with your project? Just a single screenshot would be great!

Thanks for trying to help! I appreciate it!
h35YFkR.png
Cool!

I don't know what's wrong with my scripts. 
Ah so many replies... Ok..


To Mojo, edited the pastebin, hopefully that will preserve the notes (though I don't see why it wouldn't already)


To cooldoode, shh you! Those affixes weren't supposed to be in there lol. Pasted mine by accident. (Oops on the affic though!)


Joking aside, You don't have the latest version of Sleek Item Popup (I must have messed up the version numbers) and that's why no color. v1.10.2 is the most recent and not v1.11


As for the individual equipment thing, I have no idea. I have no idea if this could tide you over though, but I updated this script with an option called STACK_SAME_EQUIP, which when set to false gives every random item it's own id regardless of it being the same as a previous item or not.


Also, as for :rarity, it's an arbitrary number that determines what item color to use... when both a prefix and a suffix with the color option are applied, the one with the higher rarity is the color used.


Okay.. I think that's everything.
Colored_Popup.png

IT WORKS!!!

Thank you so much, Vlue!

You are amazing indeed!

Unfortunately your script still doesn't work with Individual Equipment. Thanks for trying! I'll just have to find another script that allows equipment to level up!
I am really grateful for your assistance in trying to integrate with a system that isn't even one of yours, but sadly it isn't working still. Odd as it seems..I think when the new item is made it's like a clean item..

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