[CF-Devel] Artifact & subtype question (to know how to fix broken
build patch...)
crossfire-devel at archives.real-time.com
crossfire-devel at archives.real-time.com
Thu Dec 11 12:20:03 CST 2003
Yesterday i showed my building patch to some players, and it worked fine...
except i had to fix subtypes of items manually (i use'em to discriminate between
some items: type 161 = building material, subtype 1 = floor, and so on).
Investigating the reason, it's because subtype is not part of what an artifact
can give to an item (see common/treasure.c:add_abilities)
My 'building tiles', in shops, generate items, with the correct artifacts, but
since subtype isn't copied, it is wrong.
So the question would be: is there a compelling reason why an artifact could not
alter the archetype's subtype?
The type obviously is archetype-depend, but what about the subtype?
(btw, is subtype actually used somewhere?)
Now i could use another way to find what the player is building: use the builded
item's 'type' field. Which is not set for most floors & walls. So I'd have to
change archetypes for those, to add the 'type' field. I can live with that,
though :)
(the 'is_floor' is not enough, i fear, to correctly discriminate, especially
when there are walls without floors. And the 'no_pass' is not enough for walls,
since for instance doors have it too...)
Any thoughts about that?
_______________________________________________
crossfire-devel mailing list
crossfire-devel at lists.real-time.com
https://mailman.real-time.com/mailman/listinfo/crossfire-devel
More information about the crossfire
mailing list