Jump to content

Code Discussion Thread


Celtic Minstrel

Recommended Posts

On my current copy of the code, they are Boolean instead of bool (that's what they originally were). This will be a necessary change in order for the code to work on PowerMacs – if I'm not mistaken, bool is a different size on PowerPC than on Intel (2 or 4 bytes instead of 1).

 

 

On a different subject, I'm working on the new dialog engine, and have come up against text edit fields. Presumably I would need to create a control that then handles most of the work for me? I want to be able to call events when a field gains or loses focus, and I want that to be able to prevent the field from gaining or losing focus. Is that possible with the standard text edit controls? Also, would the presence of a text edit control swallow all keystrokes, or only those that can be interpreted as typing, erasing, or moving the cursor?

Link to comment
Share on other sites

  • Replies 990
  • Created
  • Last Reply

Top Posters In This Topic

Are you certain that the bool type will change size? Are you certain that the 'Boolean' type will not? I'm not sure I've seen documentation to support or refute either of these claims.

 

Quote:
I want to be able to call events when a field gains or loses focus, and I want that to be able to prevent the field from gaining or losing focus.

Why? this is highly atypical. I don't know whether this can be done, in part because it is normally something which would be useless or frowned upon (mainly preventing the user from changing the focus to another control). The answer to your last question would depend on exactly how such a thing was implemented, I think.

Link to comment
Share on other sites

Originally Posted By: Niemand
Are you certain that the bool type will change size? Are you certain that the 'Boolean' type will not? I'm not sure I've seen documentation to support or refute either of these claims.
Boolean is a typedef of unsigned char, so it should always have a size of one byte. The bool type I'm not sure of; I thought I saw somewhere that it's larger on a PowerPC. But I could be wrong on that.

Originally Posted By: Niemand
Quote:
I want to be able to call events when a field gains or loses focus, and I want that to be able to prevent the field from gaining or losing focus.

Why? this is highly atypical. I don't know whether this can be done, in part because it is normally something which would be useless or frowned upon (mainly preventing the user from changing the focus to another control). The answer to your last question would depend on exactly how such a thing was implemented, I think.
Atypical? It seems fairly common for applications to verify the contents of a field as it is losing focus, in my experience. And usually this results in the contents of the offending field being selected, hence preventing a change of focus, though I guess that's not strictly necessary. An event upon losing focus would also allow other controls that depend on the value of the field to be updated – for example, you type a pict number into the pict field and the correct picture is displayed as soon as the field loses focus.

An event upon gaining focus probably wouldn't be very useful though.

The important part is having an event handler called; I can live with it not being able to prevent a focus change.
Link to comment
Share on other sites

Ok, I've finished completing the last feature that Ishad Nha added to the scenario editor (i.e the dump of all shop related things to a text file).

If i found no critical bug upon testing, i'll upload the code tomorrow ...

 

By the way, i've found that in several scenarios talking nodes were used for personalities outside of the town range (e.g talking nodes for personality 20 when editing town 3).

The problem is that the editor refuses to save the changes when the personality is out of range (thus you can't change those already existing nodes) ...

That leads to two questions : how could designers bypass the error message and should we remove it ?

 

Chokboyz

 

Edit: i'm a little confused on how portals work : with the generic portal node the chain of event will continue whenever you choose to enter the portal or back away, but with the portal node choosing leave will break the chain of event ... Is that normal or should it be fixed ? (and, should we fix it, what behavior is the right one ?)

Idem with Stairway/Generic Stairway.

Link to comment
Share on other sites

Originally Posted By: Chokboyz
By the way, i've found that in several scenarios talking nodes were used for personalities outside of the town range (e.g talking nodes for personality 20 when editing town 3).
The problem is that the editor refuses to save the changes when the personality is out of range (thus you can't change those already existing nodes) ...
That leads to two questions : how could designers bypass the error message and should we remove it ?
Sorry, I'm not quite clear what you mean here. Do you mean that the personality assigned to a creature can be from a town other than the current town? This is correct. Or do you mean that a node in town x can claim to belong to a personality in town y, x != y? This is also correct, I think. I say leave it. We can deal with it when we rehaul the talking structure.

Originally Posted By: Chokboyz
i'm a little confused on how portals work : with the generic portal node the chain of event will continue whenever you choose to enter the portal or back away, but with the portal node choosing leave will break the chain of event ... Is that normal or should it be fixed ? (and, should we fix it, what behavior is the right one ?)
Idem with Stairway/Generic Stairway.
If you click the "Leave" button, you should not be teleported. You're saying the Generic two call the JumpTo special if you choose the Leave button? What do they call if you choose the Enter/Ascend/Descend button? If they terminate in that case, then the behaviour is probably correct. If not... I have no clue. As long as the party is not moved when the press the Leave button, I think it's best to leave it for now. Perhaps we can change that when we rehaul the special nodes, but at present changing it would likely cause compatibility problems.
Link to comment
Share on other sites

Originally Posted By: Chokboyz
By the way, i've found that in several scenarios talking nodes were used for personalities outside of the town range (e.g talking nodes for personality 20 when editing town 3).
The problem is that the editor refuses to save the changes when the personality is out of range (thus you can't change those already existing nodes) ...
That leads to two questions : how could designers bypass the error message and should we remove it ?


Designers didn't bypass the error message: they simply edited the personality from the town which it belonged to. As far as I know, this feature currently works as intended and documented. I guess there isn't really any good reason to prevent designers from editing personalities belonging to one town while in another, though, assuming it can be done.

Quote:
Edit: i'm a little confused on how portals work : with the generic portal node the chain of event will continue whenever you choose to enter the portal or back away,


This is a known bug, and I'm pretty sure no designer has relied on the buggy behaviour.
Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
If you click the "Leave" button, you should not be teleported. You're saying the Generic two call the JumpTo special if you choose the Leave button?


Yes.

Quote:
What do they call if you choose the Enter/Ascend/Descend button?


Same thing.

Quote:
If they terminate in that case, then the behaviour is probably correct.


They don't. It's not. The correct behaviour is almost certainly for the Jump To special not to be called if the player chooses Leave; I'm pretty sure that's what the documentation says should happen. Again, this is a well-known bug that's appeared on several Things That Don't Work lists. I doubt there's a compatibility issue, but I guess you can include an option just in case some designer somewhere took advantage of the current behaviour.
Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
You're saying the Generic two call the JumpTo special if you choose the Leave button? What do they call if you choose the Enter/Ascend/Descend button?

Yes. The same node as Leave.

Originally Posted By: Thuryl
This is a known bug, and I'm pretty sure no designer has relied on the buggy behaviour.

Suspected as much, so i'll fix it (i'll also fix the fact that if the m1 or/and m2 field is set to something other than -1, a message would be displayed despite being labeled as unused).

Originally Posted By: Thuryl
Jump To special not to be called if the player chooses Leave; I'm pretty sure that's what the documentation says should happen.

The documentation says exactly the opposite (the JumpTo is called if Leave is pressed and the event ends if the party teleport). rolleyes
I've assumed the right behavior was the portal one and that documentation was wrong.

Originally Posted By: Celtic Minstrel
Or do you mean that a node in town x can claim to belong to a personality in town y, x != y?

Yup, that's it. I understand that it expands the talk tree (by giving more node) and have no intention of "fixing" that.

Originally Posted By: Thuryl
Designers didn't bypass the error message: they simply edited the personality from the town which it belonged to. As far as I know, this feature currently works as intended and documented. I guess there isn't really any good reason to prevent designers from editing personalities belonging to one town while in another, though, assuming it can be done.

I agree with that; i was just wondering how someone could edit a talking node and give it to a personality of another town (that prompt an error message when i do). confused

Hope it's clearer,
Chokboyz

Link to comment
Share on other sites

Originally Posted By: Thuryl
They don't. It's not. The correct behaviour is almost certainly for the Jump To special not to be called if the player chooses Leave; I'm pretty sure that's what the documentation says should happen. Again, this is a well-known bug that's appeared on several Things That Don't Work lists. I doubt there's a compatibility issue, but I guess you can include an option just in case some designer somewhere took advantage of the current behaviour.
Okay. I think it'd be useful when rearranging the special nodes to allow the designer to separately choose a node to be called if Leave is picked and a node to be called if the other option is picked.
Link to comment
Share on other sites

Oh, Chokboyz, you may want to implement this bugfix. The implementation should be quite easy; you'll have a few more cases since you haven't yet incorporated my terrain rehaul, but it'll still be very easy.

 

And just in case it was missed...

Originally Posted By: Celtic Minstrel

Originally Posted By: Niemand
Quote:
I want to be able to call events when a field gains or loses focus, and I want that to be able to prevent the field from gaining or losing focus.

Why? this is highly atypical. I don't know whether this can be done, in part because it is normally something which would be useless or frowned upon (mainly preventing the user from changing the focus to another control). The answer to your last question would depend on exactly how such a thing was implemented, I think.

Atypical? It seems fairly common for applications to verify the contents of a field as it is losing focus, in my experience. And usually this results in the contents of the offending field being selected, hence preventing a change of focus, though I guess that's not strictly necessary. An event upon losing focus would also allow other controls that depend on the value of the field to be updated – for example, you type a pict number into the pict field and the correct picture is displayed as soon as the field loses focus.

 

An event upon gaining focus probably wouldn't be very useful though.

 

The important part is having an event handler called; I can live with it not being able to prevent a focus change.

Link to comment
Share on other sites

Ok, i've fixed Generic Portal and Generic Stairway nodes so that choosing leave will not call the next node in the chain ... I've also fixed the fact that the game was displaying a message if the (labeled unused) messages fields were not set to -1.

I've also added a description of a non-documented feature for Generic Portal/Portal which is : if extra2a is set to 0 just move the party and don't play SFX, if not play SFX.

Finally, i've added a better description of the extra2b field for Generic Stairway to display the fact that there are 8 differents messages to choose from ( 0 - stairs up, 1 - stairs down, 2 - path slopes up, 3 - path slopes down, 4 - slimy stairway up, 5 - slimy stairway down, 6 - dark passage up, 7 - dark passage down.). I've also made a check that would prevent the game from locking if the extra2b value was more or equal to 8.

 

Originally Posted By: Celtic Minstrel
I think it'd be useful when rearranging the special nodes to allow the designer to separately choose a node to be called if Leave is picked and a node to be called if the other option is picked.

I was thinking the same; it would definitely give more flexibility to the designer ...

 

Originally Posted By: Celtic Minstrel
Oh, Chokboyz, you may want to implement this bugfix. The implementation should be quite easy; you'll have a few more cases since you haven't yet incorporated my terrain rehaul, but it'll still be very easy.

Hum, isn't the party supposed to take damage/status affliction when moving over those terrains (even if in boat) ? The non-damaging lava is there for lava you're supposed to move over and the same can easily be done with swamps/diseased lands ...

If i appears the party is indeed supposed to move unharmed over lava/afflicting terrains, then applying your fix would be indeed quite easy smile

Nonetheless, I'll correct the fact that the game thinks you're moving to a bridge square if moving over lava (it thus displays a "Land or under" dialog).

 

Chokboyz

Link to comment
Share on other sites

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
Oh, Chokboyz, you may want to implement this bugfix. The implementation should be quite easy; you'll have a few more cases since you haven't yet incorporated my terrain rehaul, but it'll still be very easy.

Hum, isn't the party supposed to take damage/status affliction when moving over those terrains (even if in boat) ? The non-damaging lava is there for lava you're supposed to move over and the same can easily be done with swamps/diseased lands ...
If i appears the party is indeed supposed to move unharmed over lava/afflicting terrains, then applying your fix would be indeed quite easy smile
If the party takes damage from lava when in a boat, it defeats the point of giving them a boat to cross the lava. If you used non-damaging lava, they wouldn't need a boat; if you used damaging lava, the boat is useless because you take damage anyway. This has been fixed in the Mac version, so it should also be fixed in the Windows version.

And Thuryl also said that there are a few scenarios that rely on the correct behaviour, and don't work as expected due to the bug.

Originally Posted By: Chokboyz
Nonetheless, I'll correct the fact that the game thinks you're moving to a bridge square if moving over lava (it thus displays a "Land or under" dialog).
I've done this, but I think it'd be better for you to wait until incorporating my terrain changes, because once you do that you'll have to change it anyway. I've added a terrain special ability to specify that a space is a bridge.


Will you have both the game and the scenario editor in the repository soon?
Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
If the party takes damage from lava when in a boat, it defeats the point of giving them a boat to cross the lava. If you used non-damaging lava, they wouldn't need a boat; if you used damaging lava, the boat is useless because you take damage anyway. This has been fixed in the Mac version, so it should also be fixed in the Windows version.

And Thuryl also said that there are a few scenarios that rely on the correct behaviour, and don't work as expected due to the bug.

Ok, so i'll implemented it ...

Originally Posted By: Celtic Minstrel
Will you have both the game and the scenario editor in the repository soon?

Yup, tomorrow in the worst case ...

Chokboyz

Edit: it's done. Surprisingly, poisoned and diseased land were already not doing damages when in a boat ...
Link to comment
Share on other sites

Here is the repository : http://code.google.com/p/openexile/ .

 

If you're always on Windows (like here http://www.ironycentral.com/forum/ubbthreads.php?ubb=showflat&Number=167074#Post167074), you won't find an executable for the moment; but you should in an hour or so (i'm actually testing/packaging/... the game and the scenario editor).

 

Chokboyz

Link to comment
Share on other sites

Originally Posted By: Chokboyz
Edit: it's done. Surprisingly, poisoned and diseased land were already not doing damages when in a boat ...
That is surprising, since I don't think the Exile trilogy ever had swamp that you could boat over.

You should get the code in the repository before uploading the executable. Don't include the executable in the repository.

Originally Posted By: Miramor
Pardon me, but where's the repository? I'd like to try out this new version. smile
Note that there is no Mac version out yet. It'll be awhile, I think.
Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
You should get the code in the repository before uploading the executable.

That's done.
Originally Posted By: Celtic Minstrel
Don't include the executable in the repository.

Of course not smile

So here we go, i've uploaded the first beta of Classic Blades of Exile (Win32 only ...) at the Downloads section of the repository (http://code.google.com/p/openexile/).
Some new preferences have been added and the new Compatibility Options menu could be worth looking at ...

The package also includes the updated Character Editor and an updated Scenario Editor.
A (maybe partial) changelog can be found in the archive.

Report any bug found here (except about grass trims : it's nothing more than a test as we're intending to redo completely the frills drawing procedure). Tested and working on Vista.

Have fun,
Chokboyz
Link to comment
Share on other sites

Just a reminder: now that everything's in the repository, the best place to submit bug reports is here. smile

 

 

I have almost completed the new dialog engine, where "completed" means that it's almost ready for testing. For some reason many of the link errors related to ticpp; maybe I forgot to include one of its files.

 

Speaking of ticpp, should I include it in the repository?

 

I'd still also like an answer on the focus event thing for text edit fields. Probably the next significant thing I'll be doing it figuring out how to create text edit fields.

Link to comment
Share on other sites

Quote:
Speaking of ticpp, should I include it in the repository?

Since their code is in an SVN repository, you could put it in via svn externals. However, it wouldn't really a problem to just drop the code straight into the repository, it's pretty small and easily distinguished from the rest. You may need to look at the licensing and see that it is properly followed, by doing such things as indicating whose code it is and where it came from.
Link to comment
Share on other sites

Originally Posted By: Miramor
Huh... Anyone know what causes the "Unfortunately you die!" special node to be wrongly triggered in Bandits 2?


What were you doing when it happened? If it's the one I'm thinking of, that's supposed to go off when you kill important NPCs that you're not supposed to kill.
Link to comment
Share on other sites

Originally Posted By: Niemand
Quote:
Speaking of ticpp, should I include it in the repository?

Since their code is in an SVN repository, you could put it in via svn externals.
...Right. Well, I had no idea what that was, so I looked it up. I've set "svn:externals" on the "dialogxml" folder to "TinyXML++ -r105 http://ticpp.googlecode.com/svn/trunk/"... the only thing I'm worried about is whether the + signs would be problematic?
Link to comment
Share on other sites

Originally Posted By: Ishad Nha
When you choose the Scenario Shopping function, there is one slight glitch. If the town loaded has no shops, a town that does have shops will be loaded, but the town name displayed will remain the same.

Fixed, the town (and outdoor section) won't change anymore.
It was little trickier than loading a town with shop : the last town (the same with outdoor sections) edited before saving the file would be loaded ... seems like last_town_edited and scenario.last_out_edited were not what they appears to be (present in original code) wink
The data and text dumps were also affected.

Originally Posted By: Miramor
Huh... Anyone know what causes the "Unfortunately you die!" special node to be wrongly triggered in Bandits 2? If anyone can tell me what is going on there, that will be my first bug report...

It went off when the Ultimate Weapon's first form died - when Katothen opened up a way out of Deacon's lair and the invulnerable blue second form appeared. One of my PCs was wearing Lenin's pendant, so I'm pretty sure this wasn't supposed to happen.

I'm not familiar with this scenario (i.e never played). Can you give me the name (or directly the number) of the town where the encounter takes place ? If you feel we need to know some specials instructions about the encounter don't hesitate to tell them ...

Chokboyz
Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
...Wait, what's this "Scenario Shopping" function?
Originally Posted By: Chokboyz
Ok, I've finished completing the last feature that Ishad Nha added to the scenario editor (i.e the dump of all shop related things to a text file).

It's basically a big dump in a text file of everything shopping related in the scenario, be it outdoor (Number of node, Name of Store, Store type, Number of first item in store , full name of item, Number of items in store, Cost adjust) or in town ( Number of talking node, Store type, Name of Store, Cost adjust, Shop-specific fields).
The feature was being implemented by Ishad Nha; i've just finished the work before uploading the case/releasing the executable.

Originally Posted By: Celtic Minstrel
P.S. I featured your download – it may be only a beta, but my impression is that it's a fairly stable one. When you upload a new version, be sure to deprecate/un-feature the old one.

Yup, it's quite stable/bugfree but still needs serious betatesting, hence the beta version wink
I'll try to make sure the feature version is always up-to-date.

Chokboyz
Link to comment
Share on other sites

Okay, I'm confused about how to fix a link error involving a vtable...

 

Apart from that, the new dialog engine is essentially complete, and has been added to the repository. It's set to compile into the scenario editor only at the moment, because I'll be testing it first with the edit terrain dialog once I fix this link error and make a few other changes (eg replacing the static init functions with a static instance of an initializer class).

Link to comment
Share on other sites

As a vtable is part of the runtime code of a class definition, the main thing I would recommend is taking a close look at how you're compiling the class whose vtable has issues. Is the class definition being missed during compilation or something? Can you describe more about the error and the class that it relates to?

 

EDIT: I have succeeded in determining that the current oldstructs.h does not produce objects which are binary compatible with when -fpack-struct=2 was used. However, I have no particular evidence that that version was an exactly correct match to the game's original binary layouts. Does anyone have a good way to test or prove this? For the moment I will work under the assumption that that was the case and try to develop a version which duplicates it but without the global compiler flag.

Link to comment
Share on other sites

Well, I was able to load savegames created by the Carbon BoE, which apparently was compatible with the original BoE's savegames (it claimed it was somewhere, I think). I'm not sure if that's proof or not though.

 

 

As for the vtable error... apparently I forgot to define most of the functions in the class (some of which are virtual) without getting a compile error. Hopefully the error will be gone once they're implemented. If not, I'll get back to you.

Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
Well, I was able to load savegames created by the Carbon BoE, which apparently was compatible with the original BoE's savegames (it claimed it was somewhere, I think). I'm not sure if that's proof or not though.
If you want to make sure, there's a legacy Mac savefile in the Quintessence scenario package (it is actually in a pseudo "test.exs" scenario and in a town, but you can always test the mainscreen loading).

I've uploaded an updated copy of the code in the repository, fixing the boat problem (entering a square with a boat did damage you) and the giant strength/skill ability.

Chokboyz
Link to comment
Share on other sites

Okay, thanks. I'll remember that.

 

I have finished the preliminary version of the new dialog engine. It compiles and links into the scenario editor without error, but is not yet used by the code. (I still don't understand why I got a link error for the vtable rather than the individual missing functions.)

 

If anyone cares to look over it and make sure there are no glaring problems with it, that'd be great, but I can live without it. I know there's still one thing I should change in pict.cpp, which is to use the already existing isSheetSet function before trying to draw from a GWorld.

Link to comment
Share on other sites

In get_monst_sound(), there's a check for "strength > 9" which I suspect may always be true. In this function, strength is the attack value of the monster obtained from the a[3] array in the monster record. Therefore, it consists of the number of dice, multiplied by 100, plus the number of sides per die. As such, it's always greater than 100 (unless 0 dice are specified, in which case there's no attack at all).

 

Does this make sense, or am I missing something? If strength is > 9 for a human monster, sound 3 is returned; otherwise sound 2 is returned. This in itself makes little sense, since sound 3 is "poison cough". (Sound 2 is "swish short" which may be the sound indicating a miss.)

 

My guess is that the intent was to play a "punch" sound when the monster does less than 10 damage per hit, and a "sword" sound otherwise... though I was unable to find a "punch" sound available. So, basically, I'm quite confused about this.

 

EDIT: But wait, what's this? In monst_attack_monst and monst_attack_pc it adds 1 to the number of dice, yet in the scenario editor it doesn't subtract 1 from or add 1 to the number of dice to compensate. So does this mean that monsters have one more attack die than you give them? Or am I missing something?

Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
This in itself makes little sense, since sound 3 is "poison cough". (Sound 2 is "swish short" which may be the sound indicating a miss.)

This is because 2 and 3 are not the number of the played sound, but rather the index of the sound to play in the sound array of the boom_space() function (2 is loud sword, 3 is pole).

Originally Posted By: Celtic Minstrel
Therefore, it consists of the number of dice, multiplied by 100, plus the number of sides per die. As such, it's always greater than 100 (unless 0 dice are specified, in which case there's no attack at all).
Absolutely right, it's always true.

Originally Posted By: Celtic Minstrel
My guess is that the intent was to play a "punch" sound when the monster does less than 10 damage per hit, and a "sword" sound otherwise... though I was unable to find a "punch" sound available. So, basically, I'm quite confused about this.

There's the "club" sound (72.wav) that is used for punches, but i'd say the original intent may have been to play the "small sword" sound (69.wav, the dagger sound). I think we should remove the check already, i don't see a soldier attacking me with a dagger ...

Originally Posted By: Celtic Minstrel
EDIT: But wait, what's this? In monst_attack_monst and monst_attack_pc it adds 1 to the number of dice, yet in the scenario editor it doesn't subtract 1 from or add 1 to the number of dice to compensate. So does this mean that monsters have one more attack die than you give them? Or am I missing something?

Exact, using a 0 stat character vs a 1d1 monster, i take 2 damages each time ... I don't think we should fix that, that would alter the balance of the game ... confused

By the way, i've finished porting the scenario file IO functions to Win 32 bits (were using old 16 bits functions) and wonder if i should finish/implement the experimental (apparently Ormus') "import outdoor" function ...

Chokboyz

Edit : by the way, i think it would be correct to give a little report of activity for those that don't check the repository.
So here are the last things done in CBoE (Win32) :

Game :

- Giant Strength ability and Skill ability now use the ability strength rather than the item level to calculate effect.
- Won't take damage when moving boats over damaging terrains (fire, cold, magic, poison, disease) anymore. (update previous faulty fix)
- Won't take damage when horses refuses to enter a damaging terrain (fire, cold, magic) anymore.
- Boom effects won't be displayed at random places when being damaged outdoors anymore.

Scenario Editor :

- Dumping functions won't change current town/outdoor section anymore.
- Finished porting the file IO functions to 32 bits.
Link to comment
Share on other sites

Originally Posted By: Chokboyz
This is because 2 and 3 are not the number of the played sound, but rather the index of the sound to play in the sound array of the boom_space() function (2 is loud sword, 3 is pole).
Ohhhh.... I was missing something then.

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
My guess is that the intent was to play a "punch" sound when the monster does less than 10 damage per hit, and a "sword" sound otherwise... though I was unable to find a "punch" sound available. So, basically, I'm quite confused about this.

There's the "club" sound (72.wav) that is used for punches, but i'd say the original intent may have been to play the "small sword" sound (69.wav, the dagger sound). I think we should remove the check already, i don't see a soldier attacking me with a dagger ...
In fact, I think the intent is for humans who do less damage to punch rather than use a weapon. In particular, none of the townspeople are armed, so I suspect it's mainly meant to affect them.

But I'd rather allow the designed to explicitly specify the attack sound for the monster, so it won't make much difference if you change it. I'm not going to bother.

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
EDIT: But wait, what's this? In monst_attack_monst and monst_attack_pc it adds 1 to the number of dice, yet in the scenario editor it doesn't subtract 1 from or add 1 to the number of dice to compensate. So does this mean that monsters have one more attack die than you give them? Or am I missing something?

Exact, using a 0 stat character vs a 1d1 monster, i take 2 damages each time ... I don't think we should fix that, that would alter the balance of the game ... confused
No, don't change it. We just need to document it. Alternatively, we could do the increment upon loading an old-format scenario...

Originally Posted By: Chokboyz
By the way, i've finished porting the scenario file IO functions to Win 32 bits (were using old 16 bits functions) and wonder if i should finish/implement the experimental (apparently Ormus') "import outdoor" function ...
Well, rewriting the scenario format will require rewriting that function. I've commented out the entire body of functions that write to the scenario file in my code, since they will need to be rewritten.

Originally Posted By: Chokboyz
- Won't take damage when moving boats over damaging terrains (fire, cold, magic, poison, disease) anymore. (update previous faulty fix)
- Won't take damage when horses refuses to enter a damaging terrain (fire, cold, magic, poison, disease) anymore.
Note: I thought this only affected lava in the original game?
Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
But I'd rather allow the designed to explicitly specify the attack sound for the monster, so it won't make much difference if you change it. I'm not going to bother.
Giving the designer the choice is indeed the best choice ... I'm leaving it alone.

Originally Posted By: Celtic Minstrel
No, don't change it. We just need to document it. Alternatively, we could do the increment upon loading an old-format scenario...
Agreed. The old-format switch would requires the new scenarios to use a modified bladbase.exs (legacy monster attacks up by one to preserve consistency) but that's an idea ...

Originally Posted By: Celtic Minstrel
Note: I thought this only affected lava in the original game?

The danger of copy/pasting : the swamps and diseased lands still poison/disease the party while on horse, of course.
What has been fixed is : if the horses refuses to enter a square (lava, but also magic and cold damage), you don't take damages (legacy behavior was you take damages then you are said you can't enter).

Chokboyz

Edit: by the way, i've found that horses can cross lava if it's outdoor ("horses quite sensibly refuse" when in town). The party, of course, takes damage. The problem is i've found a piece of code that is supposed to prevent that, but is misplaced. I don't think fixing that would break any compatibility, since the party can always cross lava on foot, but i may be wrong ...

Edit2: ah, that's more problematic : the previous glitch also applies to horse blocking terrains. Fixing it would prevent horses from entering such terrains (after all there not supposed to enter them in the first place smile ) when outdoor and, again, force the party to continue by foot ...
Link to comment
Share on other sites

I think it should be fixed, anyway. Consistency a good thing.

 

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
No, don't change it. We just need to document it. Alternatively, we could do the increment upon loading an old-format scenario...
Agreed. The old-format switch would requires the new scenarios to use a modified bladbase.exs (legacy monster attacks up by one to preserve consistency) but that's an idea ...
The upside is that you won't have to edit the bladbase manually – once the conversion procedure is implemented (together with the ability to save in the new format) you can just open the bladbase and re-save it.

 

By the way, I'm thinking of allowing the designer to choose a bladbase when creating a new scenario, and providing them with 3 preset ones (one optimised for surface, one for grey cave, one for blue cave).

Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
I think it should be fixed, anyway. Consistency a good thing.

Yup, i've fixed it already ...

Originally Posted By: Celtic Minstrel
By the way, I'm thinking of allowing the designer to choose a bladbase when creating a new scenario, and providing them with 3 preset ones (one optimised for surface, one for grey cave, one for blue cave).

That's a good idea. Note that in the current version of the Win32 Scenario Editor, the bladbase.exs name is stored in the ini file, so that it can be edited if needed. With minimal efforts, it can be adapted (i.e changing a variable) to the behavior you're describing (the files and dialogs are to be done though wink ).

Chokboyz
Link to comment
Share on other sites

Whoa. I just noticed that you have not put the graphics or the sounds into the repository. I just added the sounds (in /trunk/rsrc/sounds.exa/), but if you could upload the Windows graphics, that'd be great (they can go in /trunk/rsrc/graphics.exd/win/). You can also cross-reference with the Mac graphics if you like, since they're there too; if they're different, that's probably not a good thing.

 

Those two directories (graphics.exd and sounds.exa) are going to be included in the Scenario Editor folder in the actual Mac release. Ideally the file extension will allow the Finder to disguise them as files; it's not working at the moment though. (There will also be a Mac-only resource file in the graphics.exd directory.)

 

 

 

 

It would be useful to have someone to fix bugs in the scenarios and the bladbase, by the way...

Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
Whoa. I just noticed that you have not put the graphics or the sounds into the repository. I just added the sounds (in /trunk/rsrc/sounds.exa/), but if you could upload the Windows graphics, that'd be great (they can go in /trunk/rsrc/graphics.exd/win/).

There no sound to compile with anymore, since all sound handling is done via the sound dll (do i upload the dll in the sound ressources folder ?).
Since we have a ressource repository, i'll upload the windows images. Unfortunately, i can't make them match Mac graphics files because it would break the current code ...

Originally Posted By: Celtic Minstrel
It would be useful to have someone to fix bugs in the scenarios and the bladbase, by the way...

I've uploaded a corrected bladbase some times ago. The only remaining bugs (that i'm aware of) are those in this thread http://www.ironycentral.com/forum/ubbthreads.php?ubb=showflat&Number=164683#Post164683.

Originally Posted By: Celtic Minstrel
It seems that TRAP_SLEEP_RAY actually paralyzes you. Is this right?

Yup, it paralyses you. (i think Ormus called it that way because it calls the sleep function, that handle both the sleep and paralysis cases.)

Chokboyz
Link to comment
Share on other sites

Originally Posted By: Chokboyz
There no sound to compile with anymore, since all sound handling is done via the sound dll (do i upload the dll in the sound ressources folder ?).
No, don't upload the dll – that's a "product" and doesn't belong in the repository. You should probably upload whatever is needed to create the dll though, unless you'd prefer to load directly from the files in sounds.exa. Basically, it should be possible for someone to check out the source and use what's there to build a fully functioning set of executables without needing to download anything else.

I notice that you have a separate project for each program. I just have a single project for all three. It's not at all important though. I just felt like pointing it out.

Originally Posted By: Chokboyz
Since we have a ressource repository, i'll upload the windows images. Unfortunately, i can't make them match Mac graphics files because it would break the current code ...
You could change ter6 and ter7, at least; I understand that you can't change ter5 because the removed graphics are used by the game. Don't worry too much about updating them to match, though – do it whenever the code is ready.

Originally Posted By: Chokboyz
I've uploaded a corrected bladbase some times ago. The only remaining bugs (that i'm aware of) are those in this thread http://www.ironycentral.com/forum/ubbthreads.php?ubb=showflat&Number=164683#Post164683.
Um... there is no bladbase.exs in the repository. If you do upload it into the rsrc directory, though, it should probably replace the Blades of Exile Base that's already there. The best way to do that is to rename Blades of Exile Base in your svn client, and then replace it with your version. You may want to compare them quickly to see if I have any fixes you don't, but it's rather unlikely.

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
It seems that TRAP_SLEEP_RAY actually paralyzes you. Is this right?

