Jump to content

Meleryn's stargazing dialogue needs help


ericp07

Recommended Posts

Meleryn and the PC occasionally spend time stargazing at night. I know there are some coding errors, but I'm not sure what corrections are needed, so I'd appreciate some help, please. Conditions for those blocks that need them are in EP#MelD.baf. Thanks in advance for looking and guidance!

 

//////////
// Stargazing
//////////
// Legendary constellations - Corellon's Tears
CHAIN
IF ~Global("EP#MelCorTears","GLOBAL",1)~ EP#MELJ EP#MelCorTears
~Do you see that string of five stars?~
DO ~SG("EP#MelCorTears",2)~
END
++ ~What of it?
++ ~I've read that it's named Belnimbra's Belt, for the legend of the first human female to have been turned into a swanmay, and how Lathander chased after her.~ EXTERN EP#MELJ EP#MelBelnBelt
+ ~Race(Player1,ELF)~ + ~Yes, Corellon's Tears, one of the oldest named constellations.

CHAIN
IF ~~ EP#MELJ EP#MelBelnBelt
~Hehe, it's funny to imagine Lathander doing that!~
= IF ~!Race(PLAYER1,ELF)~ ~We elves believe the Tears are the tears of grief Corellon cried when Lloth corrupted the drow, and elf first fought elf. Our legends also say the Tears glowed blood-red during the Fall of Myth Drannor.~
= IF ~!Race(PLAYER1,HALFLING)~ ~Halflings call it The Pipe.~
END
+ ~!Race(PLAYER1,HALFLING)~ + ~Why doesn't that surprise me? They do love their pipes, don't they?~ EXIT
++ ~I prefer the Lathander story. It's more upbeat.~ EXIT

// Sacred Stars - Karpri
CHAIN
IF ~Global("EP#MelKarpri","GLOBAL",1)~ EP#MELJ EP#MelKarpri
~There... that blue-green star...~
DO ~SG("EP#MelKarpri",2)~
END
+ ~!Race(Player1,ELF)~ + ~Yes, that's Karpri, associated with Ishtishia, goddess of elemental water.~ + EP#MelKarpriOchael
+ ~Race(Player1,ELF)~ + ~It's Ochael, sacred to Rillifane Rallathil, The Leaflord.~ + EP#MelOchael

IF ~~ EP#MelKarpriOchael
SAY
 ~We elves call Karpri Ochael, and hold it sacred to Rillifane Rallathil.~
IF ~~ EXIT
END

IF ~~ EP#MelOchael
 ~Our special patron watches over us day and night alike.~
IF ~~ EXIT
END

// Legendary constellations - Adarivael; Sacred Stars - Anadia
CHAIN
IF ~Global("EP#MelAdarivaelAnadia","GLOBAL",1)~ EP#MELJ EP#MelAdarivaelAnadia
~Adarivael is another elven constellation. See how it's formed by three lines of stars that come together, each with a star cluster at its outer end? Where those lines come together is due east.~
DO ~SG("EP#MelAdarivaelAnadia",2)~
END
+ ~Race(Player1,HUMAN)~ + ~My people call those stars the Arrows of the Gods, or the Sun's Signpost.~ EXTERN EP#MELJ EP#MelAdarAnadSacredSol

CHAIN
IF ~~ EP#MELJ EP#MelAdarAnadSacredSol
 ~To elves, Adarivael is sacred to Solonor Thelandira, along with another, separate star. Let's see... where is it?~
 = ~Yes, look up there. See that reddish star?~
END
+ ~!Race(Player1,HUMAN)~ + ~That's Anadia. It's associated with the element of fire, and is sacred to Kossuth. My people often associate it with Garagos the Reaver.~ EXTERN EP#MELJ EP#MelUlu
+ ~Race(Player1,HUMAN)~ + ~That's Anadia. It's associated with the element of fire, and is sacred to Kossuth. My people often associate it with Garagos the Reaver.~ EXTERN EP#MELJ EP#MelUlu

CHAIN
IF ~~ EP#MELJ EP#MelUlu
 ~That's right! Orcs call the star Gruumsh's Eye. Their legends claim that, at the end of the world, the Eye will purify Faerun in a rain of fire, leaving only orcs to rule. I find that idea highly unlikely!~
