Saturday, 7 November 2015

TRANSCRIPT: Immersive Edge PMAC Presentation

Today I gave a presentation about the PMAC system for the Immersive Edge project. Due to a few technical issues some of you may have missed part of the presentation so I thought I'd give you a transcript so you'll be able to read the full text if you'd like.

Hello everyone. My name is Aine Caoimhe and I'm the creator of the PMAC system -- one of the tools that was used by many of the creators for this Hypergrid Story project.

My presentation today will be an introduction to the system to give you an idea of what it is and how it could be useful to you, not only if you undertake a project like Immersive Edge, more generally for your regions or for other special projects.

I'll ask you to hold any questions until the end of my presentation, at which point I'll be happy to answer any general ones you might have. For any specific or special-case questions please speak with me afterwards.

Let's get started!

PMAC is an acronym for "Paramour Multi-Animation Controller" -- Paramour is the brand name I've been using for most of my products since my original store in my Paramour Winery region in OSGrid almost 6 years ago. Most of you will know me best as the creator of the Paramour Dancemaster danceball you'll see used throughout the Metaverse, as well as a variety of other related club items that involve animations and NPCs. I suppose you could say that working with those two elements of Opensim is one of my specialties.

PMAC is my most recent major script system that was first released to the public in March of this year, but its genesis was about 4 years ago as I began to look for a better alternative to the well-known MLP system that is commonly found in various furniture in SL and Opensim. I was looking for something that was far less demanding on the simulator, was easier to use -- and particularly to set up! -- and had a lot more flexibility than MLP and  other such systems offer.

Unfortunately, such an alternative didn't exist so I began the process of scripting one. Four years later, after a lot of testing and refinement, I released PMAC to the public.

When I mention "MLP" most of you will instantly think "sex bed" but MLP can actually be used for lots of PG-rated activities, too. The lack of variety you see is probably more a product of MLP being very non-user-friendly for setting up and adjusting.

The core need of a system like this is for two people to be placed in a set position and with synchronized animations, and to be able to change those. It doesn't matter if they're animations for dancing, standing around chatting, sitting on a sofa, or other more R-rated pursuits...the fundamental function remains the same.

Let's look at the key features I designed the PMAC system to provide, since that describes most of what PMAC does.

(each item in the list was uncovered, one by one, as
I spoke about it in the text that follows)

The PMAC system is a script that is placed in something that sits in a region, along with some animations and some information about how to play them.

I wanted the flexibility to be able to put it into any object...a bed, a sofa, even a single prim, sculptie, or mesh...anything! Being able to work with a single-prim object was a critical requirement. Of course it works quite happily in linksets too.

Here's a surprise for you: I'm using PMAC to do this presentation. The panel you see behind me is a simple, single prim cube with the PMAC script inside it. I'm “sitting” on it and it's controlling my position and animations...and much more!

My experience with MLP put the next feature almost at the top of my priority list: no poseballs!

As a scripter, any time you rez a poseball you have to worry about *where* to rez it...can the user see it? Can they sit on it? What if the user crashes? How do you ensure that you don't end up stranding a bunch of poseballs in a sim?

For the user, it's much easier and more intuitive to just sit on something. You don't want to have to touch it, respond to a dialog or two, wait for a pair of poseballs to rez, then sit on the right's an immersion killer and cumbersome.

PMAC works entirely without poseballs. You just sit on the object and it takes care of the rest.

Next on my list, I didn't want to be confined to only 2 users. For some things – like a large multi-person sofa – I wanted the flexibility of controlling the position and animations played by 3 users...or the end I set the limit at 9.

In reality, with only a very minor script modification PMAC can support even more...potentially up to 65 simultaneous users which is the viewer's limit for avatar display.

As you can see, it also happily accommodates just one.

I do a lot of work with NPCs as an integral part of my builds and as a fun extra component for many of my products. I'm sure anyone who has seen my danceball system has danced with a NPC partner (or at least seen someone else do so). It was imperative that PMAC not only support NPCs but actively include their use as a core feature.

