[XP] How to put Variable as Prize???

Started by Rolandojis, April 09, 2012, 03:05:37 pm

Previous topic - Next topic

Rolandojis

I want like a monster that instead of dropping and item it drops a variable when killed

Example: After defeating Monster1 you get +1 of variable2

How can I do that???

Calintz

in other words, you want to increase a specified variable by one for every time you defeat a specific enemy?

Rolandojis

mm i dunno if i specified myself, in my game monsters drop elements like fire or water

so i want it to be able to specify a monsters drop in variable

Example:
Variable2=Fire
Monster1=+1Fire drop
Monster2=+2Fire drop

Instead of having the "teasure"(database name) as an item, have a teasure of variable

Calintz

so you call the item's dropped by enemies "elements." these elements are actually items in your database though, right? you have an item called "fire," and another item called "water," and so forth?

Rolandojis

No they aren't items, I set them up as variables
variable 10 is Plant
variable 11 is Water
etc...

I want monsters to drop this "elements" each monster drops diferent amounts of elements that add up to the variable
so after killin 2 monsters that drop 3 water each, then variable 11's amount would be 6

Calintz

i don't understand why this is valuable? why would you want to set a variable that way? i don't understand why you wouldn't just make items that reflect the element you want the enemies to drop? anyway, i think that requires a script mod, and i wouldn't be able to do that for you. what battle system are you using? i don't think i can help you. sorry.

Rolandojis

well thnx anyways. umm the normal battle system

and I use this because the elements are used to create things or buy things.
Example:
You go to a specific place with 2 Plant and 1 wood and create Tree
You go to FlamingCrafts with 1 fire and 2 wood and create torch

I would do this with items but in conditional branchs only appears if you have a type of item in possesion, not a quantity of an item

KK20

Quote from: Rolandojis on April 09, 2012, 09:20:59 pm
I would do this with items but in conditional branchs only appears if you have a type of item in possesion, not a quantity of an item
Is there any reason why you can't just set a temporary variable to equal the quantity of the element? You can do that you know.
"Control Variables" => "Set" => "Item [Dropdown list] In Inventory"

Other Projects
RPG Maker XP Ace  Upgrade RMXP to RMVXA performance!
XPA Tilemap  Tilemap rewrite with many features, including custom resolution!

Nintendo Switch Friend Code: 8310-1917-5318
Discord: KK20 Tyler#8901

Join the CP Discord Server!

Calintz

that would probably work. if you create an item for each element, and use a common event to constantly set the amount of each element in the inventory (use a switch to activate it at the beginning of the game) this would work. then the conditional branch could be used to check the quantity of each element in the inventory.