!!!READ ME - 1. Overview, Feature List, Change Log, License.txt 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251
  1. // :SHOW:
  2. // :CATEGORY:NPC
  3. // :NAME:PMAC
  4. // :AUTHOR:Aine Caoimhe
  5. // :KEYWORDS:
  6. // :CREATED:2015-11-24 20:38:40
  7. // :EDITED:2015-11-24 19:38:40
  8. // :ID:1095
  9. // :NUM:1871
  10. // :REV:1
  11. // :WORLD:Second Life
  12. // :DESCRIPTION:
  13. // PARAMOUR MULTI-ANIMATION CONTROLLER (PMAC) v1.02(OSSL)
  14. // :CODE:
  15. // Provided under Creative Commons Attribution-Non-Commercial-ShareAlike 4.0 International license.
  16. // Please be sure you read and adhere to the terms of this license: https://creativecommons.org/licenses/by-nc-sa/4.0/
  17. PARAMOUR MULTI-ANIMATION CONTROLLER (PMAC) v1.02
  18. by Aine Caoimhe (c. LACM) January 2015
  19. **** OVERVIEW *****
  20. The Paramour Multi-Animation Controller (PMAC) is a no-poseball script system
  21. intended for use in
  22. almost any piece of furniture that needs to be able to position and animate
  23. multiple avatars at once.
  24. PMAC is designed to offer a high performance alternative to existing systems
  25. such as MLP, nPose, and
  26. xPose. PMAC uses a core engine that leverages the powerful OSSL functions
  27. available only in Opensim
  28. to drastically increase the script's speed and reliability, while at the same
  29. time using only a
  30. fraction of the sim resources of the existing systems.
  31. ***** KEY FEATURES *****
  32. * WORKS IN ANYTHING - The PMAC system can be put into anything, from a
  33. single-prim scultpy blanket or
  34. one-piece mesh sofa to an elaborate multi-piece bedroom linkset. You can put it
  35. in a simple pine cube
  36. prim if you feel like it. There's nothing extra to attach and hide or position
  37. nearby. All it takes
  38. is a single prim. The only "requirement" is that PMAC must be in the root prim
  39. of an object.
  40. * NO POSEBALLS - There are no poseballs used at all for PMAC. None to disguise
  41. or hide as part of the
  42. furniture, none that have to be rezzed and sat on, none to get lost inside a
  43. sofa or buried underground
  44. or scattered around a sim...all of the users simply sit on the furniture item
  45. that contains the main
  46. script and PMAC takes care of the rest using a "virtual poseball" approach that
  47. exists within the logic of the script.
  48. * A TRUE MULTI-AVATAR CONTROLLER - PMAC systems can be set up to handle
  49. animations designed for 1 to as
  50. many as 9 avatars with the flexibility to load any preset configuration on the
  51. fly. You could set it up
  52. in a sofa to act like a sit AO when you're lounging around alone, and quickly
  53. turn it into a couples
  54. controller when that special someone comes to visit, and then switch it into a
  55. multi-person handler
  56. when you have even more company...and it's all available virtually instantly
  57. from the menu without
  58. the need to stand up or reset...all adjustments are done on the fly during use.
  59. Now your VL furniture
  60. items can be just as flexible as your RL ones are.
  61. * REGION-FRIENDLY - Most multi-avatar controllers are pretty harsh on a
  62. simulator, eating up valuable
  63. cycles, and memory and other script resources. PMAC's extensive use of OSSL
  64. functions allows it to
  65. drastically reduce this overhead. The core PMAC system is a single script. Yep,
  66. a fully functional
  67. controller for up to 9 avi all done with one low-footprint script. When not in
  68. use, it is completely
  69. dormant and uses virtually no simulator resources at all (just the tiny amount
  70. of memory required for
  71. the script itself). Even when in use, the system's footprint barely changes --
  72. unlike SL systems with
  73. poseball scripts, animation handler scripts, multiple timers, multiple
  74. listeners, high message traffic,
  75. large menu memory consumption, and all the other complications that LSL-based
  76. scripts are subject to.
  77. Even with 9 avatars seated all it uses is a single script and single listener.
  78. The only time it ever uses a timer is on those rare occasions when you're
  79. editing positions or setting up a new system.
  80. * SPEED - The total time to initialize a typical PMAC system is approximately
  81. one second. That's right,
  82. just 1 second! If for some reason you need to reset it you'll be ready to use it
  83. again almost instantly.
  84. Due to its unique OSSL-based menu method, PMAC dialogs pop up right away even
  85. for very extensive set-ups
  86. with hundreds of different animations.
  87. * SYNCH - PMAC uses the tried and true Paramour synch method, keeping up to 9
  88. avatars moving in perfect
  89. unison once their animations are in your viewer's cache.
  90. * FULL NPC INTEGRATION - Want some company but none of your friends are online?
  91. PMAC can rez a NPC
  92. (or two, or three, or up to eight!) to join you instead. When you're done, PMAC
  93. tucks them away again
  94. for next time. You can pick who, where, and when at the touch of a few simple
  95. dialog buttons.
  96. * AUTO-MODE - Don't want to have to change your own animations? Simply engage
  97. PMAC's auto mode and
  98. let the system do it for you, more or less like engaging a sit AO for up to 9
  99. people. Timing can be chosen from a variety of options and changed on the fly;
  100. and you can configure the system to engage it automatically so you can have your
  101. furniture fully useable without ever even needing to see a dialog (but of course
  102. you can simply touch the object to bring up the menu and disengage this at any
  103. time).
  104. * SWAPPING - You can quickly and easily swap positions with anyone else -- even
  105. if they aren't there
  106. and it's just an unoccupied "virtual position".
  107. * AUTO HEIGHT ADJUSTMENTS - PMAC automatically adjusts positions based on each
  108. avatar's height (although admittedly this is a very rudimentary estimate and
  109. depends a lot on how the original animation was created). In many cases this
  110. will be sufficient unless you have a very tall or short avatar.
  111. * ON-THE-FLY POSITION ADJUSTMENTS - The owner can make more detailed adjustments
  112. to animation positioning at any time, rapidly and on the fly, and it remains
  113. temporarily stored in the script's memory.
  114. * NO NOTECARD EDITING FOR USERS - If the owner wishes to persist any position
  115. adjustments to the system's notecards, PMAC facilitates this by handling it all
  116. done with the touch of a single dialog button. No more copy-pasting reams of
  117. text from chat into a notecard and hoping you don't mess something up! Typically
  118. the only time you'll manually open and edit a notecard is when making major
  119. changes such as adding new animations or deleting existing ones.
  120. * EASY CONFIGURATION - PMAC can be fully configured in the script or via an
  121. optional configuration notecard which some users might find a little less
  122. intimidating to do.
  123. * USER ACCESS RESTRICTIONS - The PMAC system has a variety of settings allowing
  124. you to control who can use it, who can access which menus or animations, who can
  125. rez which NPCs, and other similar access-control restrictions.
  126. * POWERFULL ADD-ON COMMAND SYSTEM INTEGRATION - As a design goal, I wanted the
  127. PMAC system to be easy and intuitive enough to just "rez and play" without what
  128. can be a rather nasty learning curve of many other systems. I also felt it was
  129. imperative to optimize PMAC's performance, simulator footprint, and XEngine
  130. demands. As a result, only the most important and commonly-demanded features are
  131. part of the core "out of the box" PMAC system. But I also wanted to offer the
  132. flexibility for more advanced builders and users to enhance its functions,
  133. capabilities and offerings, so PMAC incorporates an integrated and extremely
  134. powerful command system that opens up almost endless possibilities via the use
  135. of scripted add-ons. If PMAC doesn't do something you want it to do, it's very
  136. likely that an add-on can be scripted to do it in conjunction with PMAC's
  137. command system -- at the expense of the additional script(s) overhead. I will
  138. likely create add-ons for the most often-requested extra features; but anyone
  139. with reasonable scripting skills can write their own custom applications for
  140. specialized requirements. The only limits are likely to be your imagination (and
  141. ability to script it).
  142. * FREE - The PMAC system is the culmination of many months of work and almost 5
  143. years of development and testing of various approaches to making the "next
  144. generation" multi-avatar controller, and I'm releasing it to the Opensim
  145. community for free (under Creative Commons Attribution-Non-Commercial-ShareAlike
  146. 4.0 International license). Any add-ons I create for it in future will be free,
  147. too, and I sincerely hope that other add-on creators will follow suit and donate
  148. their enhancements to the community as well.
  149. * COMPANION MLP CONVERTER - Thanks to Seth Nygard, existing MLP 2.x systems can
  150. be easily converted to PMAC in a matter of minutes using a supplied conversion
  151. script. Look for the "PMAC Builder's Kit" which contains everything you need to
  152. take an existing MLP system and turn it into a PMAC system.
  153. ***** CHANGE LOG *****
  154. v. 1.0 January 2015 (Initial beta release)
  155. v. 1.01 March 2015 (General release)
  156. - NEW: added ability to supply a configuration notecard that will be read on
  157. initialization and override scripted variable values (written by Seth Nygard -
  158. thanks Seth!)
  159. - TWEAK: tweaked Seth's configuration addition to support both his nameset as
  160. well as the actual variable names being supplied
  161. - TWEAK: slight further optimizations of memory use
  162. - TWEAK: system is now made completely inactive if worn
  163. - TWEAK: only owner is now notified when initialization completes
  164. - FIX: minor text tweaks and typo corrections
  165. v 1.02 May 2015 (Update Release)
  166. - BUGFIX/OVERSIGHT: add flag so if an addon rezzes an object core is prevented
  167. from interpreting this as an edit handle being rezzed and entering edit mode
  168. - BUGFIX: fixed a bug in edit mode list wrapping where advancing from the last
  169. animation in a group using "NEXT" would pull the incorrect data for the next
  170. (first) animation.
  171. - TWEAK: set a minimal sit target on root to allow sitting on it from distances
  172. greater than 10m
  173. - TWEAK: When displaying animation number range in dialog menu, display the
  174. actual range instead of possible range
  175. - NEW: added support for the Object-Rezzing prop add-on "NC_PROP" by Neo Cortex
  176. (code from Neo)
  177. - NEW/TWEAK: Altered script logic to optionally allow NPCs to occupy a PMAC
  178. object with no "real" avatars being present and added a user configuration
  179. variable to enable or disable this feature. By default it will be set to FALSE.
  180. If the NPC is to be rezzed by another object/script that script will also need
  181. to handle seating it, later unseating it, and removing it from the scene.
  182. Initially rezzing a PMAC NPC still requires an avatar user but if that user
  183. stands when NPC flag is TRUE, the NPC will not be removed (I'll need to sit down
  184. again and remove it). Be careful NOT to reset the core script when a PMAC NPC is
  185. still in the scene since this will strand it.
  186. - NEW/TWEAK: Added new user option to show the groups menu instead of the
  187. current group's animation menu when you first initiate the dialog. Subsequently
  188. if you close the dialog and re-show it, you should received whatever your most
  189. recent dialog was unless someone else was in control in the interim.
  190. **** UPDATING FROM PMAC 1.01 TO PMAC 1.02 *****
  191. - if you use in-script user settings instead of the configuration notecard,
  192. transfer your settings to the PMAC core 1.02 script.
  193. - delete the Core 1.01 script from your object's inventory
  194. - place a copy of the Core 1.02 script into the object's inventory - it should
  195. compile and enable itself automatically
  196. - replace the old READ ME 1 and READ ME 2 notecards with the updated versions.
  197. The other three core read me notecards remain unchanged.
  198. - no further changes are require...your system is ready for use
  199. - OPTIONAL: if you want to use the new object-rezzer add-on by Neo Cortex, place
  200. a copy of it in the object's inventory and follow the instructions he supplied
  201. for setting up your animations to use it. The MLP parser by Seth Nygard does not
  202. currently support conversion of MLP rezzed objects so you will need to do this
  203. manually.
  204. ***** LICENSE *****
  205. All PMAC scripts and documentation are my own creation and released under
  206. Creative Commons Attribution-Non-Commercial-ShareAlike 4.0 International
  207. license. Please be sure you read and adhere to the terms:
  208. https://creativecommons.org/licenses/by-nc-sa/4.0/
  209. Unless otherwise specified, animations contained in any Paramour product are
  210. *not* my creation but were obtained under equivalent CC terms. If you are the
  211. creator of one of the animations and do not wish it distributed please notify me
  212. and I will immediately remove it from all current and future offerings.
  213. ***** CONTACT *****
  214. You can most easily contact me in world at refugegrid.com:8002 or on G+