README.rst 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. ===================
  2. Pelican Unity WebGL
  3. ===================
  4. Compatibility
  5. =============
  6. Unity >= 5.6 (Tested on 5.6)
  7. Usage
  8. =====
  9. Basic directive
  10. ---------------
  11. .. code-block:: rst
  12. .. unitywebgl GAME_ID
  13. **GAME_ID** is the required parameter. This is name of the directory, that contains your webgl build. This directory should be place in path, specified in config.py file, or with :gameroot: parameter.
  14. Optional parameters
  15. -------------------
  16. .. code-block:: rst
  17. .. unitywebgl GAME_ID
  18. :gameroot: /games/new/
  19. :template: /games/templates/newtemplate
  20. :width: 640
  21. :height: 480
  22. +-------------------+------------------+---------------------------------------------------------+
  23. | Parameter | default value | |
  24. +===================+==================+=========================================================+
  25. | gameroot | /games | path to directory with games |
  26. +-------------------+------------------+---------------------------------------------------------+
  27. | templatepath | /games/utemplate | path to template |
  28. +-------------------+------------------+---------------------------------------------------------+
  29. | width | |
  30. +-------------------+ Player resolution |
  31. | height | |
  32. +-------------------+------------------+---------------------------------------------------------+
  33. .. note::
  34. Test pelican project can be found in *pelican_demo.zip* archive `here <https://github.com/mrpeidz/Unity-WebGL-RST-directive>`_
  35. Configuration
  36. =============
  37. You can change default root directory, template path and player resolution in the *config.py* file.
  38. Modifying html output template
  39. ------------------------------
  40. You can modify the *template.txt* file to change html output.
  41. Template parameters explanation:
  42. +-------------------+-------------------------------+
  43. | Parameter | default value |
  44. +===================+===============================+
  45. | 0 | game directory name |
  46. +-------------------+-------------------------------+
  47. | 1 | directory, where games placed |
  48. +-------------------+-------------------------------+
  49. | 2 | template directory |
  50. +-------------------+-------------------------------+
  51. | 3 | width |
  52. +-------------------+-------------------------------+
  53. | 4 | height |
  54. +-------------------+-------------------------------+
  55. About
  56. =======
  57. License: `MIT <https://opensource.org/licenses/MIT>`_
  58. `Unity WebGL RST Directive github page <https://github.com/mrpeidz/Unity-WebGL-RST-directive>`_
  59. **Mr.Page (c) 2017**