Any position that an avatar can occupy can also have a NPC there, and as of version 1.02 it's even possible to have a PMAC object occupied only by one or more NPCs, as you'll see throughout Immersive Edge. PMAC happily accepts NPCs rezzed by other scripts and told to sit on it, but it also has a fully integrated NPC controller to rez and later remove NPCs. When you use PMAC to handle the NPC, you choose from a list of all available NPCs in its inventory and you can even select the same NPC more than once.

I'm asking a couple Ruths to join me using PMAC's integrated control. I use Ruth because she travels easily between grids and rezzes quickly but you can use *any* NPC appearance notecard. Your NPC doesn't even have to look like an could just as easily be an invisible NPC wearing a tree, or a house, or....anything!

I wanted any user to be able to be “in control” of the system – to be able to pick which animation is being played.

It doesn't matter what order you sit's the first person to subsequently activate the dialog system who becomes the initial “controller” of the object.

While from a practicality standpoint only one user can be in control, it is important to be able to switch that during use in case someone else wants to pick the animations you're collectively playing. That's particularly important in a case where the current controller either crashes or goes unexpectedly AFK...another user would need to be able to take over.

PMAC can also be configured to only allow the owner to be in control for applications where that's important.

I also wanted to make the potential uses for a single object to be as flexible as possible.

As an example think of a large sofa. I might want it to be able to accommodate perhaps 3 or 4 avatars seated on it when I'm entertaining guests, but I might also want it to be a nice place to cuddle with a special someone, or to get even Or if I'm by myself maybe I just want to sit and relax there...or lie down for a snooze.

I wanted to be able to have all of that in one sofa, with one script, with one configuration, and then just pick which of those options I want to play at any given moment. I also wanted to limit who could access which of those options. PMAC allows all of that, and handles it on the fly!

To put it bluntly, MLP is a beast on sim resources, particularly when it's in use. It's even worse while it's initializing. I wanted something that didn't eat up unnecessary resources.

My target for PMAC was much the same as all my other products: close to zero footprint on the sim when it's idle, and only minimal overhead when you're using it. Using OSSL functions I was able to achieve that.

For those who aren't familiar with OSSL, these are additional special scripting functions only available in Opensim. They are usually a lot more powerful, and often a lot more efficient, but they also need to be handled with some care. PMAC makes use of OSSL functions that allows it to do things that are impossible in SL or require work-arounds that use a lot more resources.

The functions it uses are mostly the same ones my danceball needs, so if you have one of those in your region PMAC may not require any additional Opensim configuration.  It does use one or two additional ones that might need to be added to your permissions.

MLP also requires a large number of scripts to work. The typical set-up – even a very small one – will have at least 6 and often more. Each of those eats resources and simulator memory, even when idle.

Thanks to OSSL, PMAC only needs a single script to achieve *all* core functionality. and uses virtually no resources until someone sits. When active, PMAC consumes about 1/20th of the resources of a comparable MLP system. For large, complex set-ups, the relative footprint is even less.

Another common issue with MLP is the frequency of it having issues that require a restart. MLP's reset often takes a very long time and consumes a huge amount of sim resources. Recent versions of MLP are more stable, but that start-up time and resource use is still nasty. It can easily take 30 seconds for even a relatively modest system and consumes more than 1500ms of script frame time!

During use, larger MLP systems tend to be very slow since they hold and work with the entire setup at all times, which makes it more prone to glitches. It also has to keep everything in memory, even when idle, giving it a large footprint, sometimes bordering on the maximum allowed script memory.

PMAC uses a real-time data reading and handling method that allows it to hold only the current menu and a couple other pieces of data in memory. This makes it blisteringly fast to start, much faster when navigating menus, and far less prone to problems, even in very large, complex set-ups. A typical PMAC system reset takes less than a second and uses under 100ms of frame time, It rarely uses more than a tiny fraction of a script's memory limit.

A small but important feature...the system needs a “synch” function that works!

