Jump to content


More questions


  • Please log in to reply
51 replies to this topic
BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 13 April 2013 - 11:04 AM #1 More questions

Okay, I'm having some more problems.

1. The 'rakshaha' graphic isn't working properly for some reason. It shows up properly in the editor, but not in the game.

2. One of the towns is comprised almost entirely of lava. However, for some reason, even though all the creatures in the town are 100% immune to fire damage and are set to move freely, no one moves in the town. I can't seem to find anything in the docs about this. What should I do here?

Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 13 April 2013 - 11:24 AM #2 More questions

View PostBainIhrno, on 13 April 2013 - 11:04 AM, said:

1. The 'rakshaha' graphic isn't working properly for some reason. It shows up properly in the editor, but not in the game.
This sounded familiar, so I checked the bugs page and found it there. I imagine that someone has made a scenario with a fixed rakshasa graphic; check other scenarios' custom graphics and you can probably find a replacement.

View PostBainIhrno, on 13 April 2013 - 11:04 AM, said:

2. One of the towns is comprised almost entirely of lava. However, for some reason, even though all the creatures in the town are 100% immune to fire damage and are set to move freely, no one moves in the town. I can't seem to find anything in the docs about this. What should I do here?
I think creatures avoid stepping on damaging spaces (fire, ice, etc.) regardless of their immunities. You could create your own script for movement in the creature script, or you could add pathways of non-lava or non-damaging lava, or you could just live with the fact that they're motionless.

I can't remember exploring this in any detail, so there might be some sort of loophole I'm forgetting.
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 13 April 2013 - 07:14 PM #3 More questions

Your BoA scenario data script may contain glitches? My latest BoA Windows 3D Editor prints out the arrays so this could be checked. For a link to it, see post #2 in the topic "New Windows 3D Editor".  
If you can't run this program on your computer could you post your data script in this topic?
Town 50, The Abyss, has non-damaging terrain in the upper right corner, monsters should be wandering around there quite normally.

Randomizer Randomizer

Tormented Battle Mage

  • Global Moderator
    • Member ID: 4,341
  • 15,886 posts

Posted 14 April 2013 - 11:24 PM #4 More questions

Niemand's Blades of Rogue scenario back in 2007 had a black spot for the Rakshasa graphic during beta testing.  He probably fixed it by now.
"I don't know how we can ever repay you!" - Rescued damsel in distress
"Oh, I'm sure we can think of something .... How much gold do you have?" - "Hero"

"We're all screwed if Cthulhu shows up. Try to enjoy life in the meantime." - Adam Rawnsley

BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 20 April 2013 - 11:22 AM #5 More questions

Okay, I'm trying to revamp some of the creatures to make them harder to kill. For example, I've given the Sliths better armor and want to increase their HP - is it better to give the creatures more Endurance skill or more HP bonus? Also, how do I get creatures to drop gold in different amounts? It seems any creature dropping copper leaves 6 coins, silver leaves 15 coins, and gold leaves 40 coins.

nikki. nikki.

Humany-Wumany

  • Global Moderator
    • Member ID: 2,313
  • 7,445 posts

Posted 20 April 2013 - 01:46 PM #6 More questions

View PostBainIhrno, on 20 April 2013 - 11:22 AM, said:

Also, how do I get creatures to drop gold in different amounts? It seems any creature dropping copper leaves 6 coins, silver leaves 15 coins, and gold leaves 40 coins.

That's because the coins have a set value of those amounts. Use reward_give() or something similar in the death_state of enemy creatures if you want more random/varied drops.

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 20 April 2013 - 04:58 PM #7 More questions

If you want to make them tougher in offense as well as defense, just increase the creature level.
If you only want to increase the creature's ability to withstand damage, the formula for hp is the same as for a PC:
Health (Base: 7 + END + (END * Level / 2))
Using hp bonus enables you to specify exactly what the bonus is.

When a dead creature drops money, the money is an "item", there are only three money items: numbers 1,2 and 3.
You can also just leave the money in a nearby container.

BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 05 May 2013 - 03:09 PM #8 More questions

