Page 1 of 4

House of Medakan cMUD Scripts

Posted: Sun May 14, 2017 6:16 pm
by Taziar
House of Medakan cMUD Scripts

Installation Instructions for cMUD
Character name must be saved in the Name: field of the Auto Login tab.
This step allows the %char variable to contain the name of the connected character.
Without the %char variable, many of the House of Medakan scripts will fail.
If you choose not to use the %char variable you must create your own variable that captures
your character name on connection and replace that variable for all instances of %char variable.
THIS IS THE NUMBER 1 REASON WHEN THINGS DON'T WORK!
Help files: https://sites.google.com/site/houseofme ... help-files

Table of Contents

Re: HoM cMUD Scripts

Posted: Sun May 14, 2017 6:20 pm
by Taziar
Type helpBank to view help file in client.

Image

Direct download: BankCMUD.txt

Code: Select all

#CLASS {Bank}
#ALIAS helpBank {
	#PRINT {%crlf <C dodgerblue>-----Bank Help File-----</C>}
	#PRINT {   <C dodgerblue>[Updated:10/12/2019]</C>}
	#PRINT { Keeps track of all character's bank account balances.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>balBank</C> to view current balance for current character.}
	#PRINT {  Note: helpBank shows all balances for all characters.}
	#PRINT {}
	#VAR bankTotal {}
	#PRINT { <C dodgerblue>--Character Balance--</C>}
	#SORT bankList
	#FORALL @bankList {
		#PRINT {  %i %repeat(" ",%eval(13-%len(%i))) %repeat(" ",%eval(4-%len(%eval(%eval(%concat(~@,bankAccount,%i))/20))))%eval(%eval(%concat(~@,bankAccount,%i))/20) gold crowns.}
		#ADD bankTotal %eval(%eval(%concat(~@,bankAccount,%i))/20)
		}
	#PRINT {}
	#PRINT {  Total balance: <C goldenrod>@bankTotal</C> gold crowns.}
	#PRINT {}
	}
#VAR bankList {}
#VAR bankTotal {}
#ALIAS balBank {
	#PRINT {%crlf %char's balance is: <C dodgerblue>%eval(%eval(%concat(~@,bankAccount,%char))/20)</C> gold crowns. %crlf}
	}
#TRIGGER "bankBalance" {whispers to you 'Your balance is the equivalent of (%d) copper.'} {
	#VAR %concat(bankAccount,%char) %1
	} "" {case|disable}
#TRIGGER "bankDeposit" {tells you, '(%d) copper has been credited to your account.'} {
	#ADD %concat(bankAccount,%char) %1
	} "" {case|disable}
#TRIGGER "bankWithdraw" {tells you '(%d) copper has been deducted from your account.'} {
	#ADD %concat(bankAccount,%char) -%1
	} "" {case|disable}
#TRIGGER "bankPrompt" {{o|*} * >} {
	#T- bankPrompt
	#T- bankBalance
	#T- bankDeposit
	#T- bankWithdraw
	} "" {disable|nocr|prompt}
#ONINPUT "bankBalInput" {^{bal|bala|balan|balanc|balance}$} {
	#T+ bankBalance
	#T+ bankPrompt
	} "" {}
#ONINPUT "bankDepInput" {^{de|dep|depo|depos|deposi|deposit} (%d)$} {
	#T+ bankDeposit
	#T+ bankPrompt
	} "" {}
#ONINPUT "bankWithInput" {^{wit|with|withd|withdr|withdra|withdraw} (%d)$} {
	#T+ bankWithdraw
	#T+ bankPrompt
	} "" {}
#EVENT onConnect {
	#IF (%class(%concat(bankAccount,%char))=-1) {
		#ADDITEM bankList %char
		#VAR %concat(bankAccount,%char) 0 {_nodef} "Bank"
		}
	}
#CLASS 0

Re: HoM cMUD Scripts

Posted: Wed Aug 23, 2017 11:31 pm
by Taziar
Type helpClanChest to view help file in client.

Image

Direct download: ClanChestCMUD.txt

Code: Select all

#CLASS {ClanChest}
#ALIAS helpClanChest {
	#PRINT {%crlf <C dodgerblue>-----Clan Chest Help File-----</C>}
	#PRINT {      <C dodgerblue>[Updated: 9/21/2019]</C>}
	#PRINT {}
	#PRINT { Type <C dodgerblue>saveChest</C> when at quartermaster to save generic list.}
	#PRINT {  Note: type <C dodgerblue>saveChest <name></C> to save chest list with name.}
	#PRINT {   Example: saveChest Companions will save a list under the name Companions.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>showChest</C> to view contents of generic save list.}
	#PRINT {  Note: type <C dodgerblue>showChest <name></C> to view a previously named list.}
	#PRINT {   Example: showChest Companions will show the last list you saved with that name.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>searchChest <item></C> to view list of matched items with current item numbers.}
	#PRINT {  Note: to determine what chest list is searched first showChest <name> to set default.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>sortChest <item></C> to sort named items together.}
	#PRINT {  Note: works like the searchChest function except single keyword only.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>matchChest <name></C> when at quartermaster to compare a saved list with current chest contents.}
	#PRINT {  Note: matching items show in default text color, non-matching items show in <C dodgerblue>dodgerblue</C>.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>showChestList</C> to see list of current saved chest names.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>deleteChest <name></C> to delete a saved chest list.}
	#PRINT {}
	#PRINT { Script automatically gags any buggy chest slots (Oops! message).}
	#PRINT {}
	}
#ALIAS saveChest {
	#PRINT {}
	#IF (%len(%1)) {
		#IF (%ismember(%proper(%1),@clanChestNameList)) {
			#VAR %concat(chest,%proper(%1)) {} {_nodef} "ClanChest"
			#PRINT {Saving over existing chest list: %proper(%1)}
			} {
			#ADDITEM clanChestNameList %proper(%1)
			#VAR %concat(chest,%proper(%1)) {} {_nodef} "ClanChest"
			#PRINT {Saving new chest list: %proper(%1)}
			}
		#VAR clanChestName %proper(%1)
		} {
		#PRINT {Chest List Loading...}
		#T+ clansaveChestTrigger
		}
	#T+ clanChestTempTrigger
	#T+ clanChestPromptTrigger
	#T+ clanChestOopsTrigger
	#T+ clanChestFinishedTrigger
	#VAR clansaveChest {}
	#VAR clanChestTemp {}
	#VAR clanAddTemp 1
	#SEND {list}
	}
#ALIAS showChest {
	#PRINT {%crlf  One moment, retrieving chest list... %crlf}
	#IF (%ismember(%proper(%1),@clanChestNameList)) {
		#VAR clanChestName %proper(%1)
		#VAR clanChestTemp (%concat("@chest",%proper(%1)))
		#FORALL @clanChestTemp {
			#PRINT { %i}
			}
		#IF (%numitems(@clanChestTemp)) {} {
			#PRINT {  No list found!}
			}
		} {
		#FORALL @clansaveChest {
			#PRINT { %i}
			}
		#IF (%numitems(@clansaveChest)) {} {
			#PRINT {  No list found!}
			}
		}
	#PRINT {}
	}
#ALIAS searchChest {
	#IF (%len(%-1)>0) {
		#VAR clanSearchSuccess {0}
		#VAR clanSearchItem {%lower(%-1)}
		#PRINT {%crlf  One moment, searching chest list:@clanChestname for: %-1...}
		#IF (%pos(@clanSearchItem,@clanChestTemp)>0) {
			#VAR clanSearchSuccess 1
			#PRINT {}
			#FORALL @clanChestTemp {
				#IF (%pos(@clanSearchItem,%i)) {
					#PRINT {  %i}
					}
				}
			}
		#IF (@clanSearchSuccess=0) {
			#PRINT {%crlf Did not find any: @clanSearchItem}
			}
		#IF (%numitems(@clanChestTemp)) {} {
			#PRINT {%crlf Type: showChest <name> or saveChest to load list to search.}
			}
		} {
		#PRINT {%crlf  Type: searchChest <item keyword(s)>}
		}
	}
#ALIAS sortChest {
	#IF (%len(%1)>0) {
		#VAR clanSortList {}
		#VAR clanSearchSuccess {0}
		#VAR clanSearchItem {%lower(%1)}
		#PRINT {%crlf  One moment, sorting chest list:@clanChestname for: %1...}
		#IF (%pos(@clanSearchItem,@clanChestTemp)>0) {
			#VAR clanSearchSuccess 1
			#PRINT {}
			#FORALL @clanChestTemp {
				#IF (%pos(@clanSearchItem,%i)) {
					#PRINT {  %i}
					#ADDITEM clanSortList %trim(%left(%i,%pos(.,%i)))
					}
				}
			#LOOP %numitems(@clanSortList),1 {
				#SEND {withdraw %item(@clanSortList,%i)}
				}
			#REPEAT %numitems(@clanSortList) {
				#SEND {deposit @clanSearchItem}
				}
			}
		#IF (@clanSearchSuccess=0) {
			#PRINT {%crlf Did not find any: @clanSearchItem}
			}
		#IF (%numitems(@clanChestTemp)) {} {
			#PRINT {%crlf Type <C dodgerblue>showChest <name></C> or <C dodgerblue>saveChest</C> to load list to sort.}
			}
		} {
		#PRINT {%crlf  Type <C dodgerblue>sortChest <item keyword(s)></C>}
		}
	}
#ALIAS showChestList {
	#PRINT {%crlf Saved chest list names:%crlf}
	#FORALL @clanChestNameList {
		#PRINT { %i}
		}
	#PRINT {}
	}