Yup, it paralyses you. (i think Ormus called it that way because it calls the sleep function, that handle both the sleep and paralysis cases.)
Okay then. I guess the name should be changed eventually. I'll put that on the TODO list.

(My TODO list consists of comments scattered throughout the code with a "TODO:" prefix; so, much less organized than yours.)


Oh... speaking of traps... is there any reason to keep these macros around?
Code:
#define DOOR_LIGHT can_enter = run_trap(7,&PSD[c_town.town_num][which],4220,0); break;#define DOOR_HEAVY can_enter = run_trap(7,&PSD[c_town.town_num][which],4220,20); break;#define DOOR_ALARM can_enter = run_trap(7,&PSD[c_town.town_num][which],4220,11); break;#define DRESSER_LIGHT can_enter = run_trap(7,&PSD[c_town.town_num][which],4221,0); break;#define DRESSER_HEAVY can_enter = run_trap(7,&PSD[c_town.town_num][which],4221,20); break;#define DRESSER_ALARM can_enter = run_trap(7,&PSD[c_town.town_num][which],4221,11); break;#define FLOOR_LIGHT can_enter = run_trap(7,&PSD[c_town.town_num][which],4222,0); break;#define FLOOR_HEAVY can_enter = run_trap(7,&PSD[c_town.town_num][which],4222,20); break;#define FLOOR_ALARM can_enter = run_trap(7,&PSD[c_town.town_num][which],4222,11); break;#define CHEST_LIGHT can_enter = run_trap(7,&PSD[c_town.town_num][which],3450,0); break;#define CHEST_HEAVY can_enter = run_trap(7,&PSD[c_town.town_num][which],3450,20); break;#define CHEST_ALARM can_enter = run_trap(7,&PSD[c_town.town_num][which],3450,11); break;
Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
No, don't upload the dll – that's a "product" and doesn't belong in the repository. You should probably upload whatever is needed to create the dll though, unless you'd prefer to load directly from the files in sounds.exa. Basically, it should be possible for someone to check out the source and use what's there to build a fully functioning set of executables without needing to download anything else.

