Skip to content

Commit

Permalink
now illustrated
Browse files Browse the repository at this point in the history
  • Loading branch information
ShawnDriscoll committed Oct 27, 2017
1 parent b271ce1 commit 132d390
Show file tree
Hide file tree
Showing 38 changed files with 55 additions and 14 deletions.
Binary file modified docs/build/.doctrees/debugging.doctree
Binary file not shown.
Binary file modified docs/build/.doctrees/environment.pickle
Binary file not shown.
Binary file modified docs/build/.doctrees/introduction.doctree
Binary file not shown.
Binary file modified docs/build/.doctrees/samples.doctree
Binary file not shown.
Binary file modified docs/build/.doctrees/tutorial.doctree
Binary file not shown.
Binary file added docs/build/_images/broken_die.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/build/_images/dice_tut.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/build/_images/egg.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/build/_images/fake_die.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/build/_images/python_file.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/build/_images/python_package.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/build/_images/python_screen.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/build/_images/requirements.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 4 additions & 1 deletion docs/build/debugging.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ <h3>Navigation</h3>

<div class="section" id="debugging-diceroll">
<h1><strong>Debugging diceroll</strong><a class="headerlink" href="#debugging-diceroll" title="Permalink to this headline"></a></h1>
<div class="figure">
<img alt="_images/fake_die.png" src="_images/fake_die.png" />
</div>
<p><strong>diceroll 2.4</strong> keeps a log file of any dice rolls made during its last run. You will find <tt class="docutils literal"><span class="pre">diceroll.log</span></tt> in the <tt class="docutils literal"><span class="pre">Logs</span></tt>
folder it creates if one isn't there already. In the file you will see mentions of dice being rolled. <strong>diceroll</strong> uses
a default logging mode of <tt class="docutils literal"><span class="pre">INFO</span></tt> which isn't that verbose.</p>
Expand Down Expand Up @@ -133,7 +136,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/build/designers_notes.html
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/build/diceroll.html
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/build/genindex.html
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/build/glossary.html
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/build/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
14 changes: 13 additions & 1 deletion docs/build/introduction.html
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,9 @@ <h2>Preface<a class="headerlink" href="#preface" title="Permalink to this headli
</div>
<div class="section" id="requirements">
<h2>Requirements<a class="headerlink" href="#requirements" title="Permalink to this headline"></a></h2>
<div class="figure">
<img alt="_images/requirements.png" src="_images/requirements.png" />
</div>
<ul>
<li><p class="first"><strong>Microsoft Windows</strong></p>
<blockquote>
Expand Down Expand Up @@ -108,6 +111,9 @@ <h2>Requirements<a class="headerlink" href="#requirements" title="Permalink to t
</div>
<div class="section" id="installing-locally-to-your-folder">
<h2>Installing Locally to your Folder<a class="headerlink" href="#installing-locally-to-your-folder" title="Permalink to this headline"></a></h2>
<div class="figure">
<img alt="_images/python_file.png" src="_images/python_file.png" />
</div>
<p>Installing <strong>diceroll 2.4</strong> is as easy as always. Just copy <tt class="docutils literal"><span class="pre">diceroll.py</span></tt> into the same folder
your code happens to be in.</p>
<p>Then add this line at (or near) the top of your code:</p>
Expand All @@ -116,6 +122,9 @@ <h2>Installing Locally to your Folder<a class="headerlink" href="#installing-loc
</div>
<div class="section" id="installing-as-a-package">
<h2>Installing as a Package<a class="headerlink" href="#installing-as-a-package" title="Permalink to this headline"></a></h2>
<div class="figure">
<img alt="_images/python_package.png" src="_images/python_package.png" />
</div>
<p>If your code setup is different, in that you like to keep your function modules in a folder separate
from your main code, you could copy <tt class="docutils literal"><span class="pre">diceroll.py</span></tt> into that folder.</p>
<p>Say you have a folder called <tt class="docutils literal"><span class="pre">game_utils</span></tt>, and assuming you have an <tt class="docutils literal"><span class="pre">__init__.py</span></tt> inside it, just copy <tt class="docutils literal"><span class="pre">diceroll.py</span></tt>
Expand All @@ -125,6 +134,9 @@ <h2>Installing as a Package<a class="headerlink" href="#installing-as-a-package"
</div>
<div class="section" id="installing-automatically">
<h2>Installing Automatically<a class="headerlink" href="#installing-automatically" title="Permalink to this headline"></a></h2>
<div class="figure">
<img alt="_images/egg.png" src="_images/egg.png" />
</div>
<p><em>New in version 2.3</em></p>
<p>Extract <tt class="docutils literal"><span class="pre">diceroll_2.4.0b.zip</span></tt> and start a CMD window at the folder location of the <tt class="docutils literal"><span class="pre">setup.py</span></tt> file. At the
CMD prompt you can type:</p>
Expand Down Expand Up @@ -220,7 +232,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/build/license.html
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
4 changes: 2 additions & 2 deletions docs/build/modindex.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<link rel="index" title="Global index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="top" title="diceroll 2.4 Operations Manual" href="index.html" />
<generator object at 0x03855C60>
<generator object at 0x038C27D8>

<script type="text/javascript">
DOCUMENTATION_OPTIONS.COLLAPSE_MODINDEX = true;
Expand Down Expand Up @@ -92,7 +92,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
8 changes: 7 additions & 1 deletion docs/build/samples.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ <h3>Navigation</h3>