END
++ ~Heh, yes, orcs come out on top in their legends... but not so much in real life, eh?~ EXTERN EP#MELJ EP#MelGoodOrc

IF ~~ EP#MelGoodOrc
 SAY
 ~Not if *we* have anything to do with it. The only good orc is a dead orc!~
IF ~!Race(Player1,ELF)~ ~My people call it Uluemyn. We hold it sacred to Solonor Thelandira, god of archery.~
IF ~~ EXIT
END

// Legendary constellations - Cassima
CHAIN
IF ~Global("EP#MelCassima","GLOBAL",1)~ EP#MELJ EP#MelCassima
~&--#60;CHARNAME&--#62;, do you know that constellation up there? See the group of stars?~
DO ~SG("EP#MelCassima",2)~
END
+ ~!Race(Player1,HUMAN)~ + ~I know this one. Cassima... the Bird of Paradise, or the Phoenix. Humans adopted the elven legend of a young maiden named Cassima, who was accused of being an evil witch, and burned at the stake.~ + EP#MelCasPhoenix
+ ~Race(Player1,HUMAN)~ + ~I know this one. Cassima... the Bird of Paradise, or the Phoenix. My people adopted the elven legend of a young maiden named Cassima, who was accused of being an evil witch, and burned at the stake.~ + EP#MelCasPhoenix

IF ~~ EP#MelCasPhoenix
 SAY
 ~Yes. Before she died, Hanali Celanil transformed her into a Phoenix, and Cassima rose up to join the goddess.~
 IF ~~ EXIT
END

// Legendary constellations - The Swordsman
CHAIN
IF ~Global("EP#MelSwordsman","GLOBAL",1)~ EP#MELJ EP#MelSwordsman
~There's another legendary constellation, The Swordsman. There it is!~
DO ~("EP#MelSwordsman",2)~
END
+ ~Race(Player1,ELF) + ~I've learned many myths about the Swordsman. The most popular one is that the Swordsman was Auranamn, the first elf, who fought at Corellon's side during the great battle with Gruumsh. Auranamn died in the battle, so Corellon lifted his soul up and placed it among the stars, to keep eternal watch over our people.~ EXTERN EP#MELJ EP#MelSwordsmanStory
+ ~!Race(Player1,ELF) + ~Your people have many myths about the Swordsman, don't you?~ EXTERN EP#MELJ EP#MelSwordsmanElfMyth

CHAIN
IF ~~ EP#MelSwordsmanElfMyth
SAY
~We sure do. The most popular one is that the Swordsman was Auranamn, the first elf, who fought at Corellon's side during the great battle with Gruumsh. Auranamn died in the battle, so Corellon lifted his soul up and placed it among the stars, to keep eternal watch over our people.~
IF ~~ EXIT
END

CHAIN
IF ~~ EP#MELJ EP#MelSwordsmanStory
~I remember hearing about the Swordsman while I was growing up.~
END
++ ~An interesting story. I know of some others, too, but they can wait for another time. Let's move.~ EXIT

// Color Spray Nebula
CHAIN
IF ~Global("EP#MelColSprNeb",1)~ EP#MELJ EP#MelColSprNeb
~Over there... what looks like a vast color spray spell in the sky...~
DO ~SG("EP#MelColSprNeb",2)~
END
++ ~That's the Color Spray Nebula, slowly streaking across the sky as it follows the Galleon Nebula. Mystra's followers take it as a sign that their use of the Art pleases her.~ EXTERN EP#MELJ EP#MelBane

IF ~~ EP#MELJ EP#MelBane
 ~That's one way of looking at it. The cult of Bane believed that the nebula was their god's wrath, spreading across the heavens. They believed that everything in its destructive path is utterly annihilated.~
END
 ++ ~Let's hope not, Meleryn! It would be a shame to lose any of the night sky's wonders.~ EXIT

// Galleon Nebula
CHAIN
IF ~Global("EP#MelGalNeb",1)~ EP#MELJ EP#MelGalNeb
~I see a great, colorful ship, sailing across the night sky...~
DO ~SG("EP#MelGalNeb",2)~
END
++ ~Ah, yes... the Galleon Nebula, her sails billowing on celestial wind. A mighty vessel indeed!~ EXTERN EP#MELJ EP#MelGalleonVoyage
++ ~That's the Galleon Nebula, the greatest ship never to sail the Realms' seas.~ EXTERN EP#MELJ EP#MelGalleonVoyage