I'm on another round of testing -- at one point in the scenario, there is an entity who you feed garbage to, funny as that may sound. However, the dialog choice that allows you to feed the garbage when talking to the creature appears only once, and to reset it, you have to end the dialog. How can I make a dialog that allows for repeat selection of the same talking node?

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 05 May 2013 - 07:04 PM #9 More questions

Assuming that Condition = 1, it is a matter of being able to get back to it...
Really need to see the dialog script concerned. But it should be a matter of state numbers.

nikki. nikki.

Humany-Wumany

  • Global Moderator
    • Member ID: 2,313
  • 7,445 posts

Posted 06 May 2013 - 01:00 AM #10 More questions

yeah, did you try setting nextstate to equal the same state as the node you want repeating?

Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 06 May 2013 - 05:16 AM #11 More questions

You probably need to set nextstate equal to -1 at some final talking node but not end the conversation. Dialogue options normally (there are ways of circumventing this) don't come back until you refresh the conversation, and that can happen by ending the conversation or by reaching an end (a nextstate of -1) and saying, "I have another question."
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 31 May 2013 - 06:07 PM #12 More questions

Okay, I'm having trouble with another town script. This is not in the original BoE scenario, so this was written by hand. However, something doesn't seem to be working.

Spoiler

Spoiler


Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 31 May 2013 - 08:11 PM #13 More questions

Have you checked the value of the flag at that point? Is flag (16,7) actually equal to 1 when you want it to be? I don't see anything obviously problematic otherwise, if you're not getting some kind of error messages.
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 31 May 2013 - 10:03 PM #14 More questions

Firstly, use Alint to check for errors. You can use its batch form to check all scripts at once:
alint -v -w *.txt
Secondly, in state 71, include a call that prints out the current value of each of the the relevant SDFs. This may trace the error.

If all else fails, upload the scenario and scripts, I can give it my butcher's look.

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 31 May 2013 - 11:38 PM #15 More questions

This is a schematic of state 71:
beginstate 71;
if ((has_item_of_class(10,0) < 1) && (get_flag(16,4) >= 1) && (get_flag(16,7) < 2) && (get_flag(16,5) < 1)) { // A

if (get_flag(16,7) < 1) { // B
message_dialog("_Hey! You're just going to use my knowledge and leave me? I'll kill you!_ Barry exclaims, taking a huge bite out of your arm.","");

} // B
} // A

else if (get_flag(16,7) == 1) { // C
message_dialog("Barry shoots fiery energy from his eyes, preventing you from proceeding.","");

} // C

else
set_state_continue(45);
break;

Edit:
I created a placed special in town 0, Northern Outpost. The code for the special is as below:
block_entry(1);
put_boom_on_space(9,11,1,0);
run_animation_sound(51);
damage_near_loc(9,11,50,1,1);
message_dialog("Barry shoots fiery energy from his eyes, preventing you from proceeding.","");

Everything worked as it should.

BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 02 June 2013 - 10:56 AM #16 More questions

Thanks, I had to tweak with some things to get it to work. New problem: The "spawn creature" call doesn't seem to work - the idea is that there is a creature that is supposed to come back to life if you kill it before a certain SDF is set, but I can't get that to work. Also, can an SFX boom not be called among the death of a creature? I tried putting a fire boom on the space that a creature is killed on, but it doesn't seem to display. (I've killed the creature via debug mode if that matters.)

Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 02 June 2013 - 12:59 PM #17 More questions

I don't know why spawn_creature() would give you problems. I think I used it at some point during Bahs/Exodus and didn't encounter any obvious weirdness, so I'd have to see the script.

On the SFX boom: are you trying to kill a creature and then call a boom after that creature's death at the same spot where the creature died? And are you trying to do it with put_boom_on_char()? If so, I'd recommend putting something into the DEAD_STATE of the character that saves the character's location into two SDFs and then use those SDFs with put_boom_on_space() instead. Putting a boom on a creature who's now dead sounds like a recipe for an Unhandled Exception or some other kind of game-killing error.
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 02 June 2013 - 02:27 PM #18 More questions

I modified the script to do what you suggested, and that seems to work. However, the creature still doesn't spawn. Here's my current script (this is in the town code, state 56 is called when the creature is killed before the SDF is set.)

Spoiler

EDIT: I believe I figured out a way to make it work, by using "place_monster" and "set_creature_memory_cell" to the appropriate town nodes, it seems to be working the way it should.

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 03 June 2013 - 04:56 AM #19 More questions

