# Thralni

Member

3,174

1. ## What is the highest number that can be stored in a SDF?

I reckon this is another easy question to which I once again failed to find the answer in the Docs, but I've been beating my head against the wall for probably two hours now. I went with the assumption that maximum number that can be stored in a SDF would be around 32000, same as the max number that can be used in any script. Yet, I find myself wanting to the store the maximum HP of a creature (1021) in a SDF, and for whatever reason it keeps returning 253 instead. And when I fiddle around with it, it keeps giving different numbers from the actual HP of the creature. So confused. What's going on here? Any help would be appreciated.
2. ## What is the highest number that can be stored in a SDF?

One of your 'crazier moments'? You do all this wizardry with scripted combat, and using two SDFs to store a number was something you did in one of your 'crazier moments'?
3. ## What is the highest number that can be stored in a SDF?

Hi kelandon and Ess-Eschas, thanks once again for your help. This definitely makes sense, as 253 would be 1021 - (3 * 256). Thanks Ess for putting this in context, it helps me understand why things are the way they are. Though it doesn't make me any less annoyed This will be a huge pain, as I'll have to recode some bits scattered all over the scenario... Splitting the number up might work. I have one particular example where that would probably be a viable alternative. Sort of. I would take the number and divide by 100, then store in SDF, and won't allow numbers over 25500 to begin with. Cumbersome, but whatever, I'll spin some story... Though for my specific purpose outlined here (character max health) I was wondering if I could do it as follows, as it might requires less SDFs: health = 1021 // in the actual script I'd just use get_health(ME), but just to stick with he example started in my OP. set_flag(x1,y1,health/256) // stores the number of full 256 blocks required to restore the number. I'm assuming BoA rounds down, based on prior experience. set_flag(x2,y2,health%256) // stores the remainder Recapitulating the number I could then do as follows: health = 256 * get-flag(x1,y1) + get_flag(x2,y2) That said, I haven't tested it yet. Just thinking out loud now... Really though, the best way to go about this is probably to just avoid using large numbers like these...
4. ## Groups

Hey all, Another question. I recently rediscovered the idea of groups. I'd never used them before, because I'd never really need them, I guess, but now I find myself looking for shortcuts, and certain function that may only be reliable if using groups. My question is whether groups can only be created from a script, or whether I can assign creatures to a group also within the editor? It doesn't seem to be the case, but I thought I'd ask. Thanks!
5. ## Groups

my_number(), hm! Good to know. I might follow your example there. Thanks!
6. ## Groups

That's good news, and thank you for the suggestion you mentioned. It definitely sounds more simple than what i'm trying to do, but since it's already there I'll just leave it unless I find it doesn't work as well as I hoped. With regards to creatures only being 'dead' after the scripts stops running, the code that checks the group size is in the town's start state, so I'm assuming that when combat ends, or at a new turn, the code will be executed. Right...? By your words, I presume you can, in fact, use erase_char(ME) inside a script (also outside the DEAD_STATE). But perhaps you have to follow it with end(); in order to stop running the script?
7. ## Groups

A related question to an older topic. I have been fiddling around with groups, hoping to devise a way to quickly check for certain creatures having died so as to display a message upon the death of a group of enemies. And so I used the number of creatures in a group, and when this reaches 0, the message is triggered. And then it struck me that, when creature dies, I'm not even sure that this "deletes" a creature from a group at all... Anybody have any idea? Is it required that i specifically delete them upon death? And can I do this from within the DEAD state in the creature script (is it even possible to use erase_char(ME)?)? Many questions. I hope somebody can help me figure this out. Thanks in advance!
8. ## Let's Play Blades of Avernum!

Man, I never played Canopy to the end, and now I'm kind of glad I didn't. Honestly, this doesn't seem like it would have been the planned ending. It seems as though TM got tired of it and just wrapped it up then and there...
9. ## Another simple question: dialog node limit?

Hello all, I come to you with another rather simple question, but to which I can't seem to find the answer. Is there a limit to the amount of dialog nodes you can have in a dialog script? And if so, what is that limit? Thanks, Thralni
10. ## Another simple question: dialog node limit?

Hm, I hadn't considered that. I'll see if I can use it to my advantage somewhere, somehow. Though I think it should be fine. I realized I left open a bunch of nodes along the script, just in case I need to go back to another character and add something. I could always use those (though having to renumber all the nodes will be a tremendous pain)
11. ## Another simple question: dialog node limit?

Man I read over that chapter at least ten time and I still missed it. Thanks for pointing it out! I have this one town where I'm at dialog node 186, so I'm starting to push it. There also a traveling companion that reserves nodes 190-199... Oh well. I'll make it work. Thanks for reminders too, Dinti!
12. ## Groups