CHAIN
IF ~~ EP#MELJ EP#MelGalleonVoyage
~Beautiful colors, even in this dim starlight. Always on the trail of the Color Spray Nebula, but never catching up to it. A very long, very slow chase.~
END
++ ~Either that, or the Color Spray is trying to reach the Galleon. Only the gods know for sure, if anyone does.~ EXIT

// The Lion/The Wolf/The Dog/The Leopard
CHAIN
IF ~Global("EP#MelConstOfManyNames","GLOBAL",1)~ EP#MELJ EP#MelConstOfManyNames
~Take a look at that group of stars, &--#60;CHARNAME&--#62;. Can you see the animal shape?~
DO ~SG("EP#MelConstOfManyNames",1)~
END
++ ~Yes, I learned about it at Candlekeep. It's known by a different name to almost every culture in Faerun. Some people named it for great feline creatures, others for legendary canines.~ In the Gulthmere, it's known as Nobanion, the Great Lion; in the Shaar, they call it the Leopard.~ EXTERN EP#MELJ EP#MelConstFelineNames

CHAIN
IF ~~ EP#MELJ EP#MelConstCanineNames
~Right. In the North, it's usually called Asglyn the Wolf, the loyal companion of Gwaeron Windstrom. To the Rashemi and Aglarondans, it's the vigilant Narnos the Dog. Further south, in the Old Empires, they call it Ghastis, the savage Jackal.~
= ~Most demi-humans don't really acknowledge the constellation, so they have no names for it.~
END
+ ~Race(Player1,ELF)~ + ~Ah, but we're the exception, aren't we?~ EXTERN EP#MELJ EP#MelConstElael
+ ~!Race(Player1,ELF)~ + ~What about your people, Meleryn?~ EXTERN EP#MELJ EP#MelConstElael

IF ~~ EP#MELJ EP#MelConstElael
 ~Elves are an exception in many things, hehe! To us, part of the Lion is used for Elael, the Songsmith. Do you know the ancient fable about it?~
END
++ ~A bard who crafts a song so pure and sweet that even the gods are humbled.~ EXIT
++ ~If I've heard it before, I don't recall. What's the story?~ EXTERN EP#MELJ EP#MelElaelLegend

IF ~~ EP#MELJ EP#MelElaelLegend
~There once lived a bard who crafted a song so pure and sweet that even the gods were humbled.~
END
++ ~Elael was truly a legendary bard, then!~ EXIT
++ ~Hard to imagine the gods being so moved by one of us. I find that an encouraging thought!~ EXIT

// Ieriyn (The Sailor's Star); Y'landrothiel (The Traveler's Star)
CHAIN
IF ~Global("EP#MelSailorStar","GLOBAL",1)~ EP#MELJ EP#MelSailorStar
~Up over there, far above Faerun's northern pole... the brightest star in the heavens. Elves call it Y'landrothiel, The Traveler's Star, while others call it Ieriyn, the Sailor's Star. It outshines even its sister, Mystra's Star.~
DO ~SG("EP#MelSailorStar",1)~
END
++ ~Right, Meleryn. It's called the Sailor's Star because sailors throughout the ages have used it to help them navigate.~
= ~This star is a real oddity! As the night progresses, Ieriyn doesn't rise or set like other stars, but always hangs at a single point in the sky. At any time of night, you can find Ieriyn, as it's always in the North. If a ship gets lost, sailors can determine their direction by finding Ieriyn.~
= ~The Sailor's Star is sacred to Selunites, and praised by sailors across Faerun.~ EXTERN EP#MELJ EP#MelTravelerNav

IF ~~ EP#MELJ EP#MelTravelerNav
~You know a lot more about the sea than I do. On land, travelers, prospectors, and Shaundakul's worshipers all use The Traveler's Star to navigate as they travel. Humans first learned of the star's navigational uses from the elves of the North.~
END
++ ~And what you might lack in maritime lore, you sure make up for with your knowledge of overland travel. Looks like we balance each other well, Meleryn.~ + EP#MelComp

IF ~~ EP#MelComp
SAY
~I like the sound of that. I'll take it as a compliment!~
IF ~~ EXIT
END

