The BBS
The Battle System, Calculator and all - Printable Version

+- The BBS (http://bbs.studio-revolution.net)
+-- Forum: The (Yet Unnamed) BBS Game System (/forumdisplay.php?fid=25)
+--- Forum: Planning (/forumdisplay.php?fid=26)
+--- Thread: The Battle System, Calculator and all (/showthread.php?tid=984)



The Battle System, Calculator and all - bobandbill - 7th Oct 2012 06:53 AM

Said I'd make a thread on it, so!

This is the calculator used for the old ASB system we had that is intended to be used for the Game system, and a quick explanation on how it works.

html (smaller file, fixed size)
swf (size adjusts to fit the browser window)


How the program works:
- external txt files are loaded when selected, said files being for Pokemon data (name, stats, typing, abilities), attack data (descriptions, base power, effect chances, etc) and ability data (description).
- so updating that part (e.g. new generation) is a matter of mostly adding new txt files, and coding only for the more unique attacks (e.g. those based on weight, etc).
- Negrek remains a god for generating all of those for us out of the blue. =p

How damage is calculated:
- Pokemon have levels, ranging from 1 to 10 (being more than 3-4 levels higher doesn't change the power of attacks though
- The only base stats of Pokemon that matter in usual circumstances for battling is the speed stat (who goes first/last); what is there is more for info sake/in case some move comes around that relies on that and I decide to keep that with the calc. For instance, Gyro Ball is stat based, some moves depend on the oppositions' weight, etc. These are the exception rather than the norm though, and have separate coding for them
- Base power of the attacks factor in. PP is part of the calculation for how much energy it takes up to use the move. Abilities also have an impact ala the games on damage, as well as level differences, weather and any stat boosts (e.g. from growl, swords dance, etc).
- As such, these ASB battles were based on health and energy; if one was fully depleted then the Pokemon fainted.
- side effects (e.g. confusion, paralysis, critical hits, flinching, etc) is accounted for by the program.
- 'rng modifier' adds a bit more chance; as in any attack may do up to 2% more or less damage than usual with each 'roll'. (Up to the DM if they want to use that I suppose!) Double battles used double battle mechanics (e.g. surf is weaker in such circumstances).


How to use the calc:
- you need to select both the attacking and defending Pokemon, and give them a level to be able to select an attack in most cases. It'll work without any stat boosts, abilities chosen, etc, but if you want those to be factored in you also need to select those. =p
- you can select a pokemon from the list or type it in and hit submit. If you type in the first letter of few of a Pokemon (e.g. 'Ab') and hit submit, then the list will only return Pokemon that match (ie in this case Abomasnow, Abra and Absol).
- type in the attack and as long as the spelling is correct the calculator will do the rest when you hit the submit button underneath the box.


I imagine the DM can always add in their own things too (e.g. if someone uses a nice combo of moves they can determine how much more those two moves will do with damage, state their own effects with the setting of the battle, etc).

Post here if you have any questions/mistakes to point out (although I know about fury swipes and other multimoves not doing any damage in cases last I checked) suggestions on the calculator and/or how battles should run for the game!

May add more to the above when I have more time/etc.


RE: The Battle System, Calculator and all - An-chan - 7th Oct 2012 04:43 PM

Question: would it be reasonably simple to increase the amount of possible levels?

Also, for battle purposes for the human characters, we could just add a "Pokémon" template for each class or somesuch and have everyone input their stats, maybe... That is, if humans in battles/fights of some sort will be a thing. But just a thought, anyway.


RE: The Battle System, Calculator and all - bobandbill - 8th Oct 2012 12:52 PM

(7th Oct 2012 04:43 PM)An-chan Wrote:  Question: would it be reasonably simple to increase the amount of possible levels?

Also, for battle purposes for the human characters, we could just add a "Pokémon" template for each class or somesuch and have everyone input their stats, maybe... That is, if humans in battles/fights of some sort will be a thing. But just a thought, anyway.
Changing the max limit would not be too hard. I might want to reconsider how level differences work in damage dealt on that note however then if the range is increases significantly.

And by the latter part do you just mean making .txt files for characters ala the Pokemon ones? If so then yes, that is possible, but it's not that clear cut (e.g. what typing do they have? If not one of the existing ones (e.g. Normal) then I'd also have to code that into it too, pretty sure. Then there's 'attacks' people may have if it isn't done by the DM, and in such a case I think it may be better for the DM to just deal with it by themselves (e.g. if a Pokemon hits a water gun they can write it how they like and work out their own 'damage' - plus people may not necessarily have health/energy as well imo. But well, first we'll see what people want with that.)


RE: The Battle System, Calculator and all - bobandbill - 23rd Nov 2012 01:22 PM

Any newer comments on how battles should run in regards to the calculator and dungeons in general?

For instance, how should levels scale? (Before it was 1-10, Pokemon evolved at the level they would evolve in the games divided by 10 and rounded up to the nearest integet (e.g. starter pokes: evolve at level 2 and again at 4. Cases like catepie just evolved every level ie 2 and 3). With that, what about exp? (As before, exp gained was equal to the level of the opposition, exp required to evolve was the same amount as the Pokemon's own level (e.g. a level 3 poke needed 3 exp to evolve... personally I'd prefer this to be increased for this, before was just for ASBN).

And so forth. Last time around we had abilities and a thread for crazy moves too which I can remake too, but better get the more general stuff in line first!


RE: The Battle System, Calculator and all - An-chan - 2nd Dec 2012 07:23 PM

Quote:Maybe we could multiply all damage by 1,5 for better balance, since twice the damage might be a bit much... Could you change the calc in such a way that it always multiplies the output by that amount? I don't know how programming with Flash (was it?) works, so I'm not sure what that would look like.

Though, arguably, since we're nearly always going to have more people in every fight, maybe we don't need to change the damage figures... But I don't know. Maybe that's more something to discuss in the calc thread. I'll go post there shortly.

And post she did.

So, basically, what kind of a balance do we want with damage? Do we want faster, more intense battles, or what sort of a system should we go for?

Also, are people going to be included in damage calculation? I assume this would be a thing where the DM would have to input all of the character's stats to get a damage figure and then apply it in whichever way they see fit (halve it against certain pokémon, x1.5 it if they manage to punch their opponent in the gut, double it if the person is holding a really heavy stick or a knife or something). But do we need something like that anyway? Could we just apply the strength stat either directly or with some sort of formula and a miss chance of x? Or what?

Also repeating bnb's question about Pokémon levels and maybe rescaling them. Are ten levels too little? Should we change the system we had going previously?

I think combo moves and other special moves fall under the DM's discretion and don't need to be included in the calc, but on that note maybe we could just allow for "custom" moves so that the DM can simply put in base powers and hit chances and stuff like that as they please or something. I dunno how difficult that would be, though, so.


RE: The Battle System, Calculator and all - bobandbill - 2nd Dec 2012 09:34 PM

Very quick post but by special moves or whatnot I mean the canon ones that aren't just based on base power (e.g. grass knot, heat crash, etc). Fanmade moves need to have a .txt file to be made for them if we want that down the track, and personally I'd rather go without.

IDK if we need people in the calc, but if so need to decide on a 'typing' for them, etc too. Or invent one ie more work.


RE: The Battle System, Calculator and all - bobandbill - 6th Dec 2012 03:26 PM

Slightly longer post!

I agree that longer battles would be better for this. Any objections to that then? I'd rather not have to go make multiple edits to the calc to do/undo things is all.

Kinda leaning towards not having people in the calc as I think it'd be better to use use their own stats (and figuring out how we'd incoperate that into the calc as well will be all kinds of messy).

Maybe we ought to go with say a minimum of 15 levels, maybe 20 if we keep the exp system the same...? Not moree than that as getting to 10 would still take a while I imagine. Would need to rework evolution I suppose (say game mechanics level evolution rounded to nearest 10 and then divided by 5, rather than 10; so say a typical starter Pokemon (Bulbasaur etc) evolves upon levelling to level 4 and then 8 (~16 and 36 in the games iirc)). I'd then think a minimum level on Pokemon that evolve via other ways would be ideal too (e.g. stones, happiness, trades) so to not encourage the usage of them over other Pokemon given they just need an item to evolve, not actual battling and usage.


RE: The Battle System, Calculator and all - Latios - 22nd Mar 2014 05:43 PM

Alrighty, so we still have a list of problem moves floating around in the archives that we should probably bring back in some manner. Notably, I just had a pokémon try to use Sand Tomb and found that it had a base damage of 9. I'm not sure if this is the damage it's supposed to do over a series of turns or if its base damage is legitimately wrong. Also, I wasn't sure how we're handling the whole "deals damage for 2-5 turns" thing, so it would probably be good to resurrect Problem Moves and update it a bit. I can work on that if people would like!


RE: The Battle System, Calculator and all - bobandbill - 23rd Mar 2014 02:23 AM

If we're to be updating moves, we should go straight to gen 6 updates, so that means a fair bunch of moves would need editing. Help would be appreciated with that, haha.

And yeah, there will be errors, it didn't get all that much stress testing last time, to be honest. I checked the files and for some reason Sand Tomb's base power is listed as 75, not 35, so that's an error. I can't get into the site to actually change that right now as the ftp accounts changed, Kelly says she'll get to that tomorrow.

So Anni, either wait for that to be fixed or take that into account with the calculations - on my local files for that actual matchup in the fight (Vibrava v Rapidash), base damage becomes 4% rather than 8% (shows 8% for me on the site, Latios, which is what it should do as it divides by 10 and rounds up), -1% for level difference, +2% for stab, rest is rng (hitting, etc) so up to you. ;p


AS for the how many turns thing it does, what is displayed is first turn only. I vaguely remember that it was to be up to the ref on how many turns via rng. The old thread stuck back in gen 4: http://bbs.studio-revolution.net/showthread.php?tid=208
Quote:Sand Tomb
Description: The user traps the target inside a harshly raging sandstorm for two to five actions.
Type: Ground | Classification: Physical | Power: 15 In old gens I guess it had less | Accuracy: 70%
Effect: The user creates a whirlwind of sand that traps the target, allowing them to move only a minimal amount (unless the target is sufficiently large and/or powerful to negate this – e.g. a Wailord is unlikely to be hampered by the Sand Tomb created by a tiny Trapinch). There is a 37.5% chance that damage will be dealt for 2 actions, a 37.5% chance that damage will be dealt for 3 actions, a 12.5% chance that damage will be dealt for 4 actions, and a 12.5% chance that damage will be dealt for 5 actions. Damage applied in subsequent actions is equal to that which was originally dealt, and is dealt at the end of an action. The 70% accuracy chance is only applied for the first hit.

Certainly a new problem moves list will need to be compiled.


RE: The Battle System, Calculator and all - An-chan - 23rd Mar 2014 02:08 PM

I can do that calculation manually. Once you get into changing things - since I'm not sure I can do that? - I'd also like to note that the accuracy of Mud-Slap is listed as 85, even though it's always been 100. Not a big deal though, that was easy to adjust manually, but it's definitely there.


RE: The Battle System, Calculator and all - bobandbill - 5th Apr 2014 08:41 AM

Belated, but I have access and have fixed Mud-Slap and Sand Tomb on the live version of the calc now. Yay!


RE: The Battle System, Calculator and all - An-chan - 1st May 2014 04:32 PM

For some reason it says Ancient Power is not a valid move. Is the file for it maybe misspelled, or missing altogether?


RE: The Battle System, Calculator and all - bobandbill - 1st May 2014 10:49 PM

AncientPower as one word works, as that's the name of the file. I think it may have been named like that in older games so that's why. I can always just clone the file when I have time to account for such instances though so AncientPower and Ancient Power both work.


RE: The Battle System, Calculator and all - An-chan - 2nd May 2014 01:42 AM

Riiiight, okay. Yeah I checked Veekun to see if it was supposed to be spelled as one word, but since it was written as two words there, I figured that's just how it's spelled. Now that I checked it again, DynamicPunch is also spelled as two words there now, so they must have just added the space now that there's no longer any really binding character limit.

Good to know, though! I guess it would be easier to just have doubles of all the attacks than can have a space or not have a space, or then we could just write a short spelling guide, since it's case sensitive and everything.