Yeah, definitely sounds like somewhere in the pipeline spellid is being treated as a signed 16-bit integer, which is limited to -32768 to +32767.
It would make more sense to use an unsigned integer that allows for referencing ids from 0 to 65535, but probably somewhere in the data there are references to spellid -1 as meaning "No spell", maybe in case there's a valid spell with spellid 0.
|