#ALIAS deleteChest {
	#IF (%ismember(%proper(%1),@clanChestNameList)) {
		#DELITEM clanChestNameList %proper(%1)
		#UNVAR %concat(chest,%proper(%1)) "ClanChest"
		} {
		#PRINT {%crlf %proper(%1) is not a saved chest list.}
		}
	}
#ALIAS matchChest {
	#PRINT {}
	#IF (%ismember(%proper(%1),@clanChestNameList)) {
		#VAR clanChestName %proper(%1)
		#VAR clanMatchON 1
		#VAR clansaveChest {}
		#VAR clanChestTemp {}
		#T+ clansaveChestTrigger
		#T+ clanChestPromptTrigger
		#T+ clanChestOopsTrigger
		#T+ clanChestFinishedTrigger
		#SEND {list}
		} {
		#PRINT {%crlf Usage: matchChest <savedChestName>}
		}
	#PRINT {}
	}
#VAR clanAddTemp {}
#VAR clanMatchON {}
#VAR clanSaveChest {}
#VAR clanSortList {}
#VAR clanChestName {}
#VAR clanChestNameList {}
#VAR clanChestTemp {}
#VAR clanSearchItem {}
#VAR clanSearchSuccess {}
#TRIGGER "clanChestOopsTrigger" {%d. Oops! Item not found! Try again later.$} {
	#GAG
	} "" {case|disable}
#TRIGGER "clansaveChestTrigger" {(%d. [a-z]*)$} {
	#VAR clansaveChest %additem(%1,@clansaveChest)
	} "" {case|disable}
#TRIGGER "clanChestTempTrigger" {(%d. [a-z]*)$} {
	#VAR clanChestTemp %additem(%1,@clanChestTemp)
	} "" {case|disable}
#TRIGGER "clanChestPromptTrigger" {~* Press <Return> to continue, q to quit ~*>} {
	#CR
	} "" {case|disable|nocr|prompt}
#TRIGGER "clanChestFinishedTrigger" {{o|*} * >} {
	#T- clansaveChestTrigger
	#T- clanChestTempTrigger
	#T- clanChestOopsTrigger
	#T- clanChestPromptTrigger
	#T- clanChestFinishedTrigger
	#IF (@clanAddTemp) {
		#VAR clanAddTemp 0
		#VAR %concat(chest,@clanChestName) @clanChestTemp {_nodef} "ClanChest"
		}
	#IF (@clanMatchON) {
		#VAR clanMatchON 0
		#VAR clanChestTemp %expand(%concat("@chest",@clanChestName))
		#PRINT {%crlf Non matching entries show in <C dodgerblue>dodgerblue</C> %crlf}
		#FORALL @clansaveChest {
			#IF (%ismember(%i,@clanChestTemp)) {
				#PRINT { %i}
				} {
				#PRINT {<C dodgerblue> %i</C>}
				}
			}
		}
	} "" {case|disable|nocr|prompt}
#CLASS 0

Re: HoM cMUD Scripts

Posted: Fri Jul 20, 2018 7:55 pm
by Taziar
Type helpClumsy to view help file in client.

Image

Direct download: ClumsyCMUD.txt

Code: Select all

#CLASS {Clumsy}
#ALIAS helpClumsy {
	#PRINT {%crlf <C dodgerblue>-----Clumsy Help File-----</C>}
	#PRINT {   <C dodgerblue>[Updated: 8/28/2019]</C>}
	#PRINT { Script tracks individual character clumsy data across sessions.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>showClumsy</C> to toggle session message on/off for all characters.}
	#PRINT { Type <C dodgerblue>showClumsyOT</C> to toggle over time message on/off for current character.}
	#PRINT {}
	#PRINT { Type any of the following commands to show individual clumsy data: }
	#PRINT {   <C dodgerblue>bashCount</C>}
	#PRINT {   <C dodgerblue>chargeCount</C>}
	#PRINT {   <C dodgerblue>clumsyCount</C>}
	#PRINT {   <C dodgerblue>kickCount</C>}
	#PRINT {   <C dodgerblue>stabCount</C>}
	#PRINT {   <C dodgerblue>throwCount</C>}
	#PRINT {   <C dodgerblue>criticalCount</C> (throw critical)}
	#PRINT {}
	#PRINT { Type <C dodgerblue>resetClumsy</C> to reset data for current session only.}
	#PRINT { Type <C dodgerblue>resetClumsyData</C> to reset ALL data for current character.}
	#PRINT {  Note: Shows date (month/day/year) since resetting data.}
	#PRINT {}
	}
#ALIAS showClumsy {
	#IF (@showClumsy) {
		#VAR showClumsy 0
		#PRINT {Clumsy session message is turned on.}
		} {
		#VAR showClumsy 1
		#PRINT {Clumsy session message is turned off.}
		}
	}
#ALIAS showClumsyOT {
	#IF (%expand(%concat("@",show,%char,OT))) {
		#VAR %concat(show,%char,OT) 0
		#PRINT {Clumsy over time message for %char is turned on.}
		} {
		#VAR %concat(show,%char,OT) 1
		#PRINT {Clumsy over time message for %char is turned off.}
		}
	}
#ALIAS bashCount {
	#RAISE eventBashCount
	}
#ALIAS chargeCount {
	#RAISE eventChargeCount
	}
#ALIAS clumsyCount {
	#RAISE eventBashCount
	#RAISE eventChargeCount
	#RAISE eventKickCount
	#RAISE eventStabCount
	#RAISE eventThrowCount
	#RAISE eventCriticalCount
	}
#ALIAS kickCount {
	#RAISE eventKickCount
	}
#ALIAS stabCount {
	#RAISE eventStabCount
	}
#ALIAS throwCount {
	#RAISE eventThrowCount
	}
#ALIAS criticalCount {
	#RAISE eventCriticalCount
	}
#ALIAS resetClumsyData {
	#RESET Clumsy
	#VAR %concat(clumsy,%char,LandBash) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,LandCharge) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,LandKick) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,LandStab) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,LandThrow) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,LandThrowCritical) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,MissBash) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,MissCharge) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,MissKick) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,MissStab) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,MissThrow) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,PercentageBash) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,PercentageCharge) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,PercentageKick) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,PercentageStab) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,PercentageThrow) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,PercentageThrowCritical) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,TotalBash) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,TotalCharge) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,TotalKick) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,TotalStab) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(clumsy,%char,ThrowTotal) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#VAR %concat(%char,OT) {%time("m/d/20y")} {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
	#PRINT {Clumsy data for %char is now reset.}
	}
#ALIAS resetClumsy {
	#RESET Clumsy
	}
#VAR clumsyLandBash 0 0
#VAR clumsyLandCharge 0 0
#VAR clumsyLandKick 0 0
#VAR clumsyLandStab 0 0
#VAR clumsyLandThrow 0 0
#VAR clumsyLandThrowCritical 0 0
#VAR clumsyMissBash 0 0
#VAR clumsyMissCharge 0 0
#VAR clumsyMissKick 0 0
#VAR clumsyMissStab 0 0
#VAR clumsyMissThrow 0 0
#VAR clumsyPercentageBash 0 0
#VAR clumsyPercentageCharge 0 0
#VAR clumsyPercentageKick 0 0
#VAR clumsyPercentageStab 0 0
#VAR clumsyPercentageThrow 0 0
#VAR clumsyPercentageThrowCritical 0 0
#VAR clumsyTotalBash 0 0
#VAR clumsyTotalCharge 0 0
#VAR clumsyTotalKick 0 0
#VAR clumsyTotalStab 0 0
#VAR clumsyTotalThrow 0 0
#VAR showClumsy 1
#TRIGGER "clumsyBashLand" {^Your bash at * sprawling!$} {
	#VAR clumsyLandBash (@clumsyLandBash+1)
	#VAR %concat(clumsy,%char,LandBash) (%expand(%concat("@",clumsy,%char,LandBash))+1)
	#VAR clumsyTotalBash (@clumsyLandBash+@clumsyMissBash)
	#VAR clumsyPercentageBash (@clumsyLandBash*100/@clumsyTotalBash)
	#VAR %concat(clumsy,%char,TotalBash) (%expand(%concat("@",clumsy,%char,LandBash))+%expand(%concat("@",clumsy,%char,MissBash)))
	#VAR %concat(clumsy,%char,PercentageBash) (%expand(%concat("@",clumsy,%char,LandBash))*100/%expand(%concat("@",clumsy,%char,TotalBash)))
	#IF (@showClumsy) {
		#PRINT {This session you've landed @clumsyLandBash out of @clumsyTotalBash bashes (@{clumsyPercentageBash}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandBash)) out of %expand(%concat("@",clumsy,%char,TotalBash)) bashes (%expand(%concat("@",clumsy,%char,PercentageBash))~% landed)}
		}
	} "" {case}