The dll is Ormus' work ... I'll download the source and see if i can compile/upload it.

Originally Posted By: Celtic Minstrel
You could change ter6 and ter7, at least;

Ok, i will, if i find some time ...

Originally Posted By: Celtic Minstrel
Um... there is no bladbase.exs in the repository. If you do upload it into the rsrc directory, though, it should probably replace the Blades of Exile Base that's already there. The best way to do that is to rename Blades of Exile Base in your svn client, and then replace it with your version. You may want to compare them quickly to see if I have any fixes you don't, but it's rather unlikely.

I've done that ... Oh, i didn't mentioned that bladbase refers to Blades of Exile Base file, did i ? wink

Originally Posted By: Celtic Minstrel
Oh... speaking of traps... is there any reason to keep these macros around?

No, Ormus has already removed them from the Win32 code (besides they're not used anywhere in the original code as far as i can tell).

Chokboyz
Link to comment
Share on other sites

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
Um... there is no bladbase.exs in the repository. If you do upload it into the rsrc directory, though, it should probably replace the Blades of Exile Base that's already there. The best way to do that is to rename Blades of Exile Base in your svn client, and then replace it with your version. You may want to compare them quickly to see if I have any fixes you don't, but it's rather unlikely.

I've done that ... Oh, i didn't mentioned that bladbase refers to Blades of Exile Base file, did i ? wink
What do you mean?

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
Oh... speaking of traps... is there any reason to keep these macros around?

No, Ormus has already removed them from the Win32 code (besides they're not used anywhere in the original code as far as i can tell).
No, they aren't; I checked several months ago. I was just wondering if there may be some reason to use them. Probably not though.
Link to comment
Share on other sites

Originally Posted By: Celtic Minstrel
What do you mean?

I mean that i've updated the Blades of Exile Base file (the one in the mac repository) with the fixes, some times ago (cf the update log).

Originally Posted By: Celtic Minstrel
The raw fact of the matter is that there is no observable fact of nature that “proves” the universe is billions of years old, nor “proves” that all lifeforms evolved from an original common ancestor”

It all depends of the definition of "to prove" (empiricism, existence of absolute truth and so on ...). Then again, what does it have to do with BoE ? wink

Originally Posted By: Celtic Minstrel
I was just wondering if there may be some reason to use them. Probably not though.

I would delete them already ... Besides they seems to be using some party.stuff_done array that is not a good thing ...

Chokboyz
Link to comment
Share on other sites

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
What do you mean?

I mean that i've updated the Blades of Exile Base file (the one in the mac repository) with the fixes, some times ago (cf the update log).
Oh wow, I didn't notice that.

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel some idiot on a blog
The raw fact of the matter is that there is no observable fact of nature that “proves” the universe is billions of years old, nor “proves” that all lifeforms evolved from an original common ancestor”

It all depends of the definition of "to prove" (empiricism, existence of absolute truth and so on ...). Then again, what does it have to do with BoE ? wink
...It doesn't. That was actually something someone said on a blog somewhere that I copy-pasted to respond to, and I have no idea how it got into that post. (ie it wasn't even my words; I've edited it out.)

Originally Posted By: Chokboyz
Originally Posted By: Celtic Minstrel
I was just wondering if there may be some reason to use them. Probably not though.

I would delete them already ... Besides they seems to be using some party.stuff_done array that is not a good thing ...
'k, I will.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...