Page 1 of 1

Polymorph (Yes, Again)

Posted: Mon Jan 14, 2013 4:30 am
by Ceir
Much to do has already been made about the relative paucity of permissible polymorph forms. I'm making this post to suggest three potential solutions, as precisely stated as I can manage given that I do not have access to the game's code, only a few educated guesses. The explicit goal of all three proposals is to make nearly every race in the game available to those with sufficient skill in the spell, without allowing the spell to become an overpowered one-spell-solution to everything.

How Race Qualification Works Right Now(?)
When the spell is cast, the race parameter specified is compared against the list of mob races. If the race is found, the caster's skill with the spell is checked against a difficulty value. This difficulty seems to be influenced by race category and general scariness. Most available animals are made available all at once, but tigers are a little more difficult. Similarly, most humanoids are made available all at once, but thrikreen and centaur require more expertise. Moreover, this skill level range is limited. You can only go so high as your skill allows, but for some reason you cannot stoop too far below your present maximum. For example, at the Master level, tiger form becomes unavailable again.

Secondly, if the skill rating requirement is met, certain aspects of that race's default stats are checked. The spell will fail if one of the physical stats is too high, if the natural AC is too high, if the race conveys a certain subset of permanent effects like damage resistance, or if other unknown conditions are met.

The problem is that the vast majority of high-difficulty forms seem to be disabled, because everything that's frightening enough to require a high skill level fails the second check. In Ceir's case, this has actually caused his his pool of available forms to shrink as he has advanced from Adept to Master in the spell. He's lost access to the tiger form and other earlier forms, but gained nothing (I have tried) in return. He's growing more limited with experience, not less.

Proposal One - Duration
Polymorph does not last terribly long when cast; it seems to be in the 1 minute/level category of spells. At level 50 with Master rating, Ceir's Extended Polymorph barely stretches into the "A While" duration category. At low skill and caster levels, Polymorph used to last long enough for two or three fights at the most. This could be used to balance the impact of particularly powerful forms, by docking effective skill level depending on just how powerful they are. If a form has a strength score six points over the permissible maximum, dock a corresponding number of ranks from the effective skill level or character level of the caster. Some experimentation may be required to establish the ratio, but 1:1 for skill level or 2.5:1 for character level would be a nice, conservative place to start. Do the same for all three physical stats, and impose a similar penalty if the race has any form of damage resistance, too many attacks/round, or some other special advantage. Should the accumulated penalties exceed the skill level of the caster, the spell fails outright. If there are any effective levels left, use that difference to calculate spell duration.

Ceir is a transmuter who made extensive use of polymorph while leveling. He spent days (IC time) practicing the spell for no other purpose than to refine his skill with it, before reaching maximum level, and still only barely achieved an Expert rating before hitting 50. If the penalties are balanced so that particularly fearsome forms are short-lived or impossible before Expert/Level 50, there should be little concern about making the spell too powerful in general gameplay.

This proposal may or may not be feasible depending on how spell effect duration is calculated and applied. If a global function is employed which takes the character casting as a parameter, rather than the character's statistics as parameters, then an additional parameter (effect duration penalty) would have to be added. It would also require a little bit of fine tuning, to meet the twin goals of allowing most races and staying within the bounds of balanced effect.

Proposal Two - Hardcode Nerfs
The problem with many races is that their strength score is simply too high, or their natural AC is bonkers, or some other statistic exceeds a given maximum. This proposal and the next would deal with that problem by lowering the effective stats of the assumed form. Instead of turning into a true wemic, a polymorphed wizard would turn into a wemic with a capped strength score of 25 (or whatever the max is in the code).

How feasible and difficult this is depends on how the codebase handles spell effects. I know from spells like Stone Body and Enlarge Person that spells can attach multiple effects to a character simultaneously. What I don't know is whether these effects are parameterized or not. If the MUD attaches effects as a pair of (effect, extent) like (strbonus, 4), then this is relatively easy to code. If the MUD instead stores spell effects in an array, which spells reference by index (say, entry 68 increases the strength of the subject by 4), then this is not a very feasible solution.

If this is possible to do, then this has the great advantage of being a one-time solution that will easily apply to any future races. It keeps the assumed stats of the wizard within acceptable bounds, while allowing them to at least seemingly take any sort of body they wish.

Proposal Three - Scripted Nerfs
The code behind this proposal is very simple. If a race would fail the second check, due to a statistic being too high, the function would look up a different race instead, functionally quite similar but with a prefixed or suffixed internal name. For example, when "cow" fails the check (yes, cow is both in the game and banned), it would look up "polymorph_cow". Polymorph_cow would be otherwise identical, but the stats which were too high to be permissible would be nerfed to acceptable maximums. If Polymorph_cow is found, the spell uses that for the transformation instead of the original cow. If no modified race is found, the spell fails normally.

The end result is almost functionally identical to Proposal Two. The wizard or druid casts his spell and turns into a cow with lowered stats. The problem is that this is not a one-time solution. The definitions of the mobile races will have to be extended, nearly doubled, either by hand or by a program written to the task.

If it's done by hand, the work is almost assuredly going to be doubled when adding a new mobile race, as the majority of mobile races are impermissible under the current maximums, and a great deal of drudgery will have to be undertaken by builders or other authorized scripters during the initial implementation.

If it's done by a program written for the task, one that automatically parses 'normal' races and creates new 'polymorph' races as required, then the long-term obligation is not so onerous, but that is a little more work in the short term. For what it's worth, I'd be happy to write such a program myself, and it would not require giving me access to the game's code, only it's mobile race definitions.

Re: Polymorph (Yes, Again)

Posted: Mon Jan 14, 2013 4:32 am
by Ceir
I anticipated a few questions, in the case that anyone ever actually reads all that. Here are some pre-emptive replies.

Is all this really necessary, anyway?
There are two arguments for why such a fix is necessary, but they're largely matters for another topic, probably in General Discussion. To state them briefly: One, the huge number of races that are impermissible (even benign races such as pixie and cow) unnecessarily dampen the fun of playing a wizard who ought to be able to turn into just about anything. Two, transmuters benefit from a very large number of transmutation spells, but most of them are either completely useless or benefit very little from mastery. They're the only spellcasting class in the game that has no way of mitigating or healing damage done to others, and they can't even mitigate or heal damage done to themselves until level 36. Their one spell which really should reward specialization and mastery, Polymorph, currently does not. In fact, the number of creatures a transmuter can turn into only shrinks as he progresses from Adept onward, and that's silly.

But the PvP!
If you fight Ceir and he actually physically attacks you rather than cast a spell, this is either a very strange spar, or you have cut off both of his arms and he is gnawing at your ankles. There is a legitimate concern that this might change for the worse if forms such as wyvern and dragon are made available. Forms with an exceedingly high number of attacks/round may have to be addressed separately, or simply remain banned.

Finally...
Is this a high priority?
No, not really. There's very little impact felt during the first hundred hours of gameplay, as there are enough forms to at least make it to level 50. Every single mage who uses the spell will end up using roughly the same progression of 'good' forms, all the way to Adept, but the scarcity of alternatives is only unfun, not crippling.

Most of the impact is felt at high skill level, where huge chunks of the Bestiary go missing. This primarily damages high level transmuters (of which there are three that have logged in so far this month), and to a lesser extent high level druids (of which there are more, but they have a wider range of effects to fall back on).

As it stands, Abjurers and probably Thieves need more immediate help, and there are plenty of spells that don't work at all rather than simply working halfway. I simply wanted to put these three suggestions out there for future consideration. Thanks for reading, and thanks for your time.