It's impossible to properly synch animations for someone if they don't already have them cached in their viewers; but once received, you should be able to click a “synch” button and have it work. A change made to the Opensim code in 2012 broke the synch function in most scripts. I pioneered a fix for that which PMAC uses, but many other systems (like most MLP ones) are still broken.

I also wanted PMAC to have an “Auto" mode where it could play a series of animations without any need for a user to be controlling it via its dialog menus. This flexibility helps with immersion, reduces distractions, and also lets it be used as a sort of multi-person AO which is great for some applications. You can easily switch in and out of auto on the fly.

This also allows PMAC to be used only by NPCs (who can't operate dialogs). It's that capability that helped make it such a useful tool for Immersive Edge where it can work without any “live” input from its users.

Position-swapping is another important feature and is further enhanced by being something you can do on the fly to *any* position at any time, even if nobody else is using it.

For a sofa, a single pose might have an animation and position for the left side, another for the middle, and a third for the right. While playing that pose, you can swap back and forth between positions, even if it's empty. If you're by yourself it gives you three different places to sit...all with just one pose. You will continue to use that swapped position's locations and animations as you cycle through other poses in that menu, until you swap again.

This can turn a single, simple set-up into an incredibly flexible piece of furniture that's suitable for a wide a variety of situations.

It's hard to convey just how powerful this feature can be until you actually play with it.

Anyone who has owned a MLP system shudders when they think about any need to edit or tweak positions. It involves jumping through a bunch of hoops, a lot of copy-paste (that also makes subsequent loading a lot slower), is very prone to introducing errors, and requires a full system reset afterwards.

PMAC makes changing positions easy and as fool-proof as possible. You enter edit mode, move some handles around which the users follow, then click "store" on the dialog. PMAC takes care of the rest, rapidly and flawlessly, without you ever needing to open the notecard.

You have the choice of whether to make the change a temporary one that only lasts for the current session, or one that is persisted to the notecard for all subsequent uses. No system reset is's all done on the fly.

It's even scarier to set up a MLP system from scratch. Most people don't even try. I won't lie and say that PMAC is child's play, but I *do* think it's a lot easier than MLP.

I won't detail it here, but I supply full instructions in the system's “Read Me” notecards and in an extended tutorial on my blog (I'll give you the blog address at the end).

Given how deeply entrenched MLP is in Opensim, I knew that any chance for PMAC to become successful and widely-used would depend making it possible for someone who knows nothing about how this stuff works to convert an existing MLP system into a PMAC system. Thankfully, Seth Nygard rose to the challenge when I presented it to him and wrote a nifty little utility script that does it all automatically for you.

A complete novice can convert even the largest MLP system in less than 5 minutes following a few simple instructions.

There are times where you might want to limit a system's use to only the owner, or only a group of people, or you might have a special menu or a special NPC that you only want visible to you but not to anyone else who's using it.

PMAC has very flexible setup and configuration controls that require almost no scripting knowledge and lets you do this, as well as set many other useful options. All of PMAC's configuration options can either be set directly in the script, or in an optional configuration notecard that PMAC looks for and reads if it's present. The default values are usually fine for most set-ups, though, and won't require any adjustments.

It's very hard to limit myself to only a short synopsis of PMAC's Add-On feature. In my mind it's the single most powerful capability that PMAC offers. It's also the only one that requires a fairly high degree of scripting knowledge so I'll try to be brief and stick to layman's terms as I give you a little taste of what's possible.

I wanted PMAC to be very efficient, but I also wanted it to be capable of many of diverse specialized or custom applications. Those two design goals almost never go together.

My solution was to keep the core PMAC system as slimmed down and minimal as possible, since that's both ideal and sufficient for most general set-ups. I then added a set of special "hooks" to the core script, allowing it to communicate back and forth with additional, exterior scripts -- what I call "add-ons" -- but these hooks result in only a tiny increase PMAC's resource footprint. This allows additional scripts to provide extra capabilities for special situations or custom needs, but only if they're needed. If they aren't, you omit them and save the resources.

Now the sneaky part: you can write add-ons that are just as flexible and versatile and novice-friendly as PMAC is, building up a library of them and sharing them with others. PMAC already has half a dozen of these. Neo Cortex wrote one that rezzes objects, Aaack Aardvark wrote one to hand the user an object, and I've written a handful of other ones that do a variety of useful things.

For today, I wrote the one that's handling the changing textures on the board behind me and is delivering the text of this presentation. PMAC and my little custom add-on are doing the rest.

You can also use add-ons to move things, or hide and un-hide things anywhere in the region, or send commands to turn lights on or off, or even change windlight settings or music streams. All at a per-animation level!

There are other applications for the system that I might not need, but other users would. Rather than exclude that possibility, PMAC is designed to supprt them. This includes, but isn't limited to, full compatibility with RLV and other such systems. PMAC doesn't have it in its core, but fully supports it being added and integrated by someone else fairly easily using the add-on hooks I've supplied.

There are countless other possibilities that I haven't even thought of. The add-on system makes PMAC's capabilities limited only by your imagination and scripting abilities. PMAC is designed with this flexibility as a core component so you don't have to re-invent the wheel to do something new. You just plug into its hooks.

A good example of this is the way PMAC and Fred's NPC controller script were able to work in concert with one another throughout the Hypergrid Story project even though neither was designed with the other in mind. Immersive Edge's creators had a lot of the very innovative ideas and, between Fred, Neo and I, those were made achievable with a few minor modifications or special add-ons to our respective scripts.

Fred will be doing a presentation for his excellent NPC controller system tomorrow at this time which I encourage you not to miss!

Another goal was to make PMAC as intuitive as possible for a user. You just want to sit on an object to play right away without having to read instructions or know anything at all about how it works.

I used a fairly MLP-like menu structure since I expected many people to already be familiar with that and not want to learn something new. Most novice users also seem to find it pretty simple.

Being an owner of a system is a little bit more involved. You *do* need to ensure that your region is configured to let you to use the OSSL functions that PMAC requires, but any region that has my danceball in it will probably already have this. Otherwise you can usually rez and start using a pre-made PMAC system right away, or quickly convert an MLP set-up.

Reconfiguring or setting up your own system from scratch is a little more complex, but I have written a few blog tutorials that cover the basics. There are also detailed Read Me notecards supplied with the system. I won't say it's easy, but it's much, much easier -- and I hope more intuitive -- than attempting to do the same with MLP.

I supply extensive documentation with the system about how it works, how to set it up, how to modify it, and all of the other necessary information to unleash its power. Those "Read Me" notecards should answer almost all general use questions.

As I mentioned earlier, I've also posted some tutorials on my blog with even more detailed step-by-step instructions for some of the more common things you might want to do.

I'm also happy to answer your questions about it when I'm in world (but please check the other documentation first).

One final, absolutely essential PMAC feature: it's completely free!

The hundreds of hours of scripting and testing that went into PMAC are part of my donation back to the community. The entire PMAC system is full perm and released under Creative Commons Attribution-Non-Commercial-ShareAlike 4.0 International license. That means you can modify it, re-distribute it, or give away objects made with it. The only restrictions are that you can't sell it – or systems that use it – for money without separately obtaining my permission to do so; and you need to credit me for the original scripts.

I have no objection to people profiting from their own work and creations, as long as they're not lining their pockets with mine.

This concludes my presentation which, I hope, has given you a good overview of what PMAC has to offer and the huge range of possibilities for it's use.

You can see it in action in many of the Immersive Edge regions and I also have a full working version of it for you to play with at your leisure in my Paramour region on RefugeGrid.

The current version of the complete boxed system as well as all the various add-ons are available in my main Paramour Shopping region in RefugeGrid. There are boxed copies of it here, in Nara's Nook, and a number of other places throughout the Metaverse. You can also check my blog any time to find out what the most current version is, what add-ons are available, and other related news.

Thank you all for coming, and I hope you enjoy your visit.