Thanks to a “small bounty” from Birmingham, U.K.-based Daden Limited, OpenSim has new NPC functionality — otherwise known as non-player characters or bots.
“Having this functionality broken was becoming a real pain for us, as having NPCs and autonomous avatars in virtual worlds is a lot of what we are about,” David Burden, Daden’s managing director, told Hypergrid Business.
Daden specializes in virtual world products for businesses, such as immersive training and learning systems and is particularly known for its line of intelligent chatbots.
Although Daden paid OpenSim core developer Justin Clark-Casey for the work, the results will be available to the entire open source community.
“We knew we’d be needing the functionality for some future projects,” said Burden. “But were also aware that a lot of other OpenSim users would like it. Seeing as we didn’t have the resources free in-house, we decided that the best solution was to use a small bounty to encourage Justin to promote the work up his to-do list so that it could go directly into core and be of benefit to the whole OpenSim community.”
One use for NPCs is in role playing games, where the NPCs could be monsters that attack players, guides who help them in their quest, or simply villagers and shop owners who help populate the landscape and make it feel realistic and interactive.
NPCs could also be used to create virtual pets.
But that’s not the only use for NPCs.
“Our main use is for NPCs in training scenarios,” said Burden. “But also virtual helpers or guides and even simulated crowds in other applications. Our long term goal and aspiration still remain Caprica-esque autonomous avatars in virtual worlds.’
Now, NPCs can be created by cloning existing avatars, he said. NPCs can move around on auto-pilot, even when the original avatars are no longer logged in.
NPCs can be controlled by scripts embedded in control objects, running OSSL commands, he added. In addition, they can be controlled by the standard Second Life-style bot processes, using LibOMV. “We’re also hoping to do by region module but don’t think that’s there yet,” Burden said.
Unlike script-controlled NPCs, LibOMV-controlled NPCs are basically standard avatars, and can do anything that avatars can do — but require to be logged in as their own user accounts. These are the “bots” that populate Second Life’s camping chairs and dance floors.
NPCs controlled by region modules wouldn’t require in-world scripted objects, as the scripts would be located on the server, not in-world. This could provide additional security, and allow developers to use standard programming languages to control the NPCs.
Business bots
According to Burden, bots have an important role to play in business.
“That’s our main focus,” he said.
For example, training simulations often require characters for students to interact with — student nurses need practice patients, trainee salesmen need practice customers, and trainee firefighters need practice victims. It can get expensive to hire actors or trainers to play those parts in real time.
NPCs can also be used for virtual guides, or to populate crowd scenes, he said.
“We’ll be driving our bots using our Discourse chatbot engine — similar to but more powerful than the Pandorabots that some people use — and also using motivation, emotion and navigation engines that we are developing,” he said.
No rampaging bots — yet
Those worried about NPCs rampaging across grids, and taking over virtual civilization, can rest easy — the new scripted NPCs are limited to their regions of origin, said Clark-Casey, who is also the head of the Overte Foundation for OpenSim development and is available for private consulting projects.
“With a reasonable amount of work, they could cross borders as well,” he added — but only if other region is run on the same server.
“A lot of work would probably be required to get them to cross borders where the source and destination are hosted on different simulators and both simulators are co-operative,” he added. “It’s possible, but at this point one might be better off with the LibOMV approach.”
For more information on the technical details of NPCs, see the OpenSim NPC wiki and the full list of OSSL NPC functions is here.
“I’m sure this won’t be the last word in NPC functions,” he said, “though I’m keen for people to leverage existing functionality rather than try and create a large number of specialized NPC functions that need to be maintained.”
For example, instead of creating a new NPC function, the llTarget function could serve double-purpose for NPC navigation.
He also warned users to expect some hiccups as the new functionality is rolled out and tested.
“Some bugs have emerged in the new functionality, as is to be expected in fresh dev code,” he said. “These will be nailed down over the coming weeks.”
Will corporate money corrupt the open source process?
Corporations such as Intel and IBM — and small companies like Kitely — have long been donating code to the OpenSim project. And companies routinely hire OpenSim developers to do custom work for them.
In fact, according to OpenSim core developer and Avination grid manager Melanie Thielker, companies have even paid for OpenSim developers to work on particular code.
“But the work has been done under non-disclosure agreements,” she said, “and the reason for the code being written therefore never became public knowledge.”
This is the first time when a company has publicly paid for an OpenSim developer to work on a project of interest to them.
By paying for code, companies could potentially influence the direction of development of OpenSim, Thielker told Hypergrid Business. Thielker is also CEO of OpenSim hosting company 3D Hosting.
“But then, anyone can, they only have to invest the time to code it up and submit it,” she said. “If it’s not seriously broken, or breaks core functionality, it will be included, so any sole developer and any company using other, non-core devs can influence the development direction just as well.”
“Therefore, I don’t see this as having any detrimental effect,” she said.
The question to ask is whether this particular instance compromises the larger mission of the open source project, said Lawrence Pierce, a consultant who specializes in new media design and production.
“I understand very well the need for bills to be paid,” he said.
“I support this type of behaviour as long the code is shared and remains open source,” said David Miller, eLearning developer at Newmarket International (he blogs as subQuark here).
“It is amazing that anyone dedicates the time, resources, and money that Justin and [hypergrid inventor and core developer] Crista [Lopes] do to a project like OpenSim.”
And if anyone is opposed to the influence of money on OpenSim, they can branch off the code and use only volunteer contributions, he added.
“If the group of core developers was larger, on the scale of hundreds like MOODLE has, then my view may be different,” he said. “But OpenSim is so tiny that we need to allow its core developers the freedom and trust to do what they deem best.”
“Developers need to be able to earn a decent living so I think there is no problem in OpenSim developers getting paid to build things they contribute to the shared code base,” added Kitely CEO Ilan Tochner.
“It’s good that developers can earn their living doing something that helps the community instead of working on things that don’t,” he said.
“I don’t have a problem with this practice at all,” echoed OpenSim core developer hypergrid inventor Crista Lopes, who is also a professor of informatics at the University of California, Irvine.
“Some developers contribute to OpenSim as part of their day jobs,” she said. “Others do it within different structures, and with other financial stimuli. All contributions go through the same quality control, independent of their financial context.”
However, paying bounties to developers can also be very destructive to community development if its not done right, said Simon Gutteridge, owner of UK-based grid management software company PioneerX Estates,
“It harbors a situation where the company with the biggest pool of cash has the greatest influence over software direction,” he said. “This in turn causes them to become more profitable as the software starts to trend to their particular business needs and so helping to stifle the more innovative ways the software could be used. This approach rarely works in my experience.”
However, he has also seen bounties work well, he added. For example, FreePBX, a web interface for the popular Asterisk VoIP system, needed refactoring recently for its popular Custom Contexts module and the original developer wasn’t interested in the work, and it was no longer core to FreePBX. The total cost of the work was priced at $4000 — and users got together and raised $4,350 for the project.
For this model to work, he said, a specific need has to be identified, the cost estimated, and community members asked to support the project with no one supporter contributing more than a third or a quarter of the total bounty amount. If the full bounty is raised, the work begins — if not, the money is refunded.
While FreePBX managed its bounty itself, other projects use third-party platforms such as Fundry to collect money, verify that work has been completed, and then pay out the bounty or refund it if not enough money is raised.
“It allows companies to use cash to influence the development cycle but only within confined boundaries and therefore does run such a high risk of a cash rich company pushing the project down a path that is ultimately in only their interest,” said Gutteridge. “The developers still get fed and can even compete for the work if they choose, driving costs down.”
The development work is only done if enough people want it, he added, so that the project is driven by community interest.
- Storylink Radio plans spooky fall events in Kitely and Second Life - September 15, 2024
- OpenSim active users rise with cooler weather - September 15, 2024
- OSFest 2024 Opens for Builders and Participants - August 24, 2024