#TRIGGER "clumsyBashTopple" {^As * your bash, you topple over and fall to the ground!$} {
	#VAR clumsyMissBash (@clumsyMissBash+1)
	#VAR %concat(clumsy,%char,MissBash) (%expand(%concat("@",clumsy,%char,MissBash))+1)
	#VAR clumsyTotalBash (@clumsyLandBash+@clumsyMissBash)
	#VAR clumsyPercentageBash (@clumsyLandBash*100/@clumsyTotalBash)
	#VAR %concat(clumsy,%char,TotalBash) (%expand(%concat("@",clumsy,%char,LandBash))+%expand(%concat("@",clumsy,%char,MissBash)))
	#VAR %concat(clumsy,%char,PercentageBash) (%expand(%concat("@",clumsy,%char,LandBash))*100/%expand(%concat("@",clumsy,%char,TotalBash)))
	#IF (@showClumsy) {
		#PRINT {This session you've missed @clumsyMissBash out of @clumsyTotalBash bashes (@{clumsyPercentageBash}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've missed %expand(%concat("@",clumsy,%char,MissBash)) out of %expand(%concat("@",clumsy,%char,TotalBash)) bashes (%expand(%concat("@",clumsy,%char,PercentageBash))~% landed)}
		}
	} "" {case}
#TRIGGER "clumsyChargeLand" {^Chaaaaarrrge!! * bleeds profusely as you skewer * with *!$} {
	#VAR clumsyLandCharge (@clumsyLandCharge+1)
	#VAR %concat(clumsy,%char,LandCharge) (%expand(%concat("@",clumsy,%char,LandCharge))+1)
	#VAR clumsyTotalCharge (@clumsyMissCharge+@clumsyLandCharge)
	#VAR clumsyPercentageCharge (@clumsyLandCharge*100/@clumsyTotalCharge)
	#VAR %concat(clumsy,%char,TotalCharge) (%expand(%concat("@",clumsy,%char,MissCharge))+%expand(%concat("@",clumsy,%char,LandCharge)))
	#VAR %concat(clumsy,%char,PercentageCharge) (%expand(%concat("@",clumsy,%char,LandCharge))*100/%expand(%concat("@",clumsy,%char,TotalCharge)))
	#IF (@showClumsy) {
		#PRINT {This session you've landed @clumsyLandCharge out of @clumsyTotalCharge charges (@{clumsyPercentageCharge}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandCharge)) out of %expand(%concat("@",clumsy,%char,TotalCharge)) charges (%expand(%concat("@",clumsy,%char,PercentageCharge))~% landed)}
		}
	} "" {case}
#TRIGGER "clumsyChargeOops" {^Oops. Your lame efforts cause you to miss.$} {
	#VAR clumsyMissCharge (@clumsyMissCharge+1)
	#VAR %concat(clumsy,%char,MissCharge) (%expand(%concat("@",clumsy,%char,MissCharge))+1)
	#VAR clumsyTotalCharge (@clumsyMissCharge+@clumsyLandCharge)
	#VAR clumsyPercentageCharge (@clumsyLandCharge*100/@clumsyTotalCharge)
	#VAR %concat(clumsy,%char,TotalCharge) (%expand(%concat("@",clumsy,%char,MissCharge))+%expand(%concat("@",clumsy,%char,LandCharge)))
	#VAR %concat(clumsy,%char,PercentageCharge) (%expand(%concat("@",clumsy,%char,LandCharge))*100/%expand(%concat("@",clumsy,%char,TotalCharge)))
	#IF (@showClumsy) {
		#PRINT {This session you've clumsied @clumsyMissCharge out of @clumsyTotalCharge charges (@{clumsyPercentageCharge}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've clumsied %expand(%concat("@",clumsy,%char,MissCharge)) out of %expand(%concat("@",clumsy,%char,TotalCharge)) charges (%expand(%concat("@",clumsy,%char,PercentageCharge))~% landed)}
		}	
	} "" {case}
#TRIGGER "clumsyStabLand" {^* makes a strange sound as you place * in * back!$} {
	#VAR clumsyLandStab (@clumsyLandStab+1)
	#VAR %concat(clumsy,%char,LandStab) (%expand(%concat("@",clumsy,%char,LandStab))+1)
	#VAR clumsyTotalStab (@clumsyLandStab+@clumsyMissStab)
	#VAR clumsyPercentageStab (@clumsyLandStab*100/@clumsyTotalStab)
	#VAR %concat(clumsy,%char,TotalStab) (%expand(%concat("@",clumsy,%char,LandStab))+%expand(%concat("@",clumsy,%char,MissStab)))
	#VAR %concat(clumsy,%char,PercentageStab) (%expand(%concat("@",clumsy,%char,LandStab))*100/%expand(%concat("@",clumsy,%char,TotalStab)))
	#IF (@showClumsy) {
		#PRINT {This session you've landed @clumsyLandStab out of @clumsyTotalStab stabs (@{clumsyPercentageStab}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandStab)) out of %expand(%concat("@",clumsy,%char,TotalStab)) stabs (%expand(%concat("@",clumsy,%char,PercentageStab))~% landed)}
		}	
	} "" {case}
#TRIGGER "clumsyStabOoops" {^Ooops. Your clumsy execution broadcasts your intentions.$} {
	#VAR clumsyMissStab (@clumsyMissStab+1)
	#VAR %concat(clumsy,%char,MissStab) (%expand(%concat("@",clumsy,%char,MissStab))+1)
	#VAR clumsyTotalStab (@clumsyLandStab+@clumsyMissStab)
	#VAR clumsyPercentageStab (@clumsyLandStab*100/@clumsyTotalStab)
	#VAR %concat(clumsy,%char,TotalStab) (%expand(%concat("@",clumsy,%char,LandStab))+%expand(%concat("@",clumsy,%char,MissStab)))
	#VAR %concat(clumsy,%char,PercentageStab) (%expand(%concat("@",clumsy,%char,LandStab))*100/%expand(%concat("@",clumsy,%char,TotalStab)))
	#IF (@showClumsy) {
		#PRINT {This session you've clumsied @clumsyMissStab out of @clumsyTotalStab stabs (@{clumsyPercentageStab}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've clumsied %expand(%concat("@",clumsy,%char,MissStab)) out of %expand(%concat("@",clumsy,%char,TotalStab)) stabs (%expand(%concat("@",clumsy,%char,PercentageStab))~% landed)}
		}
	} "" {case}
#TRIGGER "clumsyKickLand" {Your boots need polishing again -- blood all over...$} {
	#RAISE eventKickSuccess
	} "" {case}
#TRIGGER "clumsyKickHit" {Your kick hits * in the solar plexus!$} {
	#RAISE eventKickSuccess
	} "" {case}
#TRIGGER "clumsyKickMiss" {You miss your kick at * groin, much to * relief...$} {
	#RAISE eventKickFail
	} "" {case}
#TRIGGER "clumsyKickMile" {Your beautiful full-circle kick misses * by a mile.$} {
	#RAISE eventKickFail
	} "" {case}
#TRIGGER "clumsyThrowTrigger" {You throw * at *.$} {
	#T+ clumsyThrowLand
	#T+ clumsyThrowRip
	#T+ clumsyThrowCrit
	#T+ clumsyThrowDeflect
	#T+ clumsyThrowMiss
	#ALARM "clumsyThrowAlarm" +10 {
		#RAISE eventThrown
		} "Clumsy"
	} "" {case}
#TRIGGER "clumsyThrowLand" {^* grunts in pain as * is struck by *.$} {
	#RAISE eventThrowSuccess
	} "" {case|disable}
#TRIGGER "clumsyThrowRip" {^* rips through * guts as * collapses to the ground.$} {
	#RAISE eventThrowSuccess
	} "" {case|disable}
#TRIGGER "clumsyThrowCrit" {^* spasms in excruciating pain as * is struck by *.$} {
	#RAISE eventThrown
	#VAR clumsyLandThrow (@clumsyLandThrow+1)
	#VAR clumsyLandThrowCritical (@clumsyLandThrowCritical+1)
	#VAR %concat(clumsy,%char,LandThrow) (%expand(%concat("@",clumsy,%char,LandThrow))+1)
	#VAR %concat(clumsy,%char,LandThrowCritical) (%expand(%concat("@",clumsy,%char,LandThrowCritical))+1)
	#VAR clumsyPercentageThrowCritical (@clumsyLandThrowCritical*100/@clumsyLandThrow)
	#VAR %concat(clumsy,%char,PercentageThrowCritical) (%expand(%concat("@",clumsy,%char,LandThrowCritical))*100/%expand(%concat("@",clumsy,%char,LandThrow)))
	#VAR clumsyTotalThrow (@clumsyMissThrow+@clumsyLandThrow)
	#VAR clumsyPercentageThrow (@clumsyLandThrow*100/@clumsyTotalThrow)
	#VAR %concat(clumsy,%char,ThrowTotal) (%expand(%concat("@",clumsy,%char,MissThrow))+%expand(%concat("@",clumsy,%char,LandThrow)))
	#VAR %concat(clumsy,%char,PercentageThrow) (%expand(%concat("@",clumsy,%char,LandThrow))*100/%expand(%concat("@",clumsy,%char,ThrowTotal)))
	#IF (@showClumsy) {
		#PRINT {This session you've landed @clumsyLandThrow out of @clumsyTotalThrow throws (@{clumsyPercentageThrow}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandThrow)) out of %expand(%concat("@",clumsy,%char,ThrowTotal)) throws (%expand(%concat("@",clumsy,%char,PercentageThrow))~% landed)}
		}
	} "" {case|disable}
#TRIGGER "clumsyThrowDeflect" {^* deflects * that was thrown at *.$} {
	#RAISE eventThrowFail
	} "" {case|disable}
#TRIGGER "clumsyThrowMiss" {^* just misses * and falls to the ground.$} {
	#RAISE eventThrowFail
	} "" {case|disable}
