#!QUESTMAKER_START_SCRIPT Competitive Invasion #2 #The player must repel an invasion by a set of existing mobs, from elsewhere in your world, #who will enter an existing area and behave aggressively towards the inhabitants. #An Announcer mob will offer an optional prize to the first player who #accepts the quest and kills X of the mobs. # #!QUESTMAKER_PAGE Quest Name/Duration #Enter the unique name and starting time/duration for your new quest. #Times are entered as a simple number or math expression to denote a #time in default ticks (4 second period), or you may follow the expression #with the word seconds, minutes, hours, days, mudhours, muddays, mudweeks, #mudmonths, or mudyears. Time expressions may include numbers, math #symbols, or the ? operator to generate random numbers. Example: #"5 + 3?10 minutes" would generate a frequency of 8-15 minutes.# # #Quest ID: #Enter a unique name/id for your quest: #$QUEST_ID=$UNIQUE_QUEST_NAME=competitive_invasion_2 # #Quest Name: #Enter a friendly displayable name for your quest: #$QUEST_NAME=$STRING=Competitive Invasion #2 # #Quest Frequency: #This is the time between quest starts. #$FREQUENCY=$TIMEEXPRESSION=90 minutes # #Quest Duration: #This is how long your quest remains running, and how long a player #accepting the quest has to complete the quest and report back in. #$DURATION=$TIMEEXPRESSION=90 minutes # #Quest-Player Criterium: #You may leave this entry blank, or enter a Zapper Mask to describe what #kinds of players may participate in this quest. You can use this to set #race, level, or other requirements. #$QUEST_CRITERIA=$ZAPPERMASK # #!QUESTMAKER_PAGE Specify the Announcer #The Announcer is the mob who will be announcing the quest initially. This must #be an existing mob in your world. They will announce the quest to players #once, and then mark whether the player says they accept the quest. The Announcer #must be in the area that is being invaded. # #Announcer Area/Room: #Specify below the name of the area that your Announcer mob will be located #in and/or the room in which the mob can be found. You may leave both blank #to force the quest manager to find the mob somewhere in the world, but this #will hurt the performance of your mud, so use with care. #Use double-quotes around multi-word areas and room ids/names. # #Announcer Area: #$ANNOUNCER_AREA=($AREA) #Announcer Room ID: #$ANNOUNCER_ROOM=($ROOMID) # #Announcer mob name: #Specify the name of the mob who will act as the Announcer mob. #Use double-quotes around multi-word names. #If you specified an area or room above, then the mob must be located there. #You may optionally have the quest manager select a 'random' mob by entering #a mob name of ANY MASK= followed by a Zapper Mask (see help on #ZAPPERMASKS for information on zapper mask syntax). #Remember, if the quest manager can not find your mob, the quest will not #be started. #$ANNOUNCER_NAME=$NAME # #!QUESTMAKER_PAGE Announcer greetings/instructions #Here's where you specify any special text said by the announcer regarding #your quest # #Announcer greeting: #Specify what the announcer says to people when they enter the room about their #quest. #$QUEST_NOTIFYSTRING=$LONG_STRING=Our city is being invaded by some things! # #Announcer instructions: #Specify what the announcer says to people who have accepted the quest. This #should give some details about what is to be done. You can leave this blank #if you like. #$QUEST_INSTRUCTIONSSTRING=($LONG_STRING)=Kill some number of the invaders and then return to me for your reward. # #Announcer announcement: #Select what type of annoucement the Announcer will make when the quest starts. #$QUEST_ANNOUNCEMENT_TYPE=$CHOOSE=YELL,QUESTCHAT,MPECHO,SAY #This is what the announcement says. Leave it blank if you only want him to talk to people who enter the room with him. #$QUEST_ANNOUNCEMENT=($STRING)=Invaders have entered the city! Help us! # #!QUESTMAKER_PAGE Invaders #Here's where you specify the invader mobs and where they launch their invasion #from. # #Invaders Area/Room: #Specify below the name of the area that your Invader mobs will be located #in and/or the room in which the mobs can be found. You may leave both blank #to force the quest manager to find the mobs somewhere in the world, but this #will hurt the performance of your mud, so use with care. #Use double-quotes around multi-word areas and room ids/names. # #Invaders Area: #$INVADER_AREA=($AREA) #Invaders Room ID: #$INVADER_ROOM=($ROOMID) # #Invader mobs names: #Specify the names of the mobs who will act as the Invader mobs. #They will work their way from their current location to the Announcers area. #Use double-quotes around multi-word names. #If you specified an area or room above, then the mob must be located there. #You may optionally have the quest manager select a 'random' mob by entering #a mob name of ANY MASK= followed by a Zapper Mask (see help on #ZAPPERMASKS for information on zapper mask syntax). #Remember, if the quest manager can not find your mobs, the quest will not #be started. #$INVADER_NAMES=$NAME # #Invaders To Kill: #Enter the total number of invaders that the player must kill to complete #the quest. #$INVADER_KILLS=$EXPRESSION=3 # #!QUESTMAKER_PAGE Quest Screams #Select some sayings and emotes that will occur during the quest # #Invader scream: #Specify what the invaders yell infrequently during combat. You may leave this blank. #$INVADER_SCREAM=($STRING)=Die native scum! # #Invasion warning type: #Specify how the announcer emotes if only 1 minute remains until the invasion is over: #$INVASION_WARNING_RESPONSE_TYPE=$CHOOSE=QUESTCHAT,MPECHO,SAY,YELL #Invasion warning text: #Specify what is emoted by the announcer when only 1 minute remains until the invasion is over. #$INVASION_WARNING_RESPONSE_TEXT=($LONG_STRING)=Cityguards report that this invasion will be repelled in 1 minute. # #Invader loses type: #Specify how the announcer emotes when/if a player completes the quest: #$INVADER_LOSES_RESPONSE_TYPE=$CHOOSE=QUESTCHAT,MPECHO,SAY,YELL #Invader loses text: #Specify what is emoted by the announcer when/if a player completes the quest: #$INVADER_LOSES_RESPONSE_TEXT=($LONG_STRING)=The city has been made safe by $n. Long live $n! # #Invader wins type: #Specify how the announcer emotes if no player completes the quest in time: #$INVADER_WINS_RESPONSE_TYPE=$CHOOSE=QUESTCHAT,MPECHO,SAY,YELL #Invader wins text: #Specify what is emoted by the announcer if no player completes the quest: #$INVADER_WINS_RESPONSE_TEXT=($LONG_STRING)=The cityguards have repelled the invasion! Long live the cityguards! # #!QUESTMAKER_PAGE Quest Completion #Select some rewards for completing the quest: # #Quest Point? #$QUEST_POINT=$CHOOSE=YES,NO #Amount of money (an amount, or leave blank): #$GOLD=($EXPRESSION) #Amount of experience points, blank for none, or a number% for percent of exp to next level: #$EXP=($STRING)=10% # #Player Faction to give to or take from: #$FACTION=($FACTION) #If you selected a faction above, enter a new numeric amount, #or enter +value to add, or --value to subtract: #$NUMFACTION=($STRING) # #Select whether a player may complete this quest multiple times: #$MULTIPLE=$CHOOSE=YES,NO # #If you choose, you may have completion of this quest automatically start another. #If this is what you want, enter the next quests name here: #$NEXT_QUEST=($EXISTING_QUEST_NAME) # #!QUESTMAKER_END_SCRIPT Competitive Invasion #2 set name $QUEST_ID set display $QUEST_NAME set author $#AUTHOR set wait $FREQUENCY set interval 1 #quiet set minplayers 1 set playermask $QUEST_CRITERIA set area $ANNOUNCER_AREA set room $ANNOUNCER_ROOM set mobgroup set mob $ANNOUNCER_NAME give stat keyplayer true give script LOAD=$QUEST_ID_announcer.script set area $INVADER_AREA set room $INVADER_ROOM set mob set mobgroup $INVADER_NAMES set mob give script LOAD=$QUEST_ID_invader.script give behavior Mobile min=1 max=10 chance=99 set duration $DURATION <?xml version="1.0"?> <FILE><NAME>$QUEST_ID_invaders.xml</NAME><DATA><MOBS>$INVADER_MOBS</MOBS></DATA></FILE> <FILE><NAME>$QUEST_ID_announcer.script</NAME> <DATA> ONCE_PROG 100 MPSETVAR * $QUEST_ID_ALREADY_TOLD '' MPSETVAR * $QUEST_ID_REWARDED '' MPSETVAR * $QUEST_ID_ACCEPTED '' MPSETVAR * $QUEST_ID_KILLS '' $QUEST_ANNOUNCEMENT_TYPE $QUEST_ANNOUNCEMENT ~ QUEST_TIME_PROG * -1 IF VAR ($i $QUEST_ID_REWARDED == '') $INVADER_WINS_RESPONSE_TYPE $INVADER_WINS_RESPONSE_TEXT ENDIF MPSETVAR * $QUEST_ID_ALREADY_TOLD '' MPSETVAR * $QUEST_ID_ACCEPTED '' MPSETVAR * $QUEST_ID_REWARDED '' MPSETVAR * $QUEST_ID_KILLS '' ~ GREET_PROG 100 if ISLIKE($n '$QUEST_CRITERIA') and ISPC($n) if EVAL('$MULTIPLE' == 'YES') OR !QUESTWINNER($n *) if VAR($n $QUEST_ID_KILLS >= $INVADER_KILLS) if EVAL('$EXP' != '') mpexp $n $EXP endif if EVAL('$FACTION' != '') mpfaction $n $FACTION $NUMFACTION endif if EVAL('$QUEST_POINT' == 'YES') AND !QUESTWINNER($n *) mpoload QuestPoint give "a quest point" "$n" endif if EVAL('$GOLD' != '') AND EVAL('$GOLD' > 0) mpoload $GOLD give $GOLD "$n" endif mpsetvar $i $QUEST_ID_REWARDED $n mpquestwin $n * $INVADER_LOSES_RESPONSE_TYPE $INVADER_LOSES_RESPONSE_TEXT mpendquest * mpqset * STATISTICS SUCCESS IF EVAL('$NEXT_QUEST' != '') mpstartquest $NEXT_QUEST ENDIF else if !STRIN('$<$i $QUEST_ID_ALREADY_TOLD>' '$n') sayto "$n" $QUEST_NOTIFYSTRING -- just say 'i accept' to take on this quest. MPSETVAR $i $QUEST_ID_ALREADY_TOLD '$<$i $QUEST_ID_ALREADY_TOLD> "$n"' endif endif endif endif ~ QUEST_TIME_PROG * 1 IF VAR ($i $QUEST_ID_REWARDED == '') $INVASION_WARNING_RESPONSE_TYPE $INVASION_WARNING_RESPONSE_TEXT ENDIF ~ SPEECH_PROG p i accept if ISLIKE($n '$QUEST_CRITERIA') and ISPC($n) if EVAL('$MULTIPLE' == 'YES') OR !QUESTWINNER($n *) if VAR($n $QUEST_ID_ACCEPTED == '') mpsetvar $n $QUEST_ID_ACCEPTED 'YES' sayto "$n" $QUEST_INSTRUCTIONSSTRING mpqset * STATISTICS ACCEPTED mpscript $n INDIVIDUAL LOAD=$QUEST_ID_playertrack.script else sayto "$n" Yes, yes, I know .. now off with you. endif endif endif ~ </DATA></FILE> <FILE><NAME>$QUEST_ID_invader.script</NAME> <DATA> RAND_PROG 50 MPARGSET $0 '${1 *}' if !INAREA($i == $0) IF ISFIGHT($i) FLEE ENDIF IF !AFFECTED($i Skill_Track) MPWALKTO $%INAREA($0)% ENDIF ELSE YELL $INVADER_SCREAM IF !AFFECTED($i Skill_Track) kill all ENDIF ENDIF ~ DEATH_PROG if ISLIKE($n '$QUEST_CRITERIA') and ISPC($n) if EVAL('$MULTIPLE' == 'YES') OR !QUESTWINNER($n *) IF ISPC($n) MPSETVAR $n $QUEST_ID_KILLS ++ IF EVAL('$INVADER_KILLS' > 1) mpechoat $n Killed $<$n $QUEST_ID_KILLS>/$INVADER_KILLS ELSE mpechoat $n You have killed $t. ENDIF ELSE IF ISPC($f) MPSETVAR $f $QUEST_ID_KILLS ++ IF EVAL('$INVADER_KILLS' > 1) mpechoat $n Killed $<$n $QUEST_ID_KILLS>/$INVADER_KILLS ELSE mpechoat $n You have killed $t. ENDIF ELSE IF ISFOLLOW($n) mpecho No Kill recorded. ENDIF ENDIF ENDIF ELSE mpechoat $n No Kill recorded. ENDIF ELSE mpechoat $n No Kill recorded. ENDIF ~ </DATA></FILE> <FILE><NAME>$QUEST_ID_playertrack.script</NAME> <DATA> ONCE_PROG 100 mpsetvar $i INSTRUCTIONS $QUEST_INSTRUCTIONSSTRING ~ QUEST_TIME_PROG * -1 mpqset * STATISTICS FAILED ~ RAND_PROG 99 if QVAR(* REMAINING == '') MPENDQUEST $i else mpsetvar $i TIME_REMAINING $%QVAR(* REMAINING)% endif ~ </DATA></FILE>