Thanks for the prompt response, Kel!
13. ## About checking the current tick

Hey all, I've been a little confused about the passage of time in BoA. Ina thread in the forum, Ephesos posted the following schedule for the passage of time: 0 - Dawn 250 - Full Light 3750 - Dusk 4000 - Night 4250 - Twilight 4750 - Daybreak But, then the manual says: There are 5000 ticks in a day. The first eighth and last eighth of every 5000 tick period are nighttime. ...which suggested that ticks 625 through 4375 are day, the rest is night, which is different form what Ephesos posted And further: short get_current_tick() - Gets the number of ticks (i.e. turns/combat rounds) that have elapsed since the scenario began. This will be a number from 0 to 29999, and wraps around to 0 when past 29999. So here's my question: how does all this really work, and how can I reliably check for whether it's day or night? I'm attempting for a mission to only start if it's night, but if the amount of ticks can go beyond 5000, and it's unclear when the night starts and ends, I'm a little stuck. Any suggestion would be much appreciated!
14. ## About checking the current tick

Hey all, thanks for the replies! So, "%" is what I needed... I knew from the start there was a simple, one-symbol way of doing this, but I've forgotten so much of my BoA scripting days (and some of the maths involved) that I couldn't for the life of me remember. Nikki, that code looks awesome! I'll repurpose it a little bit for use in my scenario, but otherwise it's perfect. Kelandon, I might just re-test this, as you suggest, to make sure, though it looks like if Nik's code works fine we should have the answer Thanks again all! One more question. I've implemented the code, but was wondering about something. the call "tick_difference" allows to find the difference between two time points, and the manual specifies that there is an order in which you have to supply the call the two time points, namely the earliest first, and then the later one. Does that mean that, if you give, say, tick_difference(3000,1000), it will return 4000? In other words, is it going to wrap around the day? I can test this myself of course, but given my lack of time currently, if anybody has an off-hand answer, that'd be much appreciated!
15. ## Bleh, was going to touch up my half released scenario

I feel your pain I felt much the same when going through WtRM, after seeing Chessrook's vids. Some parts are not just silly, they are outright dumb. I guess this should make you feel good, no? Means you matured That's, at least, how I chose to deal with the swamp that is WtRM... But then I also decided to give it a huge overhaul which is in full swing now. I'll release some more info when doing so becomes relevant. And, perhaps, you wish to do the same to yours?
16. ## Let's Play Blades of Avernum!

All you would really need is time, to be fair. Don't worry, I do not plan to ask you coding questions or the like. Rather, I'd approach you with questions about how you felt about the design of such and such, what was the highlight here, what was your main frustration there... So it'd be really geared towards your experience as a player, rather than the role of a beta tester. And I'll download the version in the database and give it a spin. It appears it has errors in it that the Mac version doesn't have so I need to figure out why that's happening. Kelandon: your comment on the unhandled exceptions is extremely useful, thanks! At least I can have a starting point to figure out why Chessrook bumped into that in WtRM. ALso, sent you a PM.

18. ## Let's Play Blades of Avernum!

Yeah... I indeed didn't imagine somebody would throw out something that would be needed for a special ability. I guess it's a lesson for me: place mortar and pestle in multiple locations. Also, it was interesting to see that normally you look immediately at everything that is given to you, except for the moment that you needed it the most, i.e. the note in the third power source. I assume you used the character editor or something like that to give yourself the mortar and pestle...?
19. ## Let's Play Blades of Avernum!

I have to put one comment out there, because you seem to be repeatedly stung by this in multiple scenarios: if there is a carpet, or stone path or something like that, that stands out from the rest of the floor (purple carpet vs. white marble floor, or stone path vs. drab red/brown floor etc) 99% change that the tiles that stand out will lead you to a door. It's a pretty common design, not just in BoA scenarios, but games in general, that provide a visual cue for the player on where they can or cannot go. Of course it doesn't always work like that, but most of the time it does. I realize this comment is to late for your trek through those power plants, but maybe it'll be useful at some other point in the future.
20. ## Let's Play Blades of Avernum!

The irony here is that I did the same thing. I first checked the walk through and didn't see that quest either. I think what happened is that I included this quest in the v2 overhaul of this scenario and forgot to include it in the walk through, which was already written at the time. I'll change all of this in the v3 overhaul I'm no planning, because the added annoyance is that the liaison quest can't be completed until the end of the scenario. Which is, of course, a little daft. anyway, you can complete the scenario now.
21. ## Let's Play Blades of Avernum!

