Update comments

10/31/18: Generic Favorite Picker

Jeez, this took a while. Finally (finally) the generic Favorite Pokémon Picker code is now available on GitHub with some instructions and documentation to enable you to create your own favorite pickers for anything you want. It should be possible for you to make a basic picker even without knowing any programming whatsoever, and if you know some HTML and just a smidge of JavaScript you should be able to get pretty far on that too.

There are things I've already realized I really need to do differently/better to make it nicer, but it has been long enough. Please go nuts making your own pickers!

Additionally, the actual Favorite Pokémon Picker is now running on the generic version. It still works the same way as before (hopefully), but as always, if anything's weird, please let me know.

Comment on this - View comments

Post comment

Rude, offensive or otherwise inappropriate messages, including drama, controversy or other topics that might make others uncomfortable, will be deleted on sight. Repeat troublemakers will be banned altogether. Please keep any websites entered into the website field reasonably family-friendly. You can use BBCode (forum code) to format your messages.

  • [b]Bold[/b]
  • [i]Italic[/i]
  • [u]Underlined[/u]
  • [s]Strikethrough[/s]
  • [url=http://www.dragonflycave.com]Link[/url]
  • [spoiler]Spoiler[/spoiler]
655 Fun fact: The above sprite has a 1/8192 chance of being shiny. Feel free to brag if you get one.

Comments

My own messages will be signed as Butterfree, with the Admin label below my name. If someone signs as Butterfree without that label, it's probably not me.

Butterfree
Admin
Website: The Cave of Dragonflies
Commenting on: 10-31-18

The number of items that need to be eliminated before finding your next favorite is the number of items in the current, survived and evaluating arrays put together, minus one. So you could display that number on the page with something like:

var pickerUI = new PickerUI(myPicker, {
elements: {
pick: "#pick",
pass: "#pass",
undo: "#undo",
redo: "#redo",
evaluating: "#evaluating",
favorites: "#favorites"
},
onUpdate: function() {
var arrays = this.picker.state.arrays;
$("#remaining").text(arrays.current.length + arrays.survived.length + arrays.evaluating.length - 1);
});

…assuming that you've got an element with id="remaining".

Note that that's the number of items that need to be eliminated, not the number of choices, though; the number of choices is impossible to determine because that's going to depend on how many items the user picks in each round.

[04/11/2018 00:22:22]

Austen Weissmiller
Commenting on: 10-31-18

Is there a way to get the number of choices left before getting to your favorite?

[03/11/2018 23:56:03]

Page last modified April 17 2018 at 22:56 GMT