• Play
  • About
  • News
  • Forums
  • Yppedia
  • Help
Personal tools

Template talk:My trinkets

From YPPedia

Three colour trinkets

I want to add the code to handle trinkets with three colours like specified at Category talk:My trinket templates. Or does anybody spot a problem with that approach ? Additionally I would need some admin to put a |tertiary={{{trinketcolor3|}}} into Template:Infobox pirate passing that argument to Template:Infobox pirate/trinket/yes --Alfwyn 06:10, 29 February 2008 (PST)

I'd like to look at your proposed changes more first. Can you set up your sandbox to give examples of wrongly filled-in templates?--Fiddler 10:38, 29 February 2008 (PST)
I'm a bit upset. After really thinking about the problem, setting up a sandbox version, putting the thing up to discussion, first nobody really seems to care and suddenly a slightly different version just gets implemented. Right now I feel I should just have gone ahead and done the changes without asking. --Alfwyn 05:18, 6 March 2008 (PST)
I believe the slight was unintentional. The wiki can tend to be like a giant tidalwave when trying to keep track of things that are going on. Months ago I actually had discussed the tertiary color for my trinkets with Kgarrett, but rl came to the forefront, as it should, and he put aside the project. In any event, I truly appreciate your use of the sandbox and your willingness to add various test cases to ensure a smooth transition. We all look forward to further cooperative YPPedia projects. Hopefully the future will be a little less bumpy. :) --Guppymomma 15:09, 6 March 2008 (PST)

Tertiary Trinket Colors

Ok it is decision time. We need to decide on an implementation for the Tertiary trinkets. There are two possiblilities for final implementation. Note that the possibilities only differ in the unnamed parameter case.

User:Alfwyn has offered a implementation that would keep all existing usage working. Basically this implementation would redefine the usage of the templage fields back through the templates in order to make make everything fall out properly. His code can be found here User talk:Alfwyn/Sandbox

{{My trinkets|color1|color2|text}}
{{My trinkets|color1|color2|color3|text}}
{{Colorize trinket|color1|color2}}
{{Colorize trinket|color1|color2|color3}}


Pros

Existing usage works for all trinkets.
Usage would be logical for users.

Cons

Not as easy to maintain if not familiar with Wiki Mark up do to the redefinition of fields
Could cause confusion with some users who copy existing bit of code using the template to set up their own.

User:Kgarrett1969 has offered modifying the existing templates and just adding the tertiary field as the next field, (5). In this implementation there is no redefinition needed on only the addition of the new field. This implementation has been set up in my trinkets and can be found at Template:My trinkets

{{My trinkets|color1|color2|text}}
{{My trinkets|color1|color2|text|color3}}
{{Colorize trinket|color1|color2}}
{{Colorize trinket|color1|color2|ignored|color3}}


Pros

Existing usage works for all trinkets.
Implementation is consistent with current usage.
Easy to maintain. Someone down the road new to the code would not have to work through any redefines to figure out how it works.

Cons

Logically the usage is out of sequence and could cause confusion.
Could be easy for new implementations to be set up out of order.

Please provide feedback and lets make a final decision soon since this upgrade is long overdue. --Kgarrett1969 05:25, 6 March 2008 (PST)/Usage cases added --Alfwyn 05:47, 6 March 2008 (PST)

Well, in my opinion the usage rather then the implementation should be considered, since it is used far more often than changed. That said, the main implementation difference is between {{{text|{{{5|{{{4|}}}}}}}}} and {{{text|{{{4|}}}}}} in the 'My trinkets' code.

Could cause confusion with some users who copy existing bit of code using the template to set up their own.

I don't think this is the case. Copying a three color case and using it for a two color trinket would work in both scenarios more or less like expected:
{{My trinkets|trinket|color1|color2|ignored|text}}
in the first case and
{{My trinkets|triket|color1|color2|text|ignored}}
in the other, work like indicated by the ignored keyword. --Alfwyn 07:03, 6 March 2008 (PST)

The case I'm refering to is when they copy a two color trinket and try to set it up for 3. (Example: Copying {{My trinkets|Parrot feather|red|lime|Some Text}} to {{My trinkets|Plain pin|maroon|yellow|Some Other Text}}) In this case the usage would have an unintended result and could cause confusion in the user trying to figure out why it's not working because of the inconsistency across the usage of the different trinket types. Granted it is a booched usage of the template but I can see a novice user trying this. And it still doesn't deal with the potential for template maintenance in the future. We need to remember that we are having this discussion because the template did need to be updated even though when it was created noone saw a need to allow for a third color. --Kgarrett1969 10:30, 6 March 2008 (PST)
Hm, experimentally that seems to lead in both cases to the same breakage (the third color is not valid), I added the case in both implementations to my sandbox. But yes, the case could be fixed up in your version if you handled an undefined 'tertiray' in 'My trinkets/Plain pin' as a default 'bronze' for example. However I'm not sure that a silent error is to be preferred over a more visible indication that something is wrong. --Alfwyn 10:44, 6 March 2008 (PST)
The joys of templates. Actually you define a default tertiary of 'gold' in 'Plain pin', but 'Colorize trinket' zaps an undefined tertiary to an empty string before 'Plain pin' gets to see it. Not really relevant though I guess. --Alfwyn 11:03, 6 March 2008 (PST)
I looked over your sandbox again and I thought of a couple more cases that should be checked under your implementation. Since it is your sandbox I was wondering if you would like to add them to make sure they work. I presume they will since the two color version works properly. They are {{My trinkets|OM Doll|Eurydice|ignored|ignored|Text}} and {{My trinkets|Skull|ignored|ignored|ignored|Text}}. I can see pirates attempting these for consistancy. --Kgarrett1969 12:33, 6 March 2008 (PST)

Comments

I think I prefer the version suggested by Alfwyn due to the logical order. Although there are various cases in which people might break things, these days there are many helping hands and those my trinkets issues are generally sorted out rather quickly. I do enjoy that fact that the current usages will remain working under either implementation, but the neat freak in me really does prefer to not have to rely upon having the third color out of line order. Although it may be a little more difficult to understand for future changes, it is not impossible especially when taking into consideration how rapidly Alfwyn could figure it out as a somewhat newer editor. Right now just thinking about it, it seems unlikely that there would be a trinket with more than three color options as the leanings of the art department seem to be for clean design instead of color riots in individual items. --Guppymomma 15:04, 6 March 2008 (PST)

Powered by MediaWiki
Attribution

Puzzle Pirates™ © 2001-2016 Grey Havens, LLC All Rights Reserved.   Terms · Privacy · Affiliates