-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Summon several kinds of kittycat from Bag of Cats #40656
Conversation
With this flag, a spell with "summon" effect spawns not a specific monster type ID, but rather a monster type from a monster group ID.
I found what I think is a good solution to the cutoff of the summoned monster name - effectively swapping the positions of the "Damage" and "Range" sections of the spell info display, so the "Damage" (or "Summon") section gets its own line, and "Range" shares the first line with "AOE". Here, pictures. Before: After: And this is what "Bag of Cats" looks like now: (Note, final terminology is "2 from GROUP" instead of "2 of GROUP") |
This makes the typically shorter strings (Range and AOE) share a line in two colums, while Damage (or Summon, Spawn, etc.) gets its own line.
What surprised me was that so many cats were wandering around in my house without even breaking my can. |
Travis CI shows an error that appears unrelated to anything in this PR:
|
Summary
SUMMARY: Features "Allow summoning spells to spawn from a monster group"
Purpose of change
To get all different kinds of cats from the Magiclysm "Bag of Cats" spell, which I've been wanting to do ever since #38889.
Describe the solution
Add a new flag
spell_flag::SPAWN_GROUP
, which can be provided in a spells"flags"
list.For spells with
"effect": "summon"
, the flag causes the spell to treat the"effect_str"
entry as a monster group ID, rather than a monster ID.In other words, summoning spells used to be limited to a single monster type:
Now, they can summon a monster from a group, like so:
The new flag is documented in a new "Spell Flags" section of
MAGIC.md
.Describe alternatives you've considered
I poked at some dead-ends with an
effect_list
and hard-coded random monster spawns before @KorGgenT pointed me toward this more reasonable solution.The
SPAWN_GROUP
flag may be useful for the item-spawning (and possibly vehicle-spawning) spell effects as well, but I did not attempt to implement such for this PR.Testing
Casting "Bag of Cats" gave a variety of feline forms, as intended.
Tested "Cause Bear" and "Summon Decayed Pouncer" to ensure original summoning behavior still works.
Additional context
There is still one problem I want to solve, which is the way the spell displays in the spell menu. Because monster group IDs do not really have player-readable names, and the spell description layout appears to have a maximum usable width for this field, the full name of the group will not fit:This is fixed now in e5433e4 - see comment below.