Blades of Exile features the Identify spell which enables a party to identify its items anywhere and anytime, without need for a human sage. Blades of Avernum has no such spell, this could be inconvenient in the middle of a dungeon. So I improvised a work-around, see my post in the Codex part of The Lyceum
http://thelyceum.yuk.../Identify-Spell

Word of Recall won't be such a big issue, it also requires vacant town entrances, which are in short supply.

Set name calls for the town scripts, I was able to generate these automatically.
You can then copy and paste them into your own scripts:
set_name(6,"Soldier");
set_name(7,"Roland");
&&&&&&&&

Edited by Ishad Nha, 13 October 2016 - 10:38 PM.


Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 03 June 2013 - 05:06 PM #20 More questions

View PostBainIhrno, on 02 June 2013 - 02:27 PM, said:

EDIT: I believe I figured out a way to make it work, by using "place_monster" and "set_creature_memory_cell" to the appropriate town nodes, it seems to be working the way it should.
I almost never used spawn_creature, but I worked a lot with "place_monster" and dealt with its big downside, which is that you don't know for sure what the creature's number is going to be. If there are no summons, then place_monster starts with creature number 86 and counts up. If you have summons in the town, though, it starts with whatever the next number is after the highest-numbered summon, unless you've filled up all available summon slots, in which case I'm not completely sure what it does (grab an empty space from a dead summon, I think?). The issue here is that set_creature_memory_cell may not work if you don't get the right creature number.

As an alternative, I suggest using a hidden group.
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

tridash tridash

Calculated.

  • Member
    • Member ID: 2,261
  • 299 posts
  • Locationuk

Posted 04 June 2013 - 12:49 PM #21 More questions

To work around that downside of place_monster, you can always add something in your creature script init states to set some sdf to my_number().

BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 04 June 2013 - 03:41 PM #22 More questions

That's sorta what I did, I defaulted the creature "Phoenix" to have the "phoenix" script, and set the values directly through there, and it seems to be working.

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 04 June 2013 - 06:31 PM #23 More questions

If BoE towns can access out of town dialog and BoA towns can't, this can create game-breaking problems with lack of dialog for key (BoA) NPCs.
Creatures using dialog from other towns, they seem to be quite common. I altered my copy of the source code for the 3D Editor so the town scripts showed when out-of-town dialog was used.
In some cases it is just a case of several versions of the same town existing...

Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 04 June 2013 - 08:49 PM #24 More questions

Ishad Nha, are you posting in the right thread? Several of your responses seem really off-topic.

Hmm, that workaround for place_monster is not one that I've ever tried. Seems like it would work. Hidden groups are still easier to do more complicated things with (manipulate attitudes, give non-default scripts, etc.), but it doesn't sound as though you need to do any of that here.
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 05 June 2013 - 12:10 AM #25 More questions

I am generally discussing porting from BoE to BoA.
This may be useful for Bain-Ihrno to know: BoE towns can access out of town dialog and BoA towns can't, this can create game-breaking problems with lack of dialog for key (BoA) NPCs...
I am currently drawing up a function to create a printout for this. It seems like various NPCs, in a given town, draw their dialog from various other towns. So it is not as simple as importing another town's dialog script.
This is from the relevant source code,
void port_town_dialogue_script(char *script_name,char *directory_id,short which_town)

// first, we have dialogue at all?
Boolean have_dialogue = FALSE;
for (short i = 0; i < 10; i++)
if (same_string(boe_scen_text.talk_strs[i],"Unused") == FALSE)
have_dialogue = TRUE;
if (have_dialogue == FALSE)
return;

Meaning if NPCs have dialog from other towns but there are no native Personalities in the current town, there won't even be a dialog script.
I drew up a function for the BoE Editor, this is the code:
Spoiler

Town Name is only valid for one scenario, Of Good and Evil, currently the list of names has to be listed in the source file TFILEIO.H, then the list is compiled into the BoE Scenario Editor.
Of Good and Evil list is found stuffed in this download:
http://www.freewebs....BasDecrypts.zip

Edited by Ishad Nha, 05 June 2013 - 08:14 AM.


Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 06 June 2013 - 05:25 PM #26 More questions

