Skip to content

Instantly share code, notes, and snippets.

@kinsteronline
Created April 23, 2014 20:45
Show Gist options
  • Save kinsteronline/11231760 to your computer and use it in GitHub Desktop.
Save kinsteronline/11231760 to your computer and use it in GitHub Desktop.
Pick what you need from a hash
warrior = { str: 17, int: 8, dex: 12, con: 16, luk: 10 }
strength, dexterity, luck = warrior.values_at(:str, :dex, :luk)
to_hit = strength ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment