v50 Steam/Premium information for editors
  • v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
  • Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.

Difference between revisions of "Template talk:Creature/is humanoid"

From Dwarf Fortress Wiki
Jump to navigation Jump to search
m
 
(3 intermediate revisions by 2 users not shown)
Line 10: Line 10:
 
::::No, wait, that'll just look at the first creature in the file, not all creatures. Just a sec.--[[User:Zzedar|Zzedar]] ([[User talk:Zzedar|talk]]) 23:10, 16 April 2013 (UTC)
 
::::No, wait, that'll just look at the first creature in the file, not all creatures. Just a sec.--[[User:Zzedar|Zzedar]] ([[User talk:Zzedar|talk]]) 23:10, 16 April 2013 (UTC)
 
:::::Ah, no, that ''will'' work! <tt><nowiki>{{#df_tagentry:{{#df_raw:DF2012:creature_standard.txt|CREATURE|creaturenamehere}}|whatever}}</nowiki></tt> --[[User:Zzedar|Zzedar]] ([[User talk:Zzedar|talk]]) 23:14, 16 April 2013 (UTC)
 
:::::Ah, no, that ''will'' work! <tt><nowiki>{{#df_tagentry:{{#df_raw:DF2012:creature_standard.txt|CREATURE|creaturenamehere}}|whatever}}</nowiki></tt> --[[User:Zzedar|Zzedar]] ([[User talk:Zzedar|talk]]) 23:14, 16 April 2013 (UTC)
 +
::::::I'm an idiot. There's an existing option to not parse the creature variation -- we don't have to do anything. Look at <tt><nowiki>{{:DF2012:Crab man/raw|1}}</nowiki></tt> --[[User:Zzedar|Zzedar]] ([[User talk:Zzedar|talk]]) 23:28, 16 April 2013 (UTC)
 +
:::::::Wow, I completely forgot about that. Thanks for pointing it out. I just added a wrapper around the current template to test for animalmen first (which might be a little bit faster than the other order). It looks like it only added [[DF2012:Crab man]] (the count is now 182, up from 181), but it's probably a good idea to check for animalman status anyway. Let me know if you find any more problems. --{{User:Lethosor/sig}} 00:34, 17 April 2013 (UTC)
 +
::::::::Bad news, I'm afraid: kangaroos (and giant kangaroos) have [BODY:HUMANOID]. And, as mentioned before, harpies are problematic. Edit: oh, and giant bats have HUMANOID_FLIER; not sure whether blocking that will cause any other problems.--[[User:Zzedar|Zzedar]] ([[User talk:Zzedar|talk]]) 00:52, 17 April 2013 (UTC)

Latest revision as of 00:53, 17 April 2013

(Old discussion moved to Category talk:DF2012:Humanoids)

Problem with the HUMANOID_ARMLESS exception: crab men (edit:also harpies, but a case could be made that they shouldn't be considered humanoid). I think if we're going to do this categorization at all, it's going to have to be in Wittgensteinian fashion -- that is, a checklist where any creature satisfying more than a certain number of the conditions is considered humanoid (e.g., if we had ten conditions, any creature that met at least seven would qualify). --Zzedar (talk) 21:29, 16 April 2013 (UTC)

Right, forgot about that. If that's the only exception, I may as well add it in as a special case. --Lethosor (talk) 21:50, 16 April 2013 (UTC)
Arguably harpies. What worries me is that if we put in these special cases (well, let's be honest: if you do it, because I'm not anything like comfortable enough with the commands to do it), we'll have to rewrite the template as soon as some other creature is added that doesn't mesh well.--Zzedar (talk) 22:15, 16 April 2013 (UTC)
Actually, the multiple-characteristic idea could work, if the [APPLY_CREATURE_VARIATION] tag were accessible (it's replaced on DF2012:Crab man/raw). Not sure how to access this from a template, but I'll see if it's possible. --Lethosor (talk) 21:52, 16 April 2013 (UTC)
It can be done -- instead of using the /raw page, we can use the original file, along the lines of {{#df_tagentry:DF2012:creature_standard.txt|whatever}}. That would require listing out all of the .txt files that contain creatures, though (to the best of my knowledge, there's no way to have the df parser look across all of the files, you have to list them out). I guess I could create a page for inclusion that's just all the raws glommed together. Should I?--Zzedar (talk) 22:15, 16 April 2013 (UTC)
Whoops, got my commands confused. tagentry can't take just the file name, it has to be processed by df_raw first, along the lines of {{#df_tagentry:{{#df_raw:DF2012:creature_standard.txt}}|whatever}}--Zzedar (talk) 23:08, 16 April 2013 (UTC)
No, wait, that'll just look at the first creature in the file, not all creatures. Just a sec.--Zzedar (talk) 23:10, 16 April 2013 (UTC)
Ah, no, that will work! {{#df_tagentry:{{#df_raw:DF2012:creature_standard.txt|CREATURE|creaturenamehere}}|whatever}} --Zzedar (talk) 23:14, 16 April 2013 (UTC)
I'm an idiot. There's an existing option to not parse the creature variation -- we don't have to do anything. Look at {{:DF2012:Crab man/raw|1}} --Zzedar (talk) 23:28, 16 April 2013 (UTC)
Wow, I completely forgot about that. Thanks for pointing it out. I just added a wrapper around the current template to test for animalmen first (which might be a little bit faster than the other order). It looks like it only added DF2012:Crab man (the count is now 182, up from 181), but it's probably a good idea to check for animalman status anyway. Let me know if you find any more problems. --Lethosor (talk) 00:34, 17 April 2013 (UTC)
Bad news, I'm afraid: kangaroos (and giant kangaroos) have [BODY:HUMANOID]. And, as mentioned before, harpies are problematic. Edit: oh, and giant bats have HUMANOID_FLIER; not sure whether blocking that will cause any other problems.--Zzedar (talk) 00:52, 17 April 2013 (UTC)