#EVENT OnConnect {
	#IF (%class(Clumsy|%concat(%char,ClumsyVariables))=-1) {
		#CLASS {Clumsy|%concat(%char,ClumsyVariables)} {disable}
		#CLASS 0
		#VAR %concat(clumsy,%char,LandBash) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,LandCharge) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,LandKick) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,LandStab) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,LandThrow) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,LandThrowCritical) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,MissBash) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,MissCharge) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,MissKick) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,MissStab) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,MissThrow) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,PercentageBash) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,PercentageCharge) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,PercentageKick) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,PercentageStab) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,PercentageThrow) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,PercentageThrowCritical) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,TotalBash) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,TotalCharge) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,TotalKick) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,TotalStab) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(clumsy,%char,ThrowTotal) 0 {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(show,%char,OT) {1} {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		#VAR %concat(%char,OT) {%time("m/d/20y")} {_nodef} {Clumsy|%concat(%char,ClumsyVariables)}
		} {
		#T+ {Clumsy|%concat(%char,ClumsyVariables)}
		}
	}
#EVENT eventBashCount {
	#PRINT {%crlf <C dodgerblue>Bash Data:</C>}
	#IF (@clumsyTotalBash>0) {
		#PRINT {This session you've landed @clumsyLandBash out of @clumsyTotalBash bashes (@{clumsyPercentageBash}~% landed)}
		} {
		#PRINT {No current session data available...}
		}
	#IF (%expand(%concat("@",clumsy,%char,TotalBash))>0) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandBash)) out of %expand(%concat("@",clumsy,%char,TotalBash)) bashes (%expand(%concat("@",clumsy,%char,PercentageBash))~% landed)}
		} {
		#PRINT {No over time data available...}
		}
	}
#EVENT eventChargeCount {
	#PRINT {%crlf <C dodgerblue>Charge Data:</C>}
	#IF (@clumsyTotalCharge>0) {
		#PRINT {This session you've landed @clumsyLandCharge out of @clumsyTotalCharge charges (@{clumsyPercentageCharge}~% landed)}
		} {
		#PRINT {No current session data available...}
		}
	#IF (%expand(%concat("@",clumsy,%char,TotalCharge))>0) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandCharge)) out of %expand(%concat("@",clumsy,%char,TotalCharge)) charges (%expand(%concat("@",clumsy,%char,PercentageCharge))~% landed)}
		} {
		#PRINT {No over time data available...}
		}
	}
#EVENT eventKickCount {
	#PRINT {%crlf <C dodgerblue>Kick Data:</C>}
	#IF (@clumsyTotalKick>0) {
		#PRINT {This session you've landed @clumsyLandKick out of @clumsyTotalKick kicks (@{clumsyPercentageKick}~% landed)}
		} {
		#PRINT {No current session data available...}
		}
	#IF (%expand(%concat("@",clumsy,%char,TotalKick))>0) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandKick)) out of %expand(%concat("@",clumsy,%char,TotalKick)) kicks (%expand(%concat("@",clumsy,%char,PercentageKick))~% landed)}
		} {
		#PRINT {No over time data available...}
		}
	}
#EVENT eventStabCount {
	#PRINT {%crlf <C dodgerblue>Stab Data:</C>}
	#IF (@clumsyTotalStab>0) {
		#PRINT {This session you've landed @clumsyLandStab out of @clumsyTotalStab stabs (@{clumsyPercentageStab}~% landed)}
		} {
		#PRINT {No current session data available...}
		}
	#IF (%expand(%concat("@",clumsy,%char,TotalStab))>0) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandStab)) out of %expand(%concat("@",clumsy,%char,TotalStab)) stabs (%expand(%concat("@",clumsy,%char,PercentageStab))~% landed)}
		} {
		#PRINT {No over time data available...}
		}
	}
#EVENT eventThrowCount {
	#PRINT {%crlf <C dodgerblue>Throw Data:</C>}
	#IF (@clumsyTotalThrow>0) {
		#PRINT {This session you've landed @clumsyLandThrow out of @clumsyTotalThrow throws (@{clumsyPercentageThrow}~% landed)}
		} {
		#PRINT {No current session data available...}
		}
	#IF (%expand(%concat("@",clumsy,%char,ThrowTotal))>0) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandThrow)) out of %expand(%concat("@",clumsy,%char,ThrowTotal)) throws (%expand(%concat("@",clumsy,%char,PercentageThrow))~% landed)}
		} {
		#PRINT {No over time data available...}
		}
	}
#EVENT eventCriticalCount {
	#PRINT {%crlf <C dodgerblue>Critical Throw Data:</C>}
	#IF (@clumsyTotalThrow>0) {
		#PRINT {This session you've landed @clumsyLandThrowCritical critical throws out of @clumsyLandThrow total landed throws (@{clumsyPercentageThrowCritical}~% crits landed)}
		} {
		#PRINT {No current session data available...}
		}
	#IF (%expand(%concat("@",clumsy,%char,LandThrow))>0) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandThrowCritical)) criticals out of %expand(%concat("@",clumsy,%char,LandThrow)) total landed throws (%expand(%concat("@",clumsy,%char,PercentageThrowCritical))~% crits landed)}
		} {
		#PRINT {No over time data available...}
		}
	}
#EVENT eventKickFail {
	#VAR clumsyMissKick (@clumsyMissKick+1)
	#VAR %concat(clumsy,%char,MissKick) (%expand(%concat("@",clumsy,%char,MissKick))+1)
	#VAR clumsyTotalKick (@clumsyLandKick+@clumsyMissKick)
	#VAR clumsyPercentageKick (@clumsyLandKick*100/@clumsyTotalKick)
	#VAR %concat(clumsy,%char,TotalKick) (%expand(%concat("@",clumsy,%char,LandKick))+%expand(%concat("@",clumsy,%char,MissKick)))
	#VAR %concat(clumsy,%char,PercentageKick) (%expand(%concat("@",clumsy,%char,LandKick))*100/%expand(%concat("@",clumsy,%char,TotalKick)))
	#IF (@showClumsy) {
		#PRINT {This session you've clumsied @clumsyMissKick out of @clumsyTotalKick kicks (@{clumsyPercentageKick}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've clumsied %expand(%concat("@",clumsy,%char,MissKick)) out of %expand(%concat("@",clumsy,%char,TotalKick)) kicks (%expand(%concat("@",clumsy,%char,PercentageKick))~% landed)}
		}
	}
#EVENT eventKickSuccess {
	#VAR clumsyLandKick (@clumsyLandKick+1)
	#VAR %concat(clumsy,%char,LandKick) (%expand(%concat("@",clumsy,%char,LandKick))+1)
	#VAR clumsyTotalKick (@clumsyLandKick+@clumsyMissKick)
	#VAR clumsyPercentageKick (@clumsyLandKick*100/@clumsyTotalKick)
	#VAR %concat(clumsy,%char,TotalKick) (%expand(%concat("@",clumsy,%char,LandKick))+%expand(%concat("@",clumsy,%char,MissKick)))
	#VAR %concat(clumsy,%char,PercentageKick) (%expand(%concat("@",clumsy,%char,LandKick))*100/%expand(%concat("@",clumsy,%char,TotalKick)))
	#IF (@showClumsy) {
		#PRINT {This session you've landed @clumsyLandKick out of @clumsyTotalKick kicks (@{clumsyPercentageKick}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandKick)) out of %expand(%concat("@",clumsy,%char,TotalKick)) kicks (%expand(%concat("@",clumsy,%char,PercentageKick))~% landed)}
		}	
	}
#EVENT eventThrowFail {
	#RAISE eventThrown
	#VAR clumsyMissThrow (@clumsyMissThrow+1)
	#VAR %concat(clumsy,%char,MissThrow) (%expand(%concat("@",clumsy,%char,MissThrow))+1)
	#VAR clumsyTotalThrow (@clumsyMissThrow+@clumsyLandThrow)
	#VAR clumsyPercentageThrow (@clumsyLandThrow*100/@clumsyTotalThrow)
	#VAR %concat(clumsy,%char,ThrowTotal) (%expand(%concat("@",clumsy,%char,MissThrow))+%expand(%concat("@",clumsy,%char,LandThrow)))
	#VAR %concat(clumsy,%char,PercentageThrow) (%expand(%concat("@",clumsy,%char,LandThrow))*100/%expand(%concat("@",clumsy,%char,ThrowTotal)))
	#IF (@showClumsy) {
		#PRINT {This session you've clumsied @clumsyMissThrow out of @clumsyTotalThrow throws (@{clumsyPercentageThrow}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've clumsied %expand(%concat("@",clumsy,%char,MissThrow)) out of %expand(%concat("@",clumsy,%char,ThrowTotal)) throws (%expand(%concat("@",clumsy,%char,PercentageThrow))~% landed)}
		}	
	}
#EVENT eventThrowSuccess {
	#RAISE eventThrown
	#VAR clumsyLandThrow (@clumsyLandThrow+1)
	#VAR %concat(clumsy,%char,LandThrow) (%expand(%concat("@",clumsy,%char,LandThrow))+1)
	#VAR clumsyTotalThrow (@clumsyMissThrow+@clumsyLandThrow)
	#VAR clumsyPercentageThrow (@clumsyLandThrow*100/@clumsyTotalThrow)
	#VAR %concat(clumsy,%char,ThrowTotal) (%expand(%concat("@",clumsy,%char,MissThrow))+%expand(%concat("@",clumsy,%char,LandThrow)))
	#VAR %concat(clumsy,%char,PercentageThrow) (%expand(%concat("@",clumsy,%char,LandThrow))*100/%expand(%concat("@",clumsy,%char,ThrowTotal)))
	#IF (@showClumsy) {
		#PRINT {This session you've landed @clumsyLandThrow out of @clumsyTotalThrow throws (@{clumsyPercentageThrow}~% landed)}
		}
	#IF (%expand(%concat("@",show,%char,OT))) {
		#PRINT {Since %expand(%concat("@",%char,OT)) you've landed %expand(%concat("@",clumsy,%char,LandThrow)) out of %expand(%concat("@",clumsy,%char,ThrowTotal)) throws (%expand(%concat("@",clumsy,%char,PercentageThrow))~% landed)}
		}
	}