<div class="section" id="using-roll-in-your-own-code">
<h1><strong>Using roll() in Your Own Code</strong><a class="headerlink" href="#using-roll-in-your-own-code" title="Permalink to this headline"></a></h1>
<div class="figure">
<img alt="_images/python_screen.png" src="_images/python_screen.png" />
</div>
<div class="section" id="for-simple-die-rolls">
<h2>For Simple Die Rolls<a class="headerlink" href="#for-simple-die-rolls" title="Permalink to this headline"></a></h2>
<p>Sample Outputting of Die Rolls:</p>
Expand Down Expand Up @@ -110,6 +113,9 @@ <h2>For Probabilites<a class="headerlink" href="#for-probabilites" title="Permal
</div>
<div class="section" id="for-repairing-game-code">
<h2>For Repairing Game Code<a class="headerlink" href="#for-repairing-game-code" title="Permalink to this headline"></a></h2>
<div class="figure">
<img alt="_images/broken_die.png" src="_images/broken_die.png" />
</div>
<p>Often times, game code will be downloaded or found that contains
incorrect <tt class="docutils literal"><span class="pre">randint()</span></tt> calls for rolling two 6-sided dice. A line such as:</p>
<div class="highlight"><pre><span class="n">world_size</span> <span class="o">=</span> <span class="n">randint</span><span class="p">(</span><span class="mi">2</span><span class="p">,</span> <span class="mi">12</span><span class="p">)</span> <span class="o">-</span> <span class="mi">2</span>
Expand Down Expand Up @@ -185,7 +191,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
4 changes: 2 additions & 2 deletions docs/build/search.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<link rel="index" title="Global index" href="genindex.html" />
<link rel="search" title="Search" href="" />
<link rel="top" title="diceroll 2.4 Operations Manual" href="index.html" />
<generator object at 0x035AF648>
<generator object at 0x039FB1C0>
<script type="text/javascript" src="_static/searchtools.js"></script>

</head>
Expand Down Expand Up @@ -83,7 +83,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
5 changes: 4 additions & 1 deletion docs/build/tutorial.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ <h3>Navigation</h3>

<div class="section" id="diceroll-tutorial">
<h1><strong>diceroll Tutorial</strong><a class="headerlink" href="#diceroll-tutorial" title="Permalink to this headline"></a></h1>
<div class="figure">
<img alt="_images/dice_tut.png" src="_images/dice_tut.png" />
</div>
<div class="section" id="rolling-the-dice">
<h2>Rolling the Dice<a class="headerlink" href="#rolling-the-dice" title="Permalink to this headline"></a></h2>
<p>Once <tt class="docutils literal"><span class="pre">diceroll.py</span></tt> is installed and your code is able to import the module, its <tt class="docutils literal"><span class="pre">roll()</span></tt> function can be
Expand Down Expand Up @@ -174,7 +177,7 @@ <h3>Navigation</h3>
</div>
<div class="footer">
&copy; Copyright 2017, SHONNER CORP.
Last updated on Oct 26, 2017.
Last updated on Oct 27, 2017.
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a>.
</div>
</body>
Expand Down
Binary file added docs/source/broken_die.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/source/debugging.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
**Debugging diceroll**
=======================

.. figure:: fake_die.png

**diceroll 2.4** keeps a log file of any dice rolls made during its last run. You will find ``diceroll.log`` in the ``Logs``
folder it creates if one isn't there already. In the file you will see mentions of dice being rolled. **diceroll** uses
a default logging mode of ``INFO`` which isn't that verbose. ::
Expand Down
Binary file added docs/source/dice_tut.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/egg.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/fake_die.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions docs/source/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ worth their going into.
Requirements
------------

.. figure:: requirements.png

* **Microsoft Windows**

**diceroll** has been tested on Windows versions: XP, 7, 8, and 10.
Expand Down Expand Up @@ -62,6 +64,8 @@ Requirements
Installing Locally to your Folder
---------------------------------

.. figure:: python_file.png

Installing **diceroll 2.4** is as easy as always. Just copy ``diceroll.py`` into the same folder
your code happens to be in.

Expand All @@ -72,6 +76,8 @@ Then add this line at (or near) the top of your code: ::
Installing as a Package
-----------------------

.. figure:: python_package.png

If your code setup is different, in that you like to keep your function modules in a folder separate
from your main code, you could copy ``diceroll.py`` into that folder.

Expand All @@ -83,6 +89,8 @@ into your ``game_utils`` folder and add this line near the top of your code: ::
Installing Automatically
------------------------

.. figure:: egg.png

*New in version 2.3*

Extract ``diceroll_2.4.0b.zip`` and start a CMD window at the folder location of the ``setup.py`` file. At the
Expand Down
Binary file added docs/source/python_600x600.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/python_file.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/python_package.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/python_screen.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/requirements.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions docs/source/samples.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
**Using roll() in Your Own Code**
=================================

.. figure:: python_screen.png

For Simple Die Rolls
--------------------

Expand Down Expand Up @@ -64,6 +66,8 @@ Sample Task Resolution: ::
For Repairing Game Code
-----------------------

.. figure:: broken_die.png

Often times, game code will be downloaded or found that contains
incorrect ``randint()`` calls for rolling two 6-sided dice. A line such as: ::

Expand Down
2 changes: 2 additions & 0 deletions docs/source/tutorial.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
**diceroll Tutorial**
=====================

.. figure:: dice_tut.png

Rolling the Dice
----------------
Once ``diceroll.py`` is installed and your code is able to import the module, its ``roll()`` function can be
Expand Down

0 comments on commit 132d390

Please sign in to comment.