Chaos Project

RPG Maker => RPG Maker Scripts => Script Requests => Topic started by: MerryCureSlime on April 22, 2020, 03:13:32 pm

Title: [XP] Battle formula for Items?
Post by: MerryCureSlime on April 22, 2020, 03:13:32 pm
Don't remember seeing something like this being proposed/requested around, so might as well give it a shot.

Basically, I wanted a script that allows items (say, bombs and the like) to do damage based on the user's stats. By default, they can only do fixed damage (by setting their HP healing value to a negative number) and that damage is confronted by the target's defense stats, which means they get less useful later on really quickly.

In VX Ace it's easy, since the default options allow for damage formulas for items, but not for XP.

I'm not using any custom scripts, basically starting a blank project.
Though maybe some compatibility with Blizzard's Tons of Add-ons or Wecoc's VX Ace collection would be welcome.

Appreciated the time taken in reading.
Title: Re: [XP] Battle formula for Items?
Post by: KK20 on April 24, 2020, 01:26:22 am
How complicated of an algorithm are you aiming for? If it's a universal change, it shouldn't be more than a quick edit of Game_Battler#item_effect.
Title: Re: [XP] Battle formula for Items?
Post by: MerryCureSlime on April 25, 2020, 02:21:50 pm
The same general algorhythm that skills use, able to involve any of the user's stats before the enemy's defense applies, and able to heal/damage by fixed numbers when needed. And yes, appliable to all useable items in the database.
Title: Re: [XP] Battle formula for Items?
Post by: KK20 on April 27, 2020, 03:11:10 pm
Took a look and realized this is actually much more daunting of a task than I'd like to delve into. There really isn't an easy solution for this that remains compatible with other battle systems. And configuring item algorithms would be too convoluted for the average user to understand.
Title: Re: [XP] Battle formula for Items?
Post by: MerryCureSlime on April 28, 2020, 04:22:17 pm
Ah, shame.

I won't ask about this further, but I suppose a proper way to start getting something done myself would be to add a user def to the item_effect line in Game_Battler 3

226     def item_effect(user, item)

like this?

I doubt I'll manage to get anything out, but at least this sounds like a step in the right direction?
Title: Re: [XP] Battle formula for Items?
Post by: KK20 on April 28, 2020, 06:35:49 pm
Yeah, something like that.