#EVENT eventThrown {
	#T- clumsyThrowLand
	#T- clumsyThrowRip
	#T- clumsyThrowCrit
	#T- clumsyThrowDeflect
	#T- clumsyThrowMiss
	}
#CLASS 0

Re: HoM cMUD Scripts

Posted: Sat Jul 21, 2018 1:56 am
by Taziar
Type helpColors to view help file in client.

Image

Direct download: ColorsCMUD.txt

Code: Select all

#CLASS {Colors}
#ALIAS helpColors {
	#PRINT {%crlf <C dodgerblue>-----Colors Help File-----</C>}
	#PRINT {    <C dodgerblue>[Updated: 9/1/2019]</C>}
	#PRINT {}
	#PRINT { Type <C dodgerblue>colorAlert <type> <color> [bcolor]</C> to set colors for alerts of the specified type.}
	#PRINT {  Available colorAlert types: (shown in current set color) [background color optional]}
	#PRINT {   <C %replace(@colorAlertLow,","," ")> Low            (low priority alerts) </C>}
	#PRINT {   <C %replace(@colorAlertMedium,","," ")> Medium      (medium priority alerts) </C>}
	#PRINT {   <C %replace(@colorAlertHigh,","," ")> High          (high priority alerts) </C>}
	#PRINT {   <C %replace(@colorAlertDeadly,","," ")> Deadly     (highest priority alerts) </C>}
	#PRINT {      Note: Weaves targeted at you use the Deadly alert color.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>colorToggle <type></C> to toggle color triggers on/off.}
	#PRINT {  Available colorToggle types: (current toggle mode)}
	#PRINT {   MiscColors  %if(%class(Colors|MiscColors),"    (ON)","    (OFF)")}
	#PRINT {   SkillColors  %if(%class(Colors|SkillColors),"   (ON)","   (OFF)")}
	#PRINT {   WeavesReceived  %if(%class(Colors|WeavesReceived),"(ON)","(OFF)")}
	#PRINT {}
	}
#ALIAS colorAlert {
	#PRINT {}
	#IF (%null(%1)) {
		#PRINT { Usage: <C dodgerblue>colorAlert <type> <color> [bcolor]</C> [background color optional]"}
		#PRINT {  Available Alert types: (shown in current set color)"}
		#PRINT {   <C %replace(@colorAlertLow,","," ")> Low               (low priority alerts) </C>}
		#PRINT {   <C %replace(@colorAlertMedium,","," ")> Medium         (medium priority alerts) </C>}
		#PRINT {   <C %replace(@colorAlertHigh,","," ")> High             (high priority alerts) </C>}
		#PRINT {   <C %replace(@colorAlertDeadly,","," ")> Deadly        (highest priority alerts) </C>}
		#PRINT {     Note: Weaves targeted at you use the Deadly alert color.}
		#PRINT {}
		} {
		#IF (%class(%concat("colorAlert",%1))=-1) {
			#PRINT {%1 is an invalid type selection...}
			} {
			#IF (%null(%2)) {
				#PRINT {What color is that?...}
				} {
				#IF (%colorname(%2)=536870911 AND %color(%2)=0) {
					#VAR %concat("colorAlert",%1) {}
					#PRINT { %2 is an invalid color. %concat("colorAlert",%proper(%1)) variable cleared.}
					} {
					#IF (%null(%3)) {
						#VAR %concat("colorAlert",%1) {%2}
						#PRINT {Alert %proper(%1) color set: <C %2>%2</C>}
						} {
						#IF (%colorname(%3)=536870911 AND %color(%3)=0) {
							#VAR %concat("colorAlert",%1) {}
							#PRINT { %3 is an invalid color. %concat("colorAlert",%proper(%1)) variable cleared.}
							} {
							#VAR %concat("colorAlert",%1) {%concat(%2,",",%3)}
							#PRINT {Alert %proper(%1) color set: <C %2 %3>%2 %3</C>}
							}
						}
					}
				}
			}
		}
	}
#ALIAS colorToggle {
	#PRINT {}
	#IF (%null(%1)) {
		#PRINT { Usage: colorToggle <type>}
		#PRINT {  Available colorToggle types: (current toggle mode)}
		#PRINT {   CommColors  %if(%class(Colors|CommColors),"    (ON)","    (OFF)")}
		#PRINT {   MiscColors  %if(%class(Colors|MiscColors),"    (ON)","    (OFF)")}
		#PRINT {   SkillColors  %if(%class(Colors|SkillColors),"   (ON)","   (OFF)")}
		#PRINT {   WeavesReceived  %if(%class(Colors|WeavesReceived),"(ON)","(OFF)")}
		} {
		#IF (%class(Colors|%1)=-1) {
			#PRINT {%1 is an invalid type selection...}
			} {
			#IF (%class(Colors|%1)=1) {
				#T- {Colors|%1}
				#PRINT { Color triggers for %1 have been turned off.}
				} {
				#T+ {Colors|%1}
				#PRINT { Color triggers for %1 have been turned on.}
				}
			}
		}
	}
#VAR colorAlertDeadly {white,red}
#VAR colorAlertHigh {white,darkred}
#VAR colorAlertLow {white,royalblue}
#VAR colorAlertMedium {white,mediumblue}
#CLASS 0
#CLASS {Colors|SkillColors}
#TRIGGER {^(Your bash at )(*)( sends * sprawling!)$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertLow} %x1
		#PCOL {@colorAlertLow} %x3
		} {
		#CW @colorAlertLow
		}
	} "" {case}
#TRIGGER {^(As )(*)( avoids your bash, you topple over and fall to the ground!)$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertMedium} %x1
		#PCOL {@colorAlertMedium} %x3
		} {
		#CW @colorAlertMedium
		}
	} "" {case}
#TRIGGER {^(*)( sends )(*)( sprawling with a powerful bash!)$} {
	#IF (%begins(%1,~*)) {
		#IF (%3=you) {
			#PCOL {@colorAlertHigh} %x2
			#PCOL {@colorAlertHigh} %x3
			#PCOL {@colorAlertHigh} %x4
			} {
			#PCOL {@colorAlertMedium} %x2
			#PCOL {@colorAlertLow} %x3
			#PCOL {@colorAlertMedium} %x4
			}
		} {
		#IF (%begins(%3,~*)) {
			#PCOL {@colorAlertLow} %x1
			#PCOL {@colorAlertMedium} %x2
			#PCOL {@colorAlertMedium} %x4
			} {
			#IF (%3=you) {
				#CW @colorAlertHigh
				} {
				#CW @colorAlertMedium
				}
			}
		}
	} "" {case}
#TRIGGER {^(You dodge a bash from )(*)( who loses * balance and falls!)$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertLow} %x1
		#PCOL {@colorAlertLow} %x3
		} {
		#CW @colorAlertLow
		}
	} "" {case}
#TRIGGER {^(Suddenly )(*)( places * in your back!)$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertHigh} %x1
		#PCOL {@colorAlertHigh} %x3
		} {
		#CW @colorAlertHigh
		}
	} "" {case}
#TRIGGER {^(*)( clumsily approaches you with *, but you fend off the attack.)} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertLow} %x2
		} {
		#CW @colorAlertLow
		}
	} "" {case}
#TRIGGER {[A-Z]* starts barreling down on you, * aimed at your chest.} {
	#CW @colorAlertHigh
	} "" {case}
#TRIGGER {(*)( starts barreling down on you, * aimed at your chest.)} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertHigh} %x2
		} {
		#CW @colorAlertHigh
		}
	} "" {case}
#TRIGGER {^(Suddenly )(*)( charges you with *!)$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertHigh} %x1
		#PCOL {@colorAlertHigh} %x3
		} {
		#CW @colorAlertHigh
		}
	} "" {case}
#TRIGGER {^[A-Z]* clumsily charges you with *, but you deftly step aside.$} {
	#CW @colorAlertLow
	} "" {case}
#TRIGGER {^(*)( clumsily charges you with *, but you deftly step aside.)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertLow} %x2
		} {
		#CW @colorAlertLow
		}
	} "" {case}
#TRIGGER {(*)( wipes %w boots in your face!)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertHigh} %x2
		} {
		#CW @colorAlertHigh
		}
	} "" {case}
#TRIGGER {You're hit in solar plexus, wow, this is breathtaking!!$} {
	#CW @colorAlertHigh
	} "" {case}
#TRIGGER {^(*)( grunts in pain as %w is struck by *.)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertLow} %x2
		} {
		#CW @colorAlertLow
		}
	} "" {case}
#TRIGGER {^(*)( spasms in excruciating pain as %w is struck by *.)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertLow} %x2
		} {
		#CW @colorAlertLow
		}
	} "" {case}
#TRIGGER {^[A-Z]* rips through %w*'s guts as %w collapses to the ground.$} {
	#CW {@colorAlertLow}
	} "" {case}
#TRIGGER {^([A-Z]* rips through )(*)( guts as %w collapses to the ground.)$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertHigh} %x1
		#PCOL {@colorAlertHigh} %x3
		} {
		#CW @colorAlertHigh
		}
	} "" {case}
