I've been making a HLPM for the last couple of days, really just to familiarize myself with the editor before I get started on a real scenario. Anyway, it's basically done, except for a strange problem. I have 7 shops in the HLPM: Priest Spells, Mage Spells, Alchemy Recipes, Combat Skills, Weapons, Armor, and Misc. items. I've set up the shops for each of them (starting with shop 129 and going down, to avoid any kind of inconvenience for a scenario author), and created the dialogue. Nothing special,they just give one little line when you talk to them, and then you can buy whatever. The problem is, only the priest spells teacher works properly. The other 6 at first said nothing when spoken to, and had only an "OK" option to end the conversation. I then discovered I had accidentally made 2 talk node 11s. So I fixed that, and now they give their first line, but the only option is still "OK", ending the conversation. You can't buy from them, and I can't figure out why the Priest works and they don't.
EDIT: Oh, and every shopkeeper is calling the appropriate node when talked to -- I made them call the same node as their creature number, for simplicity (which is why it starts at 6).
Here's my script:
Code:
begintalkscript;begintalknode 6; state = -1; nextstate = 1; question = "Priest Spell Teacher"; text1 = "_Hello, my child. I am here to teach you certain holy rituals, if you wish to learn them._"; begintalknode 7; state = -1; nextstate = 2; question = "Mage Spell Teacher"; text1 = "_Greetings. I am here to teach you certain powerful magics, if you wish._"; begintalknode 8; state = -1; nextstate = 3; question = "Alchemy Teacher"; text1 = "_Hello there, youngsters. I can teach alchemy recipes._"; begintalknode 9; state = -1; nextstate = 4; question = "Skills Teacher"; text1 = "_Here you can learn special combat skills to help in your journey._";begintalknode 10; state = -1; nextstate = 5; question = "Armor Vendor"; text1 = "_I am an armorsmith. Would you like to browse my wares?_"; begintalknode 11; state = -1; nextstate = 6; question = "Weapons Vendor"; text1 = "_I make weapons. Have a look at my inventory?_"; begintalknode 12; state = -1; nextstate = 7; question = "Item Vendor"; text1 = "_I sell anything that isn't weapons or armor. Have a look?_"; //If you want to change the price adjustment, change the next to last number. The//same applies to all the shops.begintalknode 13; state = 1; nextstate = -1; question = "Learn Priest Spells"; code = begin_shop_mode("Priest Spells","", 125,1,1); text1 = "_Very well. Here are the spells I can teach you._";begintalknode 14; state = 2; nextstate = -1; question = "Learn Mage Spells"; code = begin_shop_mode("Mage Spells","", 126,1,1); text1 = "_Of course. Here are the spells I can teach you._"; begintalknode 15; state = 3; nextstate = -1; question = "Learn Alchemy Recipes"; code = begin_shop_mode("Alchemy Recipes","", 124,1,1); text1 = "_What would you like to learn?_"; begintalknode 16; state = 4; nextstate = -1; question = "Learn Skills"; code = begin_shop_mode("Special Skills","", 123,1,1); text1 = "_These are the skills you can learn."; begintalknode 17; state = 5; nextstate = -1; question = "Purchase Armor"; code = begin_shop_mode("Armor","",128,1,1); text1 = "_Here are the most recent works I've finished._"; begintalknode 18; state = 6; nextstate = -1; question = "Purchase Weapons"; code = begin_shop_mode("Weapons","",129,1,1); text1 = "_Here's what I got for ya._"; begintalknode 19; state = 7; nextstate = -1; question = "Purchase Items"; code = begin_shop_mode("Items",127,1,1); text1 = "_What would you like?_"; break;
It's probably some stupid little thing I'm not seeing.
Also, I have another minor problem. The first time the player moves, the game gives the message
trainer Error: State not found -2 (trainer is the scenario script)
Nowhere do I try to call a state -2. I have "variables;", "LOAD_SCEN_STATE", and "START_SCEN_STATE". Am I missing anything? The game keeps running just fine, but it's a bit annoying and unpolished to have that message there.