So I ran through WtRM, and came upon the same issue you describe, where you can't tell Ruth what happened. It appears this is not a bug, just a terrible design decision At the back-end, I found that the empire liaison being kidnapped is apparently more important than telling her you were kidnapped by a mage. And so, when you ask her about the kidnapping, a new cave is explorable. Just west of the crystal mine you came out of after crashing the boat. Go there, find the liaison, go back to Ruth, tell her you found him, and then you can 'report back' about Thralni. *cough* I can see WHY I did this. The idea was that Ruth is so upset that she runs to you with the bad news, and you,a s the player, can only do but calm her down etc etc. Mechanically, however, this makes no sense and is very confusing to the player. I will definitely overhaul this part... As for the problem with the eastern half of the Senarti capital, I'll wait to see the video. I have never seen that one before...
22. ## Let's Play Blades of Avernum!

Nice vid as usual. The mayor not telling you where to go is... Well it appears that Ruth is supposed to tell you where to go, but due to something unforeseen, you don't see the correct text. It should be fixed now, though I'm unsure why this happens. Pretty sure it used to work... Back to the issue you had. So how did you get around the problem, and when you say you can't talk to her, does that mean she doesn't talk at all, or you don't get presented with the right dialog options? So far I can enter the eastern half of the senarti capital just fine, I'm not sure why you can't. So how about I send you that town's script, and you can try getting into that part of town again? That's assuming you have a save game that gets you to some point prior getting into the western half of the senarti capital... Or you can try to move your party there manually, which is what I assume you did in the first place to get around the eastern half of town issue?
23. ## Let's Play Blades of Avernum!

Well that is something I've never heard of before... You can't go into the east half of Voughton? Or is this the Senarti capital you are talking about? What exactly are you trying to do, and what error do you see? You mean a scripting error or does the game actually crash? And when you get the error, are you coming from the outdoor map into the town, or are you in town when the error comes up? Perhaps I can take a look at the vid, actually...? ill look at both Voughton and th senarti capital to see if I can find anything striking... it sounds like this issue could be easily rectified if I can find which is the offending script. Leaving town and re-entering should be enough to reset it and continue without issue. UPDATE: So I didn't find anything particularly strange in either town scripts. So I tried to enter the towns in the game, and found that when I enter the eastern half of the senate capital, there is an error about a special item number being out of range. Is that what you see as well, Chessrook? That said, this doesn't break the game, nor do I end up in the outdoors, nor does the game crash... EDIT: So I've ben tinkering with wtrm, and so far it's all good. I changed a couple of things that didn't make much sense, and clarified some other things to make it easier to understand where the player should go. Additionally, I added some other little things to make things more challenging (the ceremony in Tel Dakrach now requires you to fight demons to prove your worth, for instance). That said, a number of errors you encountered, Chessrook, I'm not seeing (such as the cat that you can ask for food in Voughton), so I'm not sure why you have those issues.
24. ## Let's Play Blades of Avernum!

Dang it. Given the bizar errors you have sometimes encountered, I have feared for a while that perhaps you got your hands on an outdated version, for some of the errors seem so clumsy that they must have been encountered by a tester at some point. Could you tell me at what point the error message shows, and what the error message says? Then I can investigate further. I need to know whether these errors occur in the version I have on my computer, whether these are mac or windows specific, or global. Even though I don't believe many people still play these scenarios, it'd be good to have them working... id be curious to know also how you managed to progress? For all I know that error breaks the whole thing... EDIT: From memory I remembered the error appears after you escape the castle, take the boat in the Senate town, and follow the river. The error itself is in the scenario script itself, and so a quick check showed a semicolon was missing in state 13 in the version I downloaded from the scenario library on this forum. It appears the version in my archive has the same error... I have no idea how this error got in there, as I'm sure it was fixed. I do apologize very much for this. I'm not sure how this error came back, for it was fixed a long time ago. I would send you the corrected script and ask you to reload from an older saved game, but since this error is in the scenario script, I think the whole scenario would have to be reloaded from the start... but maybe somebody can correct me on that? The error was not in any of the START or START_SCEN status, rather a custom state 13. I can't blame you if you just give up on this and move on to something else, do I can probably assure you that, siren you have done all the exploration already, you could just cut to the chase, do the main plot (Senarti fort, Tel Dakrach, Thralni's castle, underground tunnels, Creation halls, fleeing away, get to the boat...) and you should be back where you were in perhaps 1-2 hours of play...
25. ## Let's Play Blades of Avernum!

I promise my quick reply doesn't mean I have nothing to do all day... but sometimes when you do your research in lab, you have a little downtime Well that makes sense. Thanks for sharing, I'll keep that in mind as I watch the following vids. The thing you are alluding to... I'm a little nervous, but I think I know what it is. I remember there being a problem at some point (a point that would indeed be after about 6 episodes from what was posted by you today) where there was an error in the scenario script. It basically killed the whole thing and inhibited any further progress. That said, I also remember fixing it, and this was confirmed by several beta testers... So is this it, or is it something less... problematic?
×