#TRIGGER {^[A-Z]* deflects * that was thrown at %w.$} {
	#CW {@colorAlertMedium}
	} "" {case}
#TRIGGER {^(*)( deflects * that was thrown at %w.)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertMedium} %x2
		} {
		#CW @colorAlertMedium
		}
	} "" {case}
#TRIGGER {^([A-Z]* just misses )(*)( and falls to the ground.)$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertMedium} %x1
		#PCOL {@colorAlertMedium} %x3
		} {
		#CW @colorAlertMedium
		}
	} "" {case}
#CLASS 0
#CLASS {Colors|WeavesReceived}
#TRIGGER {^The impact of an unseen force sends you sprawling!$} {
	#CW @colorAlertDeadly
	} "" {case}
#TRIGGER {^Arrrgggh!!! Your body is on FIRE! You have precious few moments to save your sorry life!$} {
	#CW @colorAlertDeadly
	} "" {case}
#TRIGGER {^The air around your eyes seems to catch fire, blinding you!$} {
	#CW @colorAlertDeadly
	} "" {case}
#TRIGGER {^A strangled cough racks your lungs, causing agony!$} {
	#CW @colorAlertDeadly
	} "" {case}
#TRIGGER {^(*)( hands weave a bright red flame...)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertDeadly} %x2
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#TRIGGER {^(You gasp in pain as streaks of fire from )(*)( burn your body!)$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertDeadly} %x1
		#PCOL {@colorAlertDeadly} %x3
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#TRIGGER {^(Your body is pierced by * spikes sent by )(*)!$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertDeadly} %x1
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#TRIGGER {^(*)( gestures and you begin to lose your balance.)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertDeadly} %x2
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#TRIGGER {^(*)( calls lightning from the sky to strike you, sizzling your insides!)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertDeadly} %x2
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#TRIGGER {^(Your body is burned by a %w fireball sent by )(*)!$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertDeadly} %x1
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#TRIGGER {^~*[A-Z]%w~* (gazes deeply into your soul.. very chilling.)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertDeadly} %x2
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#TRIGGER {^(You shiver from an icy cold force sent by )(*).$} {
	#IF (%begins(%2,~*)) {
		#PCOL {@colorAlertDeadly} %x1
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#TRIGGER {^(*)( waves at you, and a cold sweat begins attacking your every muscle.)$} {
	#IF (%begins(%1,~*)) {
		#PCOL {@colorAlertDeadly} %x2
		} {
		#CW @colorAlertDeadly
		}
	} "" {case}
#CLASS 0
#CLASS {Colors|MiscColors}
#TRIGGER {You aren't in touch with {saidin|saidar} to channel it.$} {#CW @colorAlertMedium} "" {case}
#TRIGGER {You are unable to sense the True Source at all from here.$} {#CW @colorAlertMedium} "" {case}
#TRIGGER {You feel isolated from the Source!$} {#CW @colorAlertMedium} "" {case}
#TRIGGER {You lose all sense of the True Source here.$} {#CW @colorAlertMedium} "" {case}
#TRIGGER {^You sense a hidden life form in the area...$} {#CW @colorAlertDeadly} "" {case}
#TRIGGER {~*KERBOOM~* The explosion rips you from the ground and tosses you through the air.$} {#CW @colorAlertDeadly} "" {case}
#TRIGGER {~*KERBOOM~* An explosion sounds in the distance.$} {#CW @colorAlertHigh} "" {case}
#TRIGGER {PANIC!  You couldn't escape!$} {#CW @colorAlertHigh} "" {case}
#TRIGGER {[A-Z]* is thrown from your hands as you are struck.$} {#CW @colorAlertDeadly} "" {case}
#TRIGGER {You disarm * weapon with one swift strike.$} {#CW @colorAlertMedium} "" {case}
#TRIGGER {You fumble * as you are struck.$} {#CW @colorAlertHigh} "" {case}
#TRIGGER {^Ouch! That Really did HURT!$} {#CW @colorAlertDeadly} "" {case}
#TRIGGER {No way!  You're fighting for your life!$} {#CW @colorAlertLow} "" {case}
#TRIGGER {You panic and attempt to flee!} {#CW @colorAlertMedium} "" {case}
#CLASS 0

Re: HoM cMUD Scripts

Posted: Sun Aug 26, 2018 2:21 am
by Taziar
Type helpCombat to view help file in client.



Direct download:

Code: Select all

Currently in debug

Re: HoM cMUD Scripts

Posted: Sun Aug 26, 2018 12:25 pm
by Taziar
Type helpComms to view help file in client.

Image

Direct download: CommsCMUD.txt

Code: Select all

#CLASS {Comms}
#ALIAS helpComms {
	#PRINT {%crlf <C dodgerblue>-----Comms Help File-----</C>}
	#PRINT {     <C dodgerblue>[Update: 8/31/2019]</C>}
	#PRINT { Adds all communications to a new window named Communications.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>gagComms</C> to toggle gagging communications from the main screen.}
	#PRINT {  Communication gag is: <C dodgerblue>%if(@commsGag,ON,OFF)</C>}
	#PRINT {}
	#PRINT { Type <C dodgerblue>colorComms <type> <color> [bcolor]</C> to set colors for comms of the specified type.}
	#PRINT {  Available colorComms types: (shown in current set color) [background color optional]}
	#PRINT {   <C %replace(@colorBellow,","," ")> Bellow    (in zone yells)</C>}
	#PRINT {   <C %replace(@colorChat,","," ")> Chat      (global chats)</C>}
	#PRINT {   <C %replace(@colorNarrate,","," ")> Narrate   (global narrates)</C>}
	#PRINT {}
	#PRINT { <C dodgerblue>-----note regarding unwanted prompts-----</C>}
	#PRINT { To ensure that prompts do not also become captured with comms and are not}
	#PRINT { send to the Communications window you must create a new trigger inside the}
	#PRINT { Communications window and insert the following:}
	#PRINT {}
	#PRINT {     trigger pattern: ^({o|*} * > )(*)$}
	#PRINT {     trigger command: #SUB {~%2}}
	#PRINT {}
	}
#ALIAS colorComms {
	#PRINT {}
	#IF (%null(%1)) {
		#PRINT { Usage: colorComms <type> <color> [bcolor] [background color optional]}
		#PRINT {  Available Comms types: (shown in current set color)}
		#PRINT {   <C %replace(@colorBellow,","," ")> Bellow    (in zone yells) </C>}
		#PRINT {   <C %replace(@colorChat,","," ")> Chat      (global chats) </C>}
		#PRINT {   <C %replace(@colorNarrate,","," ")> Narrate   (global narrates) </C>}
		#PRINT {}
		} {
		#IF (%class(%concat("color",%1))=-1) {
			#PRINT {%1 is an invalid type selection...}
			} {
			#IF (%null(%2)) {
				#PRINT {What color is that?...}
				} {
				#IF (%colorname(%2)=536870911 AND %color(%2)=0) {
					#VAR %concat("color",%1) {}
					#PRINT { %2 is an invalid color. %concat("color",%proper(%1)) variable cleared.}
					} {
					#IF (%null(%3)) {
						#VAR %concat("color",%1) {%2}
						#PRINT {Comms %proper(%1) color set: <C %2>%2</C>}
						} {
						#IF (%colorname(%3)=536870911 AND %color(%3)=0) {
							#VAR %concat("color",%1) {}
							#PRINT { %3 is an invalid color. %concat("color",%proper(%1)) variable cleared.}
							} {
							#VAR %concat("color",%1) {%concat(%2,",",%3)}
							#PRINT {Comms %proper(%1) color set: <C %2 %3>%2 %3</C>}
							}
						}
					}
				}
			}
		}
	}
#ALIAS gagComms {
	#IF (@commsGag) {
		#VAR commsGag {0}
		#PRINT {%crlf Main screen is set to show all communications.}
		} {
		#VAR commsGag {1}
		#PRINT {%crlf Main screen is set to gag all communications.}
		}
	}
#VAR commsGag {0}
#VAR colorBellow {royalblue}
#VAR colorChat {dimgray}
#VAR colorNarrate {saddlebrown}
#TRIGGER "commsChatTrigger" {You chat '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsNarrateTrigger" {You narrate '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsPrayTrigger" {You pray '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsReplyTrigger" {You reply to %x '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsTellTrigger" {You tell %x '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsAnswersTrigger" {%x answers your prayer '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsChatsTrigger" {%x chats '*'$} {
	#COLOR @colorChat
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsNarratesTrigger" {%x narrates '*'$} {
	#COLOR @colorNarrate
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsSpeaksTrigger" {%x speaks from the {Light|Dark} '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsTellsTrigger" {%x tells you '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsBellowTrigger" {You bellow '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsHissTrigger" {You hiss '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsDrawlTrigger" {You drawl '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsSayTrigger" {You say '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsBellowsTrigger" {%x bellows '*'$} {
	#COLOR @colorBellow
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsHissesTrigger" {%x hisses '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsDrawlsTrigger" {%x drawls '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#TRIGGER "commsSaysTrigger" {%x says '*'$} {
	#CAPTURE Communications
	#IF (@commsGag) {#GAG} {}
	} "" {case}
#CLASS 0

Re: HoM cMUD Scripts

Posted: Sun Aug 26, 2018 2:26 pm
by Taziar
Type helpCondition to view help file in client.

Image

Direct download: ConditionCMUD.txt

Code: Select all

#CLASS {Condition}
#ALIAS helpCondition {
	#PRINT {%crlf <C dodgerblue>-----Condition Help File-----</C>}
	#PRINT {     <C dodgerblue>[Updated: 9/21/2019]</C>}
	#PRINT { Triggers on any form of the look, diagnose, and examine commands.}
	#PRINT {}
	#PRINT { Adds condition status to end of a PC or Mob name.}
	#PRINT {  Example: Taziar is in excellent condition.  Healthy}
	#PRINT {}
	#PRINT {  Note: colors condition sub if Colors script installed.}
	#PRINT {   Example: Taziar has a few scratches. <C white royalblue> Healthy </C>}
	#PRINT {}
	}
#TRIGGER "condHealthyTrigger" {([A-Z]*) is in excellent condition(.)$} {
	#IF (%begins(%1,"It")) {} {
		#PSUB {. <C %replace(@colorAlertLow,","," ")> Healthy </C>} %x2
		}
	} "" {case}
