| Current Path : /home/cmowner/CoffeeMud/resources/quests/random/ |
| Current File : //home/cmowner/CoffeeMud/resources/quests/random/auto_collect2.xml |
<?xml version="1.0"?>
<!-- ----------------------------------------------------------------------------
Copyright 2020-2025 Bo Zimmerman
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
--------------------------------------------------------------------------------
See guides/RandomAreas.html for information about documents of this type.
template: auto_collect2
vars:
template(auto_collect2)
category(whatevs)
area_name(area name)
targetarea_name(area name)
itemname(name of an item), item_level(#), item_material($)
collectibles_chance(number0-100)
aggression(YES,NO)
num_targets(num items to collect)
xp_amount_awarded
gold_amount_awarded
quest_point_awarded(YES,NO)
reward_items()
target_min_arealevel(#), target_max_arealevel(#)
quest_multiple(YES, NO, or PREV)
-->
<QUEST ID="auto_collect2" QUEST_TEMPLATE_ID="auto_collect2">
<QUEST_ID DEFINE="quest_id">${h:quest_template}_R$[100000000?999999999]</QUEST_ID>
<QUEST_CRITERIA SELECT="Pick-1">
<QUEST_CRITERIA CONDITION="$target_min_arealevel = ''">+SYSOP +LEVELS -<$[$target_level - $level_span] ->$[$target_level + $level_span]</QUEST_CRITERIA>
<QUEST_CRITERIA CONDITION="$target_min_arealevel != ''">+LEVEL -<$target_min_arealevel ->$target_max_arealevel </QUEST_CRITERIA>
</QUEST_CRITERIA>
<FREQUENCY>1</FREQUENCY>
<DURATION>90 minutes</DURATION>
<CATEGORY>$quest_category</CATEGORY>
<HOLDER_AREAS>"$target_area_name"</HOLDER_AREAS>
<HOLDER_ROOMS>ALL</HOLDER_ROOMS>
<COLLECTABLES_ITEMS>${SELECT: ANY\. from $target_item}</COLLECTABLES_ITEMS>
<COLLECTABLES_CHANCE>$[(5+($num_targets / $target_area_size * 100)) * 2]</COLLECTABLES_CHANCE>
<NUM_COLLECTABLES>$num_targets</NUM_COLLECTABLES>
<LOCALS_RESPONSE>${j:1:quest_fightspeech}</LOCALS_RESPONSE>
<QUEST_POINT>$quest_point_awarded</QUEST_POINT>
<GOLD>$gold_amount_awarded</GOLD>
<EXP>$xp_amount_awarded</EXP>
<MULTIPLE>$quest_multiple</MULTIPLE>
<NEXT_QUEST>$next_quest_id</NEXT_QUEST>
<FACTION>$target_faction</FACTION>
<NUMFACTION>$[$target_faction_amt / -500]</NUMFACTION>
<QUEST_NAME SELECT="Pick-1">
<QUEST_NAME>You need $num_targets ${p:target_item_name} in ${C:target_area_name} $reason_verbed</QUEST_NAME>
<QUEST_NAME>You want $num_targets ${p:target_item_name} in ${C:target_area_name} $reason_verbed</QUEST_NAME>
<QUEST_NAME>You must $reason_verb $num_targets ${p:target_item_name} in ${C:target_area_name}</QUEST_NAME>
<QUEST_NAME>${C:reason_verb} $num_targets ${p:target_item_name} in ${C:target_area_name}</QUEST_NAME>
<QUEST_NAME PICKWEIGHT=99 CONDITION="$deityname!=''">$deityname needs $num_targets ${p:target_item_name} in ${C:target_area_name} $reason_verbed</QUEST_NAME>
</QUEST_NAME>
<QUEST_INSTRUCTIONSSTRING>${j:1:quest_instructionstring}</QUEST_INSTRUCTIONSSTRING>
<QUEST_WINSPEECH_TEXT>${j:1:quest_winspeech}</QUEST_WINSPEECH_TEXT>
<REWARD_ITEMS>${SELECT: ANY\. FROM $dungeon_treasure_items}</REWARD_ITEMS>
<STRING load="/resources/quests/random/inc_questcommon.xml" />
<STRING ID="item_level" define="item_level">$target_level</STRING>
<STRING ID="target_item_name" define="target_item_name">${SELECT: NAME from (SELECT: FIRST\. from $target_item)}</STRING>
<OBJECT ID="target_item" define="target_item" SELECT="Any-1">
<OBJECT condition="$itemname=''">SELECT: ANY\. FROM $item_junk WHERE level <= $target_level</OBJECT>
<OBJECT condition="$itemname!=''">
<ITEM class="GenItem" name="$itemname" display="$itemname lies here">
<MATERIAL SELECT="Pick-1">
<MATERIAL PICKWEIGHT=99 CONDITION="$item_material=''">$any_Item_material</MATERIAL>
<MATERIAL PICKWEIGHT=1 CONDITION="$item_material!=''">$item_material</MATERIAL>
</MATERIAL>
<LEVEL SELECT="Pick-1">
<LEVEL PICKWEIGHT=99 CONDITION="$item_level=''">$level_range</LEVEL>
<LEVEL PICKWEIGHT=1 CONDITION="$item_level!=''">$item_level</LEVEL>
</LEVEL>
</ITEM>
</OBJECT>
</OBJECT>
<STRING ID="quest_fightspeech" PREDEFINE="reason=$reason" SELECT="Any">
<STRING CONDITION="$aggression='YES'">$quest_fightspeech</STRING>
<STRING CONDITION="$aggression!='YES'"></STRING>
</STRING>
<STRING ID="reason_verbed" PREDEFINE="reason=$reason">$reason_verbed</STRING>
<STRING ID="reason_verb" PREDEFINE="reason=$reason">$reason_verb</STRING>
<STRING ID="reason_desc" PREDEFINE="reason=$reason">$reason_desc</STRING>
<STRING ID="reason" DEFINE="reason" SELECT="Pick-1">
<STRING>$reason_ilostthem</STRING>
<STRING>$reason_welosteachother</STRING>
<STRING>$reason_gencollect</STRING>
<STRING>$reason_idoforthem</STRING>
<STRING>$reason_wedotoeachother</STRING>
<STRING PICKWEIGHT=99 CONDITION="$deityname!=''">$reason_deitydo</STRING>
</STRING>
<STRING ID="reason_deitydo" SELECT="All" REQUIRES="deityname=$">
<STRING define="reason_verbed">$verb_stolen</STRING>
<STRING define="reason_verb">$verb_steal</STRING>
<STRING define="quest_winspeech">$quest_generic_winner_speeches</STRING>
<STRING define="quest_fightspeech">$quest_generic_fight_speeches</STRING>
<STRING define="reason_short">${c:deityname} needs the ${p:target_item_name} of $target_area_name.</STRING>
<STRING define="reason_desc" SELECT="Any-1">
<STRING>${c:deityname} needs the ${p:target_item_name} of $target_area_name for some magical experiments.</STRING>
<STRING>${c:reason_verb} ${p:target_item_name} from $target_area_name for ${c:deityname}.</STRING>
<STRING>${c:deityname} has proclaimed that $target_area_name has too many ${p:target_item_name}.</STRING>
<STRING>Collect ${p:target_item_name} for ${c:deityname}.</STRING>
<STRING>${c:deityname} feels like witnessing a $adj_feeling_good $target_area_name ${hurt_verb}ing. Go do it and bring me their ${p:target_item_name}.</STRING>
</STRING>
</STRING>
<STRING ID="reason_short" define="reason_short" SELECT="Any-1">
<STRING>You need $num_targets ${p:target_item_name} $reason_verbed!</STRING>
<STRING>You must $reason_verb $num_targets ${p:target_item_name}!</STRING>
<STRING>Assistance required with $num_targets ${p:target_item_name}!</STRING>
<STRING>${c:reason_verb} $num_targets ${p:target_item_name} for goodness sake!</STRING>
<STRING>${c:reason_verb} $num_targets ${p:target_item_name}, quickly!</STRING>
<STRING>You want $num_targets ${p:target_item_name} $reason_verbed! </STRING>
</STRING>
<STRING ID="quest_instructionstring" SELECT="ALL">
<STRING ACTION="PREPEND">$reason_desc</STRING>
<STRING ACTION="APPEND">$reason_short</STRING>
<STRING SELECT="Any-1" ACTION="APPEND">
<STRING>You'll find them around $target_area_name.</STRING>
<STRING>Just look around $target_area_name.</STRING>
<STRING>They are all around $target_area_name.</STRING>
</STRING>
</STRING>
<STRING ID="quest_winspeech" PREDEFINE="reason=$reason">$quest_winspeech</STRING>
<STRING id="quest_generic_fight_speeches" SELECT="Any-1">
<STRING>${c:target_item_name} is mine!</STRING>
<STRING>Hey! Leave $target_item_name where it is!</STRING>
<STRING>Don't touch $target_item_name !!</STRING>
<STRING>You are not getting $target_item_name!</STRING>
<STRING>I would rather $hurt_verb you than let you get $target_item_name.</STRING>
</STRING>
<STRING id="quest_generic_winner_speeches" SELECT="Any-1">
<STRING>They are all $reason_verbed! That's all of them!</STRING>
<STRING>${c:reason_verbed} at last!</STRING>
<STRING>Congratulations for having them $reason_verbed.</STRING>
<STRING>Congratulations adventurer, you have ${reason_verbed}, and that will be all.</STRING>
</STRING>
<STRING ID="reason_partytime" SELECT="All">
<STRING define="reason_verbed">$verb_collected</STRING>
<STRING define="reason_verb">$verb_collect</STRING>
<STRING define="quest_winspeech" SELECT="Any-1" >
<STRING>Yay! Let the party BEGIN!</STRING>"
<STRING>TIME TO CELEBRATE!</STRING>"
<STRING>Let the celebration begin!</STRING>"
<STRING>We can finally begin the festivities!</STRING>"
</STRING>
<STRING define="quest_fightspeech">$quest_generic_fight_speeches</STRING>
<STRING define="reason_desc" SELECT="Any-1">
<STRING>You're throwing a party and you need lots of ${p:target_item_name}.</STRING>
<STRING>Today you are celebrating, and ${p:target_item_name} are your favorite gifts.</STRING>
<STRING>It's your $noun_anyrelation`s birthday, and you need several ${p:target_item_name} for your gift.</STRING>
<STRING>It is officially ${C:target_area_name} Day, and the ceremony requires several ${p:target_item_name}.</STRING>
</STRING>
</STRING>
<STRING ID="reason_ilostthem" SELECT="All">
<STRING define="reason_verbed">$verb_returned</STRING>
<STRING define="reason_verb">$verb_return</STRING>
<STRING define="quest_winspeech" SELECT="Any-1">
<STRING>You found them!</STRING>
<STRING>You're so relieved!</STRING>
<STRING>Congratulations for finding them!</STRING>
</STRING>
<STRING define="quest_fightspeech">$quest_generic_fight_speeches</STRING>
<STRING define="reason_desc" SELECT="Any-1">
<STRING>You lost your ${p:target_item_name} and need you to find them in $target_area_name.</STRING>
<STRING>Your $noun_anyrelation has lost some ${p:target_item_name} in $target_area_name and you need to find them.</STRING>
<STRING>You seem to have misplaced the ${p:target_item_name} around $target_area_name.</STRING>
<STRING>You can't find your $noun_anyrelation`s ${p:target_item_name} in $target_area_name.</STRING>
</STRING>
</STRING>
<STRING ID="reason_welosteachother" SELECT="All">
<STRING define="reason_verbed">$verb_collected</STRING>
<STRING define="reason_verb">$verb_collect</STRING>
<STRING define="quest_winspeech" SELECT="Any-1">
<STRING>You $verb_collected them!</STRING>
<STRING>You are thanked for your assistance.</STRING>
<STRING>Congratulations for getting these!</STRING>
</STRING>
<STRING define="quest_fightspeech">$quest_generic_fight_speeches</STRING>
<STRING define="reason_desc" SELECT="Any-1">
<STRING>${C:p:target_item_name} are important to your experiments. Please get $verb_collected from $target_area_name.</STRING>
<STRING>${C:p:target_item_name} are important to your $noun_anyrelation`s experiments. Please $verb_collected them from $target_area_name.</STRING>
<STRING>You need ${p:target_item_name} for your $noun_anyrelation`s project. You'll find them around $target_area_name.</STRING>
<STRING>You need ${p:target_item_name} for your important project. You'll find them in $target_area_name.</STRING>
<STRING>${C:p:target_item_name} are key to your work. Check around $target_area_name for you.</STRING>
<STRING>The ${p:target_item_name} are sitting around $target_area_name for me, and you must have them.</STRING>
</STRING>
</STRING>
<STRING ID="reason_gencollect" SELECT="All">
<STRING define="reason_verbed">$verb_collected</STRING>
<STRING define="reason_verb">$verb_collect</STRING>
<STRING define="quest_winspeech">$quest_generic_winner_speeches</STRING>
<STRING define="quest_fightspeech">$quest_generic_fight_speeches</STRING>
<STRING define="reason_desc" SELECT="Any-1">
<STRING>You need several ${p:target_item_name} $verb_collected and brought to you.</STRING>
<STRING>You need ${p:target_item_name} $verb_collected for me. You can get them from $target_area_name.</STRING>
<STRING>You are collecting ${p:target_item_name}.</STRING>
<STRING>${c:target_area_name} is a great source of ${p:target_item_name}, and you need lots of them $verb_collected!</STRING>
<STRING>Your $noun_anyrelation is collecting ${p:target_item_name}, and we need your assistance.</STRING>
<STRING>${c:target_area_name} is a great source of ${p:target_item_name}, and your $noun_anyrelation needs lots of them $verb_collected!</STRING>
</STRING>
</STRING>
<STRING ID="reason_idoforthem" SELECT="All">
<STRING define="reason_verbed">$verb_collected</STRING>
<STRING define="reason_verb">$verb_collect</STRING>
<STRING define="quest_winspeech">$quest_generic_winner_speeches</STRING>
<STRING define="quest_fightspeech">$quest_generic_fight_speeches</STRING>
<STRING define="reason_desc" SELECT="Any-1">
<STRING>${c:target_area_name} has the ${p:target_item_name} that your $noun_anyrelation requires.</STRING>
<STRING>You wish to give ${p:target_item_name} to your $noun_anyrelation, and $target_area_name has them all over.</STRING>
<STRING>Your $noun_anyrelation requires ${p:target_item_name}.</STRING>
<STRING>${c:target_area_name} has too many ${p:target_item_name}.</STRING>
</STRING>
</STRING>
<STRING ID="reason_wedotoeachother" SELECT="All">
<STRING define="reason_verbed">$verb_stolen</STRING>
<STRING define="reason_verb">$verb_steal</STRING>
<STRING define="quest_winspeech">$quest_generic_winner_speeches</STRING>
<STRING define="quest_fightspeech">$quest_generic_fight_speeches</STRING>
<STRING define="reason_desc" SELECT="Any-1">
<STRING >You need the ${p:target_item_name} of $target_area_name for your magical experiments.</STRING>
<STRING>${c:reason_verb} ${p:target_item_name} from $target_area_name for you.</STRING>
<STRING>${c:target_area_name} has all your ${p:target_item_name}. Get them back for you.</STRING>
<STRING>Collect ${p:target_item_name}.</STRING>
</STRING>
</STRING>
<STRING ID="quest_point_awarded" DEFINE="quest_point_awarded" SELECT="Pick-1">
<STRING PICKWEIGHT=2>NO</STRING>
<STRING PICKWEIGHT=1>YES</STRING>
</STRING>
<STRING ID="gold_amount_awarded" DEFINE="gold_amount_awarded" SELECT="any-1">
<STRING>$[$target_level*2]</STRING>
</STRING>
<STRING ID="xp_amount_awarded" DEFINE="xp_amount_awarded" SELECT="any-1">
<STRING>$[100 + ($target_level * 3)]</STRING>
</STRING>
<STRING ID="target_level" DEFINE="target_level" SELECT="any-1">
<STRING>${SELECT:MED_LEVEL from $target_area}</STRING>
</STRING>
<STRING ID="level_range" SELECT="any-1" DEFINE="level_range" MERGE=true>
<STRING>$target_level</STRING>
</STRING>
<STRING ID="target_faction" SELECT="any-1" DEFINE="target_faction">
<STRING></STRING>
</STRING>
<STRING ID="target_faction_amt" SELECT="first" DEFINE="target_faction_amt">
<STRING>0</STRING>
</STRING>
<OBJECT ID="target_area" SELECT="Pick-1" DEFINE="target_area">
<OBJECT pickweight=55555 condition="$targetarea_name != ''">SELECT: ANY\. FROM areas where NAME=$targetarea_name</OBJECT>
<OBJECT pickweight=1 condition="$targetarea_name = '' and $target_min_arealevel = ''">
SELECT: ANY\. FROM areas WHERE (SELECT:count\. from AREA\NPROOMS) > $num_targets
</OBJECT>
<OBJECT pickweight=1 condition="$targetarea_name = '' and $target_min_arealevel != ''">
SELECT: ANY\. FROM areas WHERE MED_LEVEL >= $target_min_arealevel and MED_LEVEL <= $target_max_arealevel
and (SELECT:count\. from AREA\NPROOMS) > $num_targets
</OBJECT>
</OBJECT>
<STRING ID="target_area_name" SELECT="any-1" DEFINE="target_area_name">
<STRING>${SELECT:name from $target_area}</STRING>
</STRING>
<STRING ID="target_area_size" SELECT="any-1" DEFINE="target_area_size">
<STRING>${SELECT:VISITABLE_ROOMS from $target_area}</STRING>
</STRING>
<STRING ID="aggression" DEFINE="aggression" SELECT="Pick-1">
<STRING PICKWEIGHT=50>NO</STRING>
<STRING PICKWEIGHT="$target_level">YES</STRING>
</STRING>
</QUEST>