// Chandos (Grumbar)
CHAIN
IF ~Global("EP#MelChandos","GLOBAL",1)~ EP#MELJ EP#MelChandos
~There's an "earthy" star over there. If you look carefully, you can see its brownish color.~
DO ~SG("EP#MelChandos",1)~
END
++ ~It's faint, but I see it. That's Chandos, a star sacred to Grumbar, the Boss of Earth.~ EXTERN EP#MELJ EP#MelIaras

CHAIN
IF ~~ EP#MELJ EP#MelIaras
 ~We elves call Chandos Iaras, and consider it sacred to Labelas Enoreth.~
END
++ ~An eye in the sky, observing the passage of time.~ EXIT

// Coliar (Akadi)
CHAIN
IF ~Global("EP#MelColiar","GLOBAL",1)~ EP#MELJ EP#MelColiar
~That bluish-white star over there...~
DO ~SG("EP#MelColiar",1)~
END
++ ~Coliar. It's sacred to Akadi, goddess of elemental air.~ EXTERN EP#MELJ EP#MelLuridel

CHAIN
IF ~~ EP#MELJ EP#MelLuridel
 ~Really? We elves call it Luridel, and hold it sacred to Erevan Ilesere, god of mischief.~
END
++ ~Ah, the patron of rogues. I can't help but wonder what he's up to.~ EXIT

Link to comment

You have a lot of problems here. In order to fix them, you need to identify them. If you COMPILE this file with WeiDU, you will get error messages that tell you where there's a problem.

 

By doing this and comparing the relevant code against 1) WeiDU's docs or 2) a working mod, you should be able to fix all of your errors in less than half an hour.

 

Some of the problems:

  • There are CHAIN actions here mixed in with a number of states. These things are very different and shouldn't be mixed together. The states should all be part of a single BEGIN EP#MELJ action.
  • In CHAIN IF ~conditions~ THEN filename state, the THEN is mandatory.
  • After PC responses, there needs to be a transNext.
  • Some strings are not closed (missing final ~) or have an extra ~ in the middle.
  • One of the CHAINs has a PC response in the middle followed by more NPC lines. I don't think this is possible.
  • Some of the Global("variable", "GLOBAL", value) checks are missing the "GLOBAL" parameter.
  • The entries got turned into

Link to comment

I mix CHAIN and stats because I like to have the dialogues in chronological order. But after the CHAIN, you have to tell the installer which dlg file the stat chould be added to using APPEND - END. So, my .d files usually look like this:

 

BEGIN mynpcdlg

 

-states-

 

CHAIN

 

APPEND mynpcdlg

 

-more states-

 

END //APPEND

 

To give an example from above that should work regarding the CHAIN - state problem:

 

 

// Sacred Stars - Karpri

CHAIN

IF ~Global("EP#MelKarpri","GLOBAL",1)~ EP#MELJ EP#MelKarpri

~There... that blue-green star...~

DO ~SG("EP#MelKarpri",2)~

END

+ ~!Race(Player1,ELF)~ + ~Yes, that's Karpri, associated with Ishtishia, goddess of elemental water.~ + EP#MelKarpriOchael

+ ~Race(Player1,ELF)~ + ~It's Ochael, sacred to Rillifane Rallathil, The Leaflord.~ + EP#MelOchael

 

APPEND EP#MELJ

IF ~~ EP#MelKarpriOchael

SAY

~We elves call Karpri Ochael, and hold it sacred to Rillifane Rallathil.~

IF ~~ EXIT

END

 

IF ~~ EP#MelOchael

~Our special patron watches over us day and night alike.~

IF ~~ EXIT

END

 

END //APPEND

 

// Legendary constellations - Adarivael; Sacred Stars - Anadia

CHAIN

IF ~Global("EP#MelAdarivaelAnadia","GLOBAL",1)~ EP#MELJ EP#MelAdarivaelAnadia

~Adarivael is another elven constellation. See how it's formed by three lines of stars that come together, each with a star cluster at its outer end? Where those lines come together is due east.~

DO ~SG("EP#MelAdarivaelAnadia",2)~

END

+ ~Race(Player1,HUMAN)~ + ~My people call those stars the Arrows of the Gods, or the Sun's Signpost.~ EXTERN EP#MELJ EP#MelAdarAnadSacredSol

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...