#TRIGGER "condScratchedTrigger" {([A-Z]*) has a few scratches(.)$} {
	#PSUB {. <C %replace(@colorAlertLow,","," ")> Scratched </C>} %x2
	} "" {case}
#TRIGGER "condHurtTrigger" {([A-Z]*) has some small wounds and bruises(.)$} {
	#PSUB {. <C %replace(@colorAlertLow,","," ")> Hurt </C>} %x2
	} "" {case}
#TRIGGER "condWoundedTrigger" {([A-Z]*) has quite a few wounds(.)$} {
	#PSUB {. <C %replace(@colorAlertMedium,","," ")> Wounded </C>} %x2
	} "" {case}
#TRIGGER "condBatteredTrigger" {([A-Z]*) has some big nasty wounds and scratches(.)$} {
	#PSUB {. <C %replace(@colorAlertMedium,","," ")> Battered </C>} %x2
	} "" {case}
#TRIGGER "condBeatenTrigger" {([A-Z]*) looks pretty hurt(.)$} {
	#PSUB {. <C %replace(@colorAlertHigh,","," ")> Beaten </C>} %x2
	} "" {case}
#TRIGGER "condCriticalTrigger" {([A-Z]*) is in awful condition(.)$} {
	#PSUB {. <C %replace(@colorAlertHigh,","," ")> Critical </C>} %x2
	} "" {case}
#TRIGGER "condStunnedTrigger" {([A-Z]*) is lying here, stunned(.)$} {
	#PSUB {. <C %replace(@colorAlertDeadly,","," ")> STUNNED </C>} %x2
	} "" {case}
#TRIGGER "condIncapacitatedTrigger" {([A-Z]*) is bleeding awfully from big wounds(.)$} {
	#PSUB {. <C %replace(@colorAlertDeadly,","," ")> INCAPACITATED </C>} %x2
	} "" {case}
#CLASS 0

Re: HoM cMUD Scripts

Posted: Sun Aug 26, 2018 4:51 pm
by Taziar
Type helpDoors to view help file in client.

Image

Direct download: DoorsCMUD.txt

Code: Select all

#CLASS {Doors}
#ALIAS helpDoors {
	#PRINT {%crlf <C dodgerblue>-----Doors Help File-----</C>}
	#PRINT {   <C dodgerblue>[Updated: 10/12/2019]</C>}
	#PRINT { The ~@doorName variable is automatically filled with trigger events.}
	#PRINT {  Hint: set macros for open ~@doorName and close ~@doorName to spam a door.}
	#PRINT {}
	#PRINT {  Type <C dodgerblue><command></C> to complete action:}
	#PRINT {    <C dodgerblue>cd</C> to close  ~@doorName}
	#PRINT {    <C dodgerblue>kd</C> to knock  ~@doorName}
	#PRINT {    <C dodgerblue>ld</C> to lock   ~@doorName}
	#PRINT {    <C dodgerblue>od</C> to open   ~@doorName}
	#PRINT {    <C dodgerblue>pd</C> to pick   ~@doorName}
	#PRINT {    <C dodgerblue>ud</C> to unlock ~@doorName}
	#PRINT {}
	#PRINT {   <C dodgerblue>cda</C> to close all doors (door names must be saved in map properties).}
	#PRINT {   <C dodgerblue>oda</C> to open  all doors (door names must be saved in map properties).}
	#PRINT {}
	#PRINT { Type <C dodgerblue><command> <direction></C> to use door name saved in map properties for that direction.}
	#PRINT {  Example: cd n to close ~%doorname north (~%doorName is door name saved in map properties)}
	#PRINT {}
	#PRINT { Recognized directions: <C dodgerblue>n e s w u d</C>}
	#PRINT {  Note: anything not a recognized direction will be ignored and <command> ~@doorName used instead.}
	#PRINT {   Example: cd sw (incorrect directional) will send command: <C dodgerblue>close ~@doorName</C>}
	#PRINT {}
	#PRINT { Type <C dodgerblue> showDoorExits</C> to toggle door name in exit line function on/off.}
	#PRINT {  Example: [ obvious exits: E W ] [ E: chamberdoor ]}
	#PRINT {   Current toggle: <C dodgerblue>%if(@showDoorExits,ON,OFF)</C>}
	#PRINT {}
	#PRINT { Type <C dodgerblue>setDoor <direction></C> to create ~@doorName in that direction on your map.}
	#PRINT {  Example: setDoor n to create a door north of current map location named ~@doorName.}
	#PRINT {}
	#PRINT { Type <C dodgerblue>setDoor <direction> <door name></C> to create door in direction with given name.}
	#PRINT {  Example: [setDoor s gate] to create a door south of current map location named gate.}
	#PRINT {   Note: the setDoor command sets door name the same on both sides of door,}
	#PRINT {    must manually adjust room properties for doors with different named sides.}
	#PRINT {}
	}
#ALIAS setDoor {
	#IF (%ismember(%1,@doorDirection)) {
		#MENU {Mapper|File|Map}
		#IF (%len(%2)) {#DOOR %1 %2} {#DOOR %1 @doorName}
		#MENU {Mapper|File|Follow}
		}
	}
#ALIAS cd {
	#IF (%ismember(%lower(%1),@doorDirection)) {
		#IF (%null(%doorname(,%1))) {
			#PRINT {%crlf Door name not saved in map properties for that direction... %crlf}
			} {
			#SEND {close %doorname(,%1) %item(@doorDirectionInput,%ismember(%lower(%1),@doorDirection))}
			#IF (@doorName=%doorname(,%1)) {} {
				#VAR doorName {%doorname(,%1)}
				#UPDATE Macros
				#PRINT {%crlf doorName is now set as: <C dodgerblue>@doorName</C> %crlf}
				}
			}
		} {
		#SEND {close @doorName}
		}
	}
#ALIAS kd {
	#IF (%ismember(%lower(%1),@doorDirection)) {
		#IF (%null(%doorname(,%1))) {
			#PRINT {%crlf Door name not saved in map properties for that direction... %crlf}
			} {
			#SEND {knock %doorname(,%1) %item(@doorDirectionInput,%ismember(%lower(%1),@doorDirection))}
			#IF (@doorName=%doorname(,%1)) {} {
				#VAR doorName {%doorname(,%1)}
				#UPDATE Macros
				#PRINT {%crlf doorName is now set as: <C dodgerblue>@doorName</C> %crlf}
				}
			}
		} {
		#SEND {knock @doorName}
		}
	}
#ALIAS ld {
	#IF (%ismember(%lower(%1),@doorDirection)) {
		#IF (%null(%doorname(,%1))) {
			#PRINT {%crlf Door name not saved in map properties for that direction... %crlf}
			} {
			#SEND {lock %doorname(,%1) %item(@doorDirectionInput,%ismember(%lower(%1),@doorDirection))}
			#IF (@doorName=%doorname(,%1)) {} {
				#VAR doorName {%doorname(,%1)}
				#UPDATE Macros
				#PRINT {%crlf doorName is now set as: <C dodgerblue>@doorName</C> %crlf}
				}
			}
		} {
		#SEND {lock @doorName}
		}
	}
#ALIAS od {
	#IF (%ismember(%lower(%1),@doorDirection)) {
		#IF (%null(%doorname(,%1))) {
			#PRINT {%crlf Door name not saved in map properties for that direction... %crlf}
			} {
			#SEND {open %doorname(,%1) %item(@doorDirectionInput,%ismember(%lower(%1),@doorDirection))}
			#IF (@doorName=%doorname(,%1)) {} {
				#VAR doorName {%doorname(,%1)}
				#UPDATE Macros
				#PRINT {%crlf doorName is now set as: <C dodgerblue>@doorName</C> %crlf}
				}
			}
		} {
		#SEND {open @doorName}
		}
	}
#ALIAS pd {
	#IF (%ismember(%lower(%1),@doorDirection)) {
		#IF (%null(%doorname(,%1))) {
			#PRINT {%crlf Door name not saved in map properties for that direction... %crlf}
			} {
			#SEND {pick %doorname(,%1) %item(@doorDirectionInput,%ismember(%lower(%1),@doorDirection))}
			#IF (@doorName=%doorname(,%1)) {} {
				#VAR doorName {%doorname(,%1)}
				#UPDATE Macros
				#PRINT {%crlf doorName is now set as: <C dodgerblue>@doorName</C> %crlf}
				}
			}
		} {
		#SEND {pick @doorName}
		}
	}