A second big problem is that BoE dialog simply has Personality whereas BoA dialog has layered States... You can't just copy and paste someone's dialog from another town's dialog script because the states of that dialog may conflict with the dialog states in the current town's dialog script.

Town Personality Dialog Counts,  copy this and paste into a spreadsheet:
Spoiler


BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 09 June 2013 - 12:37 PM #27 More questions

Playtested both halves of the scenario now, I'm just making some final touches to the scenario. I'm trying to put a dialog box in that mentions a PC by name, and have tried following scripts from other scenarios.

For example:

Spoiler


Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 09 June 2013 - 03:11 PM #28 More questions

You need a couple more calls, notably get_buffer_text(). Look at any string manipulation in any released scenario and notice the last two steps (getting the text and adding it to the dialog). I'll edit in an example when I'm back at my computer.
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 09 June 2013 - 05:34 PM #29 More questions

Check this out, it is from the end of the Part 2 documentation, have you read it recently?
String Manipulation Calls
These calls are designed to give the scenario designer a lot more control over the text displayed to the player. They’re a little complicated, but much more powerful.........
You should not need a SDF, Character number should suffice.

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 09 June 2013 - 06:11 PM #30 More questions

I just tested this in town 0 and it worked. I added a second paragraph because the sum total of the strings was well over 256 characters.
beginstate 26; // For testing only
reset_dialog();
clear_buffer();
append_string("Ambush! You are attacked by a large batallion of Sliths. One of their captains says, _It'sss ");
append_char_name(1);
append_string(", the traitor! All disssloyal Sssliths mussst be executed at onccce!_");
get_buffer_text(dlgstr);
add_dialog_str(0,dlgstr,0);
add_dialog_str(1,"Obviously, the Slithzerikai do not take kindly to one of their own fighting for the Vale. It may take longer than you expected to reach Genmar.",0);
choice = run_dialog(1);
  break;

Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 10 June 2013 - 07:01 AM #31 More questions

View PostIshad Nha, on 09 June 2013 - 05:34 PM, said:

You should not need a SDF, Character number should suffice.
I think the point is that the character number is stored in that SDF.

View PostIshad Nha, on 09 June 2013 - 06:11 PM, said:

get_buffer_text(dlgstr);
add_dialog_str(0,dlgstr,0);
These were the two calls I was referring to in my post, so I won't bother finding another example.

View PostIshad Nha, on 09 June 2013 - 06:11 PM, said:

I just tested this in town 0 and it worked. I added a second paragraph because the sum total of the strings was well over 256 characters.
This is often an issue with party member names, because you don't know how many characters are in the name, and the string is disjointed so you have to add up the components. Word of warning to anyone using string manipulation, I guess.
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 10 June 2013 - 03:10 PM #32 More questions

Out of curiosity, would creatures move on lava if I created a script that repeatedly gave them the status "hovering feet"?

Kelandon Kelandon

!!!

  • Global Moderator
    • Member ID: 2,682
  • 9,786 posts

Posted 10 June 2013 - 04:54 PM #33 More questions

View PostBainIhrno, on 10 June 2013 - 03:10 PM, said:

Out of curiosity, would creatures move on lava if I created a script that repeatedly gave them the status "hovering feet"?
You'd have to try it to know for sure, but I don't think so.
VCH: I believe we settled this way back when: Kelandon was the most attractive.
SoT: You'd be happy, too, if you were such a clever spider.
Ephesos: In conclusion, yarr.

Kelandon's Pink and Pretty Page!!

Ishad Nha Ishad Nha

Hand of Avadon

  • Member
    • Member ID: 4,773
  • 2,366 posts

Posted 11 June 2013 - 07:10 AM #34 More questions

It depends whether the game engine checks for status 27 or not. If it only checks the nature of the nearby floor/terrain, the answer would be no.
I tried an experiment in a monster-free version of town 50. An NPC High Priest had Hovering Feet but did not move over lava no matter what I tried.

BainIhrno BainIhrno

Hand of Avadon

  • Moderator
    • Member ID: 3,311
  • 1,312 posts

Posted 12 June 2013 - 01:30 AM #35 More questions

Well, thanks for trying. Looks like I'm going to have to rework this dungeon.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users