Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
neo2083
Beginner


Joined: 06 Feb 2004
Posts: 17
Location: USA

PostPosted: Mon Mar 08, 2004 8:27 am   

Script Help for the Working man
 
I play on MateriaMagica and I wanna make a script that takes in a trigger and from the info it gathers in that trigger, stores the results in a variable so that i can then dispkay the information in my status window. Now, i know how to put the results on my status window, and I know how to make triggers and stuff, but there are alot of possibilites to capture and I would like some reccomendations on how to make the script as small as possible. Thanks :)

In my mud there are 2 moons, Trigael and Marabah, and depending on what cycles the moons are in worldgates around the world may open up.

Let me Start with some needed info for all those who wanna take a shot at this:

Based upon your estimation, it is morning.
The twin moons, Trigael and Marabah are in the phases:
Trigael: (gibbous waning) Marabah: (gibbous waning) <---------This is the line I need to capture
Materia Magica has been up since: Tue Feb 24 21:53:39 2004.
The current system time is: Mon Mar 8 00:26:40 2004.

*** The above is an output I recieve from the mud when type in the command "time" ***

Below is a table with all the possible combinations i need to check for:


Full Trigael

Trigael, Marabah: full, full
(662, 746) Rune on plane Alyria <-------As an example, when Trigael is in it's Full Cycle, and Marabah is also in its
(625, 461) Xaventry on plane Alyria Full cycle, worldgates near Rune and Xaventry will open up.

Trigael, Marabah: full, gibbous waning
(662, 746) Rune on plane Alyria
(1177, 384) Lowangen on plane Alyria

Trigael, Marabah: full, half waning
(662, 746) Rune on plane Alyria
(967, 699) Arcane Archipelago on plane Alyria

Trigael, Marabah: full, crescent waning
(662, 746) Rune on plane Alyria
(502, 1281) Sigil on plane Alyria

Trigael, Marabah: full, new
(662, 746) Rune on plane Alyria
(1015, 1116) Capture the Flag Arena on plane Alyria

Trigael, Marabah: full, crescent waxing
(662, 746) Rune on plane Alyria
(1279, 1053) Deceit on plane Alyria

Trigael, Marabah: full, half waxing
(662, 746) Rune on plane Alyria
(1674, 541) Templeton on plane Alyria

Trigael, Marabah: full, gibbous waxing
(662, 746) Rune on plane Alyria
(-1, -1) Ethereal Void on plane Void


Gibbous Waning Trigael

Trigael, Marabah: gibbous waning, full
(625, 461) Xaventry on plane Alyria
(1177, 384) Lowangen on plane Alyria

Trigael, Marabah: gibbous waning, gibbous waning
(625, 461) Xaventry on plane Alyria
(967, 699) Arcane Archipelago on plane Alyria

Trigael, Marabah: gibbous waning, half waning
(625, 461) Xaventry on plane Alyria
(502, 1281) Sigil on plane Alyria

Trigael, Marabah: gibbous waning, crescent waning
(625, 461) Xaventry on plane Alyria
(1015, 1116) Capture the Flag Arena on plane Alyria

Trigael, Marabah: gibbous waning, new
(625, 461) Xaventry on plane Alyria
(1279, 1053) Deceit on plane Alyria

Trigael, Marabah: gibbous waning, crescent waxing
(625, 461) Xaventry on plane Alyria
(1674, 541) Templeton on plane Alyria

Trigael, Marabah: gibbous waning, half waxing
(625, 461) Xaventry on plane Alyria
(662, 746) Rune on plane Alyria

Trigael, Marabah: gibbous waning, gibbous waxing
(625, 461) Xaventry on plane Alyria
(1538, 430) Decara on plane Underworld


Half Waning Trigael

Trigael, Marabah: half waning, full
(1177, 384) Lowangen on plane Alyria
(967, 699) Arcane Archipelago on plane Alyria

Trigael, Marabah: half waning, gibbous waning
(1177, 384) Lowangen on plane Alyria
(502, 1281) Sigil on plane Alyria

Trigael, Marabah: half waning, half waning
(1177, 384) Lowangen on plane Alyria
(1015, 1116) Capture the Flag Arena on plane Alyria

Trigael, Marabah: half waning, crescent waning
(1177, 384) Lowangen on plane Alyria
(1279, 1053) Deceit on plane Alyria

