User:Allen Kerensky/Myriad Lite/BAM Adventure Giver NPC

From OpenSimulator

Jump to: navigation, search

Contents

BAM Adventure Giver NPC

BAM Adventure Giver NPC Concepts

All quests start and end with an NPC.

The first quest NPC would be fictional task 100, and each step of the quest would be 101, 102, etc, and when done, the player returns to the quest NPC to claim the prize.

BAM Adventure Giver NPC Setup

There are a number steps and configurable items for a BAM Adventure Giver NPC:

  1. Create your quest NPC item.
  2. Drop in the BAM Adventure Giver NPC script.
  3. Edit the "Adventure Specific Configuration" section at the top of the script. The variables are explained next.
    1. Set MSG_NPCNAME to the NPC's game name
    2. Choose a hovertext color for the NPC - http://wiki.secondlife.com/wiki/Category:LSL_Color
    3. Choose an alpha/transparency - 0.0 is totally clear, 1.0 is totally visible.
    4. ADVNAME: Adventure Name - set a short name for this adventure. Example: "Red Salt Quest"
    5. ADVTEXT: Adventure Description - set a short one-line description for this adventure. Example: "Find the rest salt for the baker"
    6. ADV_ATTRACT: Attract Message - Set a message for the NPC to attract player help. Example: " can you help me find some red salt?"
    7. MSG_OWNER_STARTADV: Message to owner that player started adventure. Example: " has started Red Salt Quest"
    8. ADV_ALL_TASKS: list of all task numbers that MUST be completed to get the prize. Example: "101, 102" NOTE: This list is a comma-separated values list, so there should be a SPACE after each comma. If the adventure does not finish when the player has performed all tasks, check this first!
    9. MSG_ADV_INCOMPLETE: what NPC should say if player comes back with not all tasks complete. Example: " Not done yet?"
    10. MSG_OWNER_DONEADV: message to quest owner when player finishes a quest. Example: "has completed Red Salt Quest"
    11. ADVDONETEXT: message from NPC to player that the quest is done. Example: "Thanks for finding red salt for me!"
    12. ADVDONEUUID: uuid key of a sound to play when player is successful on the quest, like a fanfare. Example: a "TA-DA" horn sound Can be the name of a sound effect file in the NPC object inventory too.
    13. PRIZENAME: name of a prize object in NPC object inventory to give to the player when they finish the quest. Example: Sweet roll or NONE. Put the Prize object in the NPC's object inventory. The key value NONE means do not give a prize at the end of the quest.
    14. ADVTASKTDNUM: the task to-do number of the NEXT TASK. Example: 101
    15. ADTASKTODO: a text description of the NEXT TASK the player should do. Example: "Find the Red Salt Mine."
    16. ADVTASKTODOHINT: a hint for the player on how to complete the NEXT TASK they are being given. Example: "You think the Red Salt Mine is northeast."
    17. TRIGGERWAIT: how long in seconds before a player can re-trigger this NPC or goal. Example: 60
    18. PRIZEWAIT: how long in seconds between when player can re-do quest and get the prize again. Example: 3600 (= 1 hour, or 86400 = 1 day)
    19. EVENTTIMER: how long between timer events, the smaller the number, the more lag. Example: 15.0 The timer processes the trigger and prize given lists to expire old entries - too long a wait between timers means longer before players can retry the quests.
  4. Save the script and let the NPC restart.
  5. Move on to creating the quest goals for this NPC's quest.

The Myriad RPG Group

Join the Myriad RPG group for announcements and discussion around the Myriad RPG and Myriad Lite scripts.

SecondLife: secondlife:///app/group/dbedc3be-729e-a123-d669-92f401e07a1e/about

OSgrid: secondlife:///app/group/da0227e5-8a0d-4d99-b970-9411932c852d/about

Community

Role Medieval Modern Futuristic Universal
Scripter Allen Kerensky
Builder
Tester
Mentor/Teacher

Feature Requests

If you have a feature you would like to see added to BAM Adventure Giver NPC, write a new feature request on the talk page for this article.

The best feature requests will have:

 Your SL name
 The name, version, and date of the script you are requesting new features in
 A description of the feature
 A sample implementation of the feature in LSL compatible with OSG and SL.

Bug Reports

If you find a bug or something that just doesn't seem right in how the BAM Adventure Giver NPC script works, file a bug report on the talk page for this article.

The best bug reports will have:

 Your OSG or SL name
 The name, version, and date of the script you are having problems with
 A description of the problem itself
 Steps to follow to reproduce the problem

Contributing to Myriad Lite

If you would like to contribute to the Myriad Lite project, please do!

The best contributions will have:

 Your SL Name
 A description of the contribution
 The patch, script, file, or object being contributed
 A release stating: 
 * that you intend to contribute this to Myriad Lite
 * that you are the original creator of the contribution or are legally empowered to contribute it
 * that you acknowledge this contribution can be released under the Creative Commons BY 3.0 Unported and Modified BSD (3-clause) licenses
//============================================================================
// BAM Adventure Giver NPC
// Copyright (c) 2012 by Baroun Tardis and Allen Kerensky (OSG/SL) All Rights Reserved.
// This work is dual-licensed under
// Creative Commons Attribution (CC BY) 3.0 Unported
// http://creativecommons.org/licenses/by/3.0/
// - or -
// Modified BSD License (3-clause)
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
// * Redistributions of source code must retain the above copyright notice, 
//   this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above copyright notice,
//   this list of conditions and the following disclaimer in the documentation
//   and/or other materials provided with the distribution.
// * Neither the name of Myriad Lite nor the names of its contributors may be
//   used to endorse or promote products derived from this software without
//   specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR
// IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
// OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
// NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
// NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
// THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//
// The Myriad RPG System was designed, written, and illustrated by Ashok Desai
// Myriad RPG System licensed under:
// Creative Commons Attribution (CC BY) 2.0 UK: England and Wales
// http://creativecommons.org/licenses/by/2.0/uk/
//============================================================================
Personal tools
General
About This Wiki