#ALIAS ud {
	#IF (%ismember(%lower(%1),@doorDirection)) {
		#IF (%null(%doorname(,%1))) {
			#PRINT {%crlf Door name not saved in map properties for that direction... %crlf}
			} {
			#SEND {unlock %doorname(,%1) %item(@doorDirectionInput,%ismember(%lower(%1),@doorDirection))}
			#IF (@doorName=%doorname(,%1)) {} {
				#VAR doorName {%doorname(,%1)}
				#UPDATE Macros
				#PRINT {%crlf doorName is now set as: <C dodgerblue>@doorName</C> %crlf}
				}
			}
		} {
		#SEND {unlock @doorName}
		}
	}
#ALIAS cda {
	#FORALL %roomexit() {
		#IF (%null(%doorname(,%i))) {} {
			#SEND {close %doorname(,%i) %item(@doorDirectionInput,%ismember(%i,@doorDirection))}
			}
		}
	}
#ALIAS oda {
	#FORALL %roomexit() {
		#IF (%null(%doorname(,%i))) {} {
			#SEND {open %doorname(,%i) %item(@doorDirectionInput,%ismember(%i,@doorDirection))}
			}
		}
	}
#VAR showDoorExits 1
#VAR doorName {}
#VAR doorExitsName {}
#VAR doorDirection {d|e|n|s|u|w}
#VAR doorDirectionInput {down|east|north|south|up|west}
#VAR doorRoomName {}
#TRIGGER "doorSeemsTrigger" {The (%w) seems to be closed.$} {
	#IF (%1=@doorName) {} {
		#VAR doorName %1
		#UPDATE Macros
		#PRINT { doorName is now set as: <C dodgerblue>@doorName</C>}
		}
	} "" {case}
#TRIGGER "doorHiddenTrigger" {You skillfully discover a hidden (%w).$} {
	#IF (%1=@doorName) {} {
		#VAR doorName %1
		#UPDATE Macros
		#PRINT { doorName is now set as: <C dodgerblue>@doorName</C>}
		}
	} "" {case}
#TRIGGER "doorClosedTrigger" {The (%w) is closed.$} {
	#IF (%1=@doorName) {} {
		#VAR doorName %1
		#UPDATE Macros
		#PRINT { doorName is now set as: <C dodgerblue>@doorName</C>}
		}
	} "" {case}
#TRIGGER "doorOpenTrigger" {The (%w) is open.$} {
	#IF (%1=@doorName) {} {
		#VAR doorName %1
		#UPDATE Macros
		#PRINT { doorName is now set as: <C dodgerblue>@doorName</C>}
		}
	} "" {case}
#TRIGGER "doorObviouslyTrigger" {The (%w) is obviously open.$} {
	#IF (%1=@doorName) {} {
		#VAR doorName %1
		#UPDATE Macros
		#PRINT { doorName is now set as: <C dodgerblue>@doorName</C>}
		}
	} "" {case}
#TRIGGER "doorVisableTrigger" {The (%w) is quite visible.$} {
	#IF (%1=@doorName) {} {
		#VAR doorName %1
		#UPDATE Macros
		#PRINT { doorName is now set as: <C dodgerblue>@doorName</C>}
		}
	} "" {case}
#TRIGGER "doorExitsTrigger" {^(~[ obvious exits: *~])$} {
	#FORALL @doorDirection {
		#IF (%null(%doorname(,%i))) {} {#ADDITEM doorExitsName %concat(%upper(%i):," ",%doorname(,%i))}
		}
	#IF (%null(@doorExitsName)) {} {
		#SUB {%1 [ %replace(@doorExitsName,"|"," ") ]}
		}
	#VAR doorExitsName {}
	} "" {case}
#CLASS 0

Re: HoM cMUD Scripts

Posted: Wed Sep 05, 2018 3:35 pm
by Taziar
Type helpFive15 to view help file in client.

Image

Direct download: Five15CMUD.txt

Code: Select all

#CLASS {Five15}
#ALIAS helpfive15 {
	#PRINT {%crlf <C dodgerblue>-----Five15 Help File-----</C>}
	#PRINT {    <C dodgerblue>[Updated: 8/31/2019]</C>}
	#PRINT {}
	#PRINT { Type <C dodgerblue>515</C> to view current time waiting to reconnect.}
	#PRINT {  Note: automatically inputs 515 into command line on disconnection.}
	#PRINT {}
	#PRINT { Renting, quitting, and 'sleep well and wake' automatically start the 5/15 timer.}
	#PRINT {  Note: includes a 30 minute timer for immortal and darkfriend switching.}
	#PRINT {}
	#PRINT { 20 minute linkless timer starts on any other disconnection.}
	#PRINT {  Note: Once linkless timer finishes the 5/15 timer will start.}
	#PRINT {}
	}
#ALIAS 515 {
	#PRINT {}
	#IF (%alarm(fiveSameSideAlarm)>0) {
		#PRINT { <C darkgray>Sameside wait:</C> %eval(%alarm(fiveSameSideAlarm)/1000/60\1440)m %eval(%alarm(fiveSameSideAlarm)/1000\60)s}
		}
	#IF (%alarm(fiveCrossRaceAlarm)>0) {
		#PRINT { <C darkgray>Crossrace wait:</C> %eval(%alarm(fiveCrossRaceAlarm)/1000/60\1440)m %eval(%alarm(fiveCrossRaceAlarm)/1000\60)s}
		}
	#IF (%alarm(fiveLinklessAlarm)>0) {
		#PRINT { <C darkgray>Time until linkless rented:</C> %eval(%alarm(fiveLinklessAlarm)/1000/60\1440)m %eval(%alarm(fiveLinklessAlarm)/1000\60)s}
		}
	#IF (%alarm(fiveThirtyAlarm)>0 AND %alarm(fiveLinklessAlarm)=-1) {
		#PRINT { <C darkgray>Thirty timer:</C> %eval(%alarm(fiveThirtyAlarm)/1000/60\1440)m %eval(%alarm(fiveThirtyAlarm)/1000\60)s}
		}
	#IF (%class(fiveSameSideAlarm)=-1 AND %class(fiveCrossRaceAlarm)=-1 AND %class(fiveLinklessAlarm)=-1 AND %class(fiveThirtyAlarm)=-1) {
		#PRINT {%crlf Five15 timer not active...}
		}
	}
#TRIGGER "five15Sleep" {You {drawl|hiss|say} 'sleep well and wake'} {
	#T+ event515Timer
	#T- event20Timer
	#ALARM "five15ResetAlarm" {+5} {
		#T- event515Timer
		#T+ event20Timer
		} "Five15"
	} "" {}
#ONINPUT {^{ren|rent}$} {
	#T+ event515Timer
	#T- event20Timer
	#ALARM "five15RentAlarm" {+5} {
		#T- event515Timer
		#T+ event20Timer
		} "Five15"
	}
#ONINPUT {^quit$} {
	#T+ event515Timer
	#T- event20Timer
	#ALARM "five15QuitAlarm" {+5} {
		#T- event515Timer
		#T+ event20Timer
		} "Five15"
	}
#EVENT event515Timer {
	#ALARM "five15Alarm" {+1} {
		#PRINT {%crlf<C white red> 5/15 minute countdown started... now! </C> <C red>(</C>%time(h:nn:ss)<C red>)</C>}
		} "Five15"
	#ALARM "fiveSameSideAlarm" {+301} {
		#BEEP 0
		#PRINT {%crlf<C white green> You may log on a sameside alt. </C>}
		#BEEP 0
		} "Five15"
	#ALARM "fiveCrossRaceAlarm" {+901} {
		#BEEP 0
		#PRINT {%crlf<C white green> You may log on a crossrace alt. </C>}
		#BEEP 0
		} "Five15"
	#ALARM "fiveThirtyAlarm" {+1801} {
		#BEEP 0
		#PRINT {%crlf<C white green> Thirty minute wait completed... </C>}
		#BEEP 0
		} "Five15"
	#INPUT 515 1
	}
#EVENT event20Timer {
	#PRINT {%crlf<C white blue> 20 minute linkless countdown started... now! </C> <C blue>(</C>%time(h:nn:ss)<C blue>)</C>}
	#ALARM "fiveLinklessAlarm" {+1201} {
		#BEEP 0
		#T+ event515Timer
		#RAISE event515Timer
		#BEEP 0
		} "Five15"
	#INPUT 515 1
	}
#EVENT OnConnect {
	#IF (%class(fiveSameSideAlarm)=1) {
		#TEMP {Trigger {fiveSameSideAlarm} removed.} {#GAG} "Five15" {case|verbatim}
		#UNTRIGGER fiveSameSideAlarm
		}
	#IF (%class(fiveCrossRaceAlarm)=1) {
		#TEMP {Trigger {fiveCrossRaceAlarm} removed.} {#GAG} "Five15" {case|verbatim}
		#UNTRIGGER fiveCrossRaceAlarm
		}
	#IF (%class(fiveLinklessAlarm)=1) {
		#TEMP {Trigger {fiveLinklessAlarm} removed.} {#GAG} "Five15" {case|verbatim}
		#UNTRIGGER fiveLinklessAlarm
		}
	#IF (%class(fiveThirtyAlarm)=1) {
		#TEMP {Trigger {fiveThirtyAlarm} removed.} {#GAG} "Five15" {case|verbatim}
		#UNTRIGGER fiveThirtyAlarm
		}
	#T- event515Timer
	#T+ event20Timer
	#INPUT {}
	}
#EVENT OnDisconnect {
	#RAISE event515Timer
	#RAISE event20Timer
	}
#CLASS 0