to Share - to copy, distribute and transmit the workto Remix - to adapt the work

Under the following conditions:

Attribution. You must attribute the work in the manner specified by the author or licensor (but not in any way that suggests that they endorse you or your use of the work).

Noncommercial. You may not use this work for commercial purposes.

Share alike. If you alter, transform, or build upon this work, you may distribute the resulting work only under the same or similar license to this one.

- For any reuse or distribution, you must make clear to others the license terms of this work. The best way to do this is with a link to this web page.

- Any of the above conditions can be waived if you get permission from the copyright holder.

- Nothing in this license impairs or restricts the authors moral rights.

This script was requested by JanraeMendoza...This Script is a Xp version of the original VX one.THIS SCRIPT HAS NOT BEEN FULLY TESTEDThis script may have a few flaws this is because I prefer and am much better at VX rather than XP.This is my first proper released XP script.

Also a version that works with XAS Hero edition was requested and fufilled.These Scripts are currently equal to the 1.1 version of the VX one, I may update these to match the VX version.

In both scripts a definition called dropluckcalc is added, and in Game_Actor two definitions are added (replicating the VX .armors and .weapons).Features

Generates A Drop luck variable that changes the probability of dropping any advance equipment

@@AdvancedItems.each_index do |i| if enemy.item_id == @@AdvancedItems[i] include_drop_luck = true # and item is an advance equipment then # include drop luck end end

end

if enemy.weapon_id > 0

@@AdvancedWeapons.each_index do |i| if enemy.weapon_id == @@AdvancedWeapons[i] include_drop_luck = true # and item is an advance equipment then # include drop luck end end

end

if enemy.armor_id > 0

@@AdvancedArmors.each_index do |i| if enemy.armor_id == @@AdvancedArmors[i] include_drop_luck = true # and item is an advance equipment then # include drop luck end end

end

# Determine if treasure appears if include_drop_luck == true

prob = enemy.treasure_prob + dropluck

if rand(100) < prob if enemy.item_id > 0 treasures.push($data_items[enemy.item_id]) end if enemy.weapon_id > 0 treasures.push($data_weapons[enemy.weapon_id]) end if enemy.armor_id > 0 treasures.push($data_armors[enemy.armor_id]) end end

else

if rand(100) < enemy.treasure_prob if enemy.item_id > 0 treasures.push($data_items[enemy.item_id]) end if enemy.weapon_id > 0 treasures.push($data_weapons[enemy.weapon_id]) end if enemy.armor_id > 0 treasures.push($data_armors[enemy.armor_id]) end end

# Seeing as this def is called before the actuall usage this will surfice # as a place to put them seeing as initialize def causes errors with XAS # Setup Like the VX version @@AdvancedItems = [] # array ids of AE items @@AdvancedWeapons = [] # array ids of AE weapons @@AdvancedArmors = [] # array ids of AE armors

Place like normal (Below standard scripts and above main // Make sure that the XAS is below the actual XAS scripts)

The Script runs at the end of the battle, If an enemy has the possibility to drop any Advance equipment the drop luck is subtracted from the Advance equipment denominator before the mostly normal procedure carries out.

To set Advance Equipment(AE) just add the id to the array of the correct type, e.g. AE Weapon ids in the array @@AdvancedWeapons...

To set the drop luck increasing weapons and armours just add to the correct hash the information using this as a key "id => dropluckincrease".

Read the comments in the script, post here if any bugs or the comments don't make sense.Compatibility

This script will probably not be compatible with any script that modifies Scene_Battle.start_phase5XAS version modifies XAS_BA_ItemDrop.defeat_process...Credits and Thanks

Thanks to:

JanraeMendoza for the request and original testing

XAS Credits:

Xiderowg for XAS

MogHunter for XAS Hero Edition

Calvin624 for the Translated Version

Author's Notes

A = XP VersionB = XAS Version

Version History: // Note DL is Drop Luck and AE is Advanced Equipment...1.0 - A/B - Original version for JanraeMendoza

To Add:- Choose who's equipment is checked...- Add more options and make easier for user...

Please report any bugs here...

« Last Edit: June 26, 2011, 05:21:14 PM by ForeverZer0 »

Logged

If you put a million monkeys at a million keyboards, one of them will eventually write a Java program.The rest of them will write Perl programs.