TabletopTools icon indicating copy to clipboard operation
TabletopTools copied to clipboard

Add possibility of hit vs miss, and glitches

Open mmahmoudian opened this issue 3 years ago • 5 comments

Is your feature request related to a problem? Please describe. No

Describe the solution you'd like In some games like Shadowrun the player have to throw n die and then if any dice value is less than or equal to x (e.g 1) it will be considered as miss. Then if number of misses is more than hits, it will be a glitch

Describe alternatives you've considered Don't have any idea at this point about alternative, sorry.

Additional context -- not applicable --

mmahmoudian avatar Jun 03 '22 14:06 mmahmoudian

For this feature you need two sliders, one for the "less than" value and one for the number of hits?

I guess I add a setting to hide/show the new sliders to keep (for some people) unwanted sliders away.

mueller-ma avatar Jun 10 '22 08:06 mueller-ma

Can you share a link to the game rules of Shadowrun? It can be implemented in Hacktoberfest.

mueller-ma avatar Sep 17 '22 12:09 mueller-ma

Thank you for getting back on this, I believe this link is correct:

https://www.shadowrunsixthworld.com/resources/

mmahmoudian avatar Sep 17 '22 12:09 mmahmoudian

@mueller-ma

I might have a go at this.

If you have specific design requirements, especially regarding the slider hiding, then please elaborate.

theAkito avatar Oct 29 '22 12:10 theAkito

Please add one switch in the settings for both new sliders, like the "increment" slider:

  • https://github.com/mueller-ma/TabletopTools/blob/main/app/src/main/res/xml/pref_main.xml#L20-L23
  • Use the following function to read preferences: https://github.com/mueller-ma/TabletopTools/blob/main/app/src/main/java/com/github/muellerma/tabletoptools/utils/Prefs.kt#L21-L22
  • And show or hide the slider: https://github.com/mueller-ma/TabletopTools/blob/main/app/src/main/java/com/github/muellerma/tabletoptools/ui/fragments/DicesFragment.kt#L42-L44

mueller-ma avatar Oct 30 '22 07:10 mueller-ma