Trigael, Marabah: half waning, new
(1177, 384) Lowangen on plane Alyria
(1674, 541) Templeton on plane Alyria

Trigael, Marabah: half waning, crescent waxing
(1177, 384) Lowangen on plane Alyria
(662, 746) Rune on plane Alyria

Trigael, Marabah: half waning, half waxing
(1177, 384) Lowangen on plane Alyria
(625, 461) Xaventry on plane Alyria

Trigael, Marabah: half waning, gibbous waxing
(1177, 384) Lowangen on plane Alyria
(1538, 430) Decara on plane Underworld


Crescent Waning Trigael

Trigael, Marabah: crescent waning, full
(967, 699) Arcane Archipelago on plane Alyria
(502, 1281) Sigil on plane Alyria

Trigael, Marabah: crescent waning, gibbous waning
(967, 699) Arcane Archipelago on plane Alyria
(1015, 1116) Capture the Flag Arena on plane Alyria

Trigael, Marabah: crescent waning, half waning
(967, 699) Arcane Archipelago on plane Alyria
(1279, 1053) Deceit on plane Alyria

Trigael, Marabah: crescent waning, crescent waning
(967, 699) Arcane Archipelago on plane Alyria
(1674, 541) Templeton on plane Alyria

Trigael, Marabah: crescent waning, new
(967, 699) Arcane Archipelago on plane Alyria
(662, 746) Rune on plane Alyria

Trigael, Marabah: crescent waning, crescent waxing
(967, 699) Arcane Archipelago on plane Alyria
(625, 461) Xaventry on plane Alyria

Trigael, Marabah: crescent waning, half waxing
(967, 699) Arcane Archipelago on plane Alyria
(1177, 384) Lowangen on plane Alyria

Trigael, Marabah: crescent waning, gibbous waxing
(502, 1281) Sigil on plane Alyria
(389, 81) Hellbent Mountain on plane Faerie


New Trigael

Trigael, Marabah: new, full
(502, 1281) Sigil on plane Alyria
(1015, 1116) Capture the Flag Arena on plane Alyria

Trigael, Marabah: new, gibbous waning
(502, 1281) Sigil on plane Alyria
(1279, 1053) Deceit on plane Alyria

Trigael, Marabah: new, half waning
(502, 1281) Sigil on plane Alyria
(1674, 541) Templeton on plane Alyria

Trigael, Marabah: new, crescent waning
(502, 1281) Sigil on plane Alyria
(662, 746) Rune on plane Alyria

Trigael, Marabah: new, new
(502, 1281) Sigil on plane Alyria
(625, 461) Xaventry on plane Alyria

Trigael, Marabah: new, crescent waxing
(502, 1281) Sigil on plane Alyria
(1177, 384) Lowangen on plane Alyria

Trigael, Marabah: new, half waxing
(502, 1281) Sigil on plane Alyria
(967, 699) Arcane Archipelago on plane Alyria

Trigael, Marabah: new, gibbous waxing
(1538, 430) Decara on plane Underworld
(625, 461) Xaventry on plane Alyria


Crescent Waxing Trigael

Trigael, Marabah: crescent waxing, full
(1015, 1116) Capture the Flag Arena on plane Alyria
(1279, 1053) Deceit on plane Alyria

Trigael, Marabah: crescent waxing, gibbous waning
(1015, 1116) Capture the Flag Arena on plane Alyria
(1674, 541) Templeton on plane Alyria

Trigael, Marabah: crescent waxing, half waning
(1015, 1116) Capture the Flag Arena on plane Alyria
(662, 746) Rune on plane Alyria

Trigael, Marabah: crescent waxing, crescent waning
(1015, 1116) Capture the Flag Arena on plane Alyria
(625, 461) Xaventry on plane Alyria

Trigael, Marabah: crescent waxing, new
(1015, 1116) Capture the Flag Arena on plane Alyria
(1177, 384) Lowangen on plane Alyria

Trigael, Marabah: crescent waxing, crescent waxing
(1015, 1116) Capture the Flag Arena on plane Alyria
(967, 699) Arcane Archipelago on plane Alyria

Trigael, Marabah: crescent waxing, half waxing
(1279, 1053) Deceit on plane Alyria
(502, 1281) Sigil on plane Alyria

Trigael, Marabah: crescent waxing, gibbous waxing
(76, 301) Seelie Castle on plane Faerie
(1674, 541) Templeton on plane Alyria


Half Waxing Trigael

Trigael, Marabah: half waxing, full
(1279, 1053) Deceit on plane Alyria
(1674, 541) Templeton on plane Alyria

Trigael, Marabah: half waxing, gibbous waning
(1279, 1053) Deceit on plane Alyria
(662, 746) Rune on plane Alyria

Trigael, Marabah: half waxing, half waning
(1279, 1053) Deceit on plane Alyria
(625, 461) Xaventry on plane Alyria

Trigael, Marabah: half waxing, crescent waning
(1279, 1053) Deceit on plane Alyria
(1177, 384) Lowangen on plane Alyria

Trigael, Marabah: half waxing, new
(1279, 1053) Deceit on plane Alyria
(967, 699) Arcane Archipelago on plane Alyria

Trigael, Marabah: half waxing, crescent waxing
(1279, 1053) Deceit on plane Alyria
(502, 1281) Sigil on plane Alyria

Trigael, Marabah: half waxing, half waxing
(1279, 1053) Deceit on plane Alyria
(1015, 1116) Capture the Flag Arena on plane Alyria

Trigael, Marabah: half waxing, gibbous waxing
(1752, 984) Vir on plane Underworld
(1177, 384) Lowangen on plane Alyria


Gibbous Waxing Trigael

Trigael, Marabah: gibbous waxing, full
(1674, 541) Templeton on plane Alyria
(662, 746) Rune on plane Alyria

Trigael, Marabah: gibbous waxing, gibbous waning
(1674, 541) Templeton on plane Alyria
(625, 461) Xaventry on plane Alyria

Trigael, Marabah: gibbous waxing, half waning
(1674, 541) Templeton on plane Alyria
(1177, 384) Lowangen on plane Alyria

Trigael, Marabah: gibbous waxing, crescent waning
(1674, 541) Templeton on plane Alyria
(967, 699) Arcane Archipelago on plane Alyria

Trigael, Marabah: gibbous waxing, new
(1674, 541) Templeton on plane Alyria
(502, 1281) Sigil on plane Alyria

Trigael, Marabah: gibbous waxing, crescent waxing
(1674, 541) Templeton on plane Alyria
(1015, 1116) Capture the Flag Arena on plane Alyria

Trigael, Marabah: gibbous waxing, half waxing
(1674, 541) Templeton on plane Alyria
(1279, 1053) Deceit on plane Alyria

Trigael, Marabah: gibbous waxing, gibbous waxing
(1234, 865) Hotel Hello on plane Underworld
(662, 746) Rune on plane Alyria
Reply with quote
wilh
Wanderer


Joined: 08 Feb 2001
Posts: 89
Location: USA

PostPosted: Mon Mar 08, 2004 1:20 pm   
 
quote:

Based upon your estimation, it is morning.
The twin moons, Trigael and Marabah are in the phases:
Trigael: (gibbous waning) Marabah: (gibbous waning) <---------This is the line I need to capture
Materia Magica has been up since: Tue Feb 24 21:53:39 2004.
The current system time is: Mon Mar 8 00:26:40 2004.


Well, here's the first part. Note that this has not been tested, so please excuse any bugs. It should be close, however.
Code:

#VAR moonStates {full|gibbous waning|half waning|crescent waning|new|crescent waxing|half waxing|gibbous waxing}
#TRIGGER {^Trigael: ~((@moonStates)~) Marabah: ~((@moonStates)~)$} {#VAR TrigaelState {};#VAR MarabahState {}}

If you then need some lookup routines to display currently available world gates, you could use the database functions. Here's a way to start:
Code:

#ADDKEY worldGates {gibbous waxing-gibbous waxing} {(1234,865) Hotel Hello on plane Underworld|(662,746) Rune on plane Alyria}
#ADDKEY worldGates {gibbous waxing-half waxing} {((1674, 541) Templeton on plane Alyria|(1279, 1053) Deceit on plane Alyria}
.
.
etc.

And then to access the results:
Code:

#ALIAS showWorldgates {#SHOW Trigael, Marabah: @{trigaelState},@{marabahState};#FORALL %db(@worldGates,{@{trigaelState}-@marabahState}) {#SHOW %i}}

I hope this helps to get you started. The tedious part will be to put in all the information initially. Also, you might want to consider setting the trigger so that it is initially inactive and is only activated when you type the
Code:
time
command.

Cheers,

Wil
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net