Page 1 of 2

Monster moving filter (CSBwin)

Posted: Sun Mar 13, 2005 1:08 pm
by Zyx
I almost cleared my autonomous "to do" list. But I have other ideas relying on some possible features, like a monster moving filter.
I'd like to have a chance to trigger a DSA when a monster plans to move, with some other possibilities like:
cancel the movement
choose the direction of facing
choose the tile aimed

Is it possible?

Posted: Sun Mar 13, 2005 4:23 pm
by Paul Stevens
That is difficult. I have worked on the Monster AI business for
many hours and have not figured out very much. I am afraid that
anything we do in this area will cause bugs for some time to come.

I'll look at it with just the movements in mind to see if there is
anything at all that can be implemented safely.

Posted: Sun Mar 13, 2005 6:46 pm
by Paul Stevens
One thing worries me. There can be thousands of monsters in a
dungeon. DSAs are not too efficient. If we fire up a DSA every time
a monster is about to move we could eaily overwhelm the CPU. I don't
know what to do about this. Restrict to one level. Restrict to particular
monsters. Restrict to particular ?????.

It occured to me that even though I do not know how monsters work I
could relatively easily add code that 'pretends' that there are walls adjacent
to the monster to restrict its movements. Or to restrict its vision. Your DSA
could say:

"Prevent movement to the south and east." (Pretend there are stone walls).
"Prevent vision to the north, west, and south." (As if the party were far away).
"Pretend the party is at relative location (1,2)." (relative to the monster)

I don't quite know what these statements mean exactly. Especially
the 2nd one. But it seems likely we could get them to do some useful
things without breaking the MonsterAI itself.

Posted: Sun Mar 13, 2005 10:48 pm
by Zyx
Restricting to the current level would be a start, since otherwise I would have added checkups in the DSA to ensure the moving monsters are on the same level as the party.
You could also restrict to a certain distance from the party, like a maximum of 10 tiles away.

The three functions you suggested look very interesting.

Posted: Sun Mar 13, 2005 11:38 pm
by Paul Stevens
OK. Here we go again. And, since you did not want a single new
feature, you may as well tell me now what additional features you
need.

Posted: Sun Mar 13, 2005 11:51 pm
by Zyx
I hope you're asking a question you want to be answered...

PARTY ATTACK FILTER:
Possibility to trigger a DSA, etc.
Access to the action used (from the combo, like punch/kick,warcry)
Possibility to change damage to be done.
Possibility to change time of recovery.

EXAMINING FILTER: (when putting an object on the eye in the inventory screen)
Possibility to trigger a DSA, etc.
Possibility to add other lines of information.

SHOW COMPLETE INFORMATION:
When examining an item, like an apple, you currently don't see if it's broken or poisonned, or cursed.

ADD EXISTING TAGS:
All the objects don't share the same tags, but could. (except maybe chests and potions)

ADD NEW TAGS:
To be discussed... There is already a thread mentionning it. Not sure I need it.

Posted: Wed Mar 16, 2005 10:17 pm
by Paul Stevens
Get 'MonsterMovementFilter.rar'. There is even a little bit
of documentation. I will try to add some more. The Giggler
is easy to push back into the dead-end with this filter that
prevents him from moving east.

Posted: Wed Mar 16, 2005 10:36 pm
by Zyx
Could you upload it again, the archive seems to be corrupt.

Posted: Wed Mar 16, 2005 11:23 pm
by Guest
There. That seems better.

Posted: Thu Mar 17, 2005 3:01 am
by Zyx
The solution you found is so simple and elegant, yet useful! Could you provide the monster ID and monster location?

Posted: Thu Mar 17, 2005 5:03 pm
by Guest
The parameters are described in the Monster Movement Filter documentatiion.
I updated it this morning.

Posted: Thu Mar 17, 2005 9:34 pm
by Paul Stevens
When examining an item, like an apple, you currently don't see if it's broken or poisonned, or cursed.
There ain't no such thing as a poisoned apple or a broken apple.

The code sets a 'Cursed' bit for MISC items ( when a Deth Knight
creates an apple upon death..,..of course it never happens .. only
cursed swords ) but it NEVER looks at the cursed bit in MISC items.

You can set an apple 'Cursed' using a DSA. But the graphics.dat file
says that apples cannot be cursed so it does not get printed. You can
fix that by changing the graphics.dat. The code that prints the apple's
characteristics also says that apples cannot be cursed. I fixed that.

If we add poisoned and broken flags to MISC items then I am going to
have to be careful about loading old dungeons in which the bits were
not used and may contain random values. Also, I don't know what the
original graphics.dat file has for these bits. But these problems are
surmountable.

At any rate, I am not going to do anything more right away. I am just
letting you know where things stand and would like feedback from you as
to what you think we should do. The code could ignore the graphics.dat
but that would mean that all MISC items are treated identically as far as
the broken, cursed, and poisoned flags are concerned. It also would mean
that the designer could not plant a 'poisoned' apple without the player
being able to examine the 'poison' flag. If we use the flags in the graphics.dat
then an apple could be poisoned but that would not be printed.
Possibility to add other lines of information
Do you mean additional info between the parentheses? Or a
line at the bottom of the current text? Where do you envision that
this text would come from? From a text object in an unused cell
of the dungeon?

Posted: Thu Mar 17, 2005 11:01 pm
by Zyx
Possibility to add other lines of information:
I meant "a line at the bottom of the current text", and I was thinking about "a text object in an unused cell of the dungeon", like with &SAY.

I think the cursed flag should be treated identically for all the items: this flag was already displayed for weapons and armors, and there's no reason curses on other items couldn't be identified.

As for broken and poisonned tags, since they were never displayed and could be used for hidden flags, let's the designer choose by design if he wants to display it or no in the "Examine filter". So don't do anything to display them.

How many supplementary lines of information would fit in the examine window? (Considering a consumable, cursed object which would already use two more lines.) 3 or 4, no?

Posted: Mon Mar 21, 2005 4:37 am
by Paul Stevens
Zyx wrote
EXAMINING FILTER:
Try ViewFilter.rar

Also, the documentation has been updated.

Posted: Mon Mar 21, 2005 5:14 am
by Zyx
And just when I climbed this whole mountainside to wash my eyelids in the rain...

Err, I mean, and just when I was going to bed!
I'll try it. But from the documentation I can already ask: could you add a "color" parameter to the &DESCRIBE operation?

Posted: Mon Mar 21, 2005 5:53 am
by Paul Stevens
Each line can be in its own color easily. But the parenthesised
list counts as one line an is all in the same color. If you want
individual phrases within the parenthesised list to be in different
colors then we are going to have to do a lot of work to rewrite
the existing code that does the drawing.

Posted: Tue Mar 22, 2005 4:25 am
by Zyx
It would be enough to be able to color each line, the parenthesised list counting as one line.

Posted: Tue Mar 22, 2005 2:53 pm
by Paul Stevens
It would be enough to be able to color each line
Get the latest 'ViewFilter.rar'

The 'Party Attack' filter is quite possible. But it is going to require a
lot of study on my part to decide a consistent interface and then to
wiggle it into the existing code. In order for it to be less than totally ugly,
I am going to have to rearrange the existing code.

Posted: Tue Mar 22, 2005 5:12 pm
by Zyx
Nice!
It seems that I cannot use charnum=4 (active character) with &MASTERY.

Could you provide a parameter with &PARAM@ in the viewing filter for the index of the viewing character?

Posted: Tue Mar 22, 2005 8:55 pm
by Zyx
Fetching the objectID with &PARAM@ in the viewing filter brings a wrong ID.

Posted: Wed Mar 23, 2005 4:44 am
by Paul Stevens
I attempted to fix all three concerns. See new ViewFilter.rar

Posted: Wed Mar 23, 2005 5:09 am
by Zyx
Thanks, everything works. just a detail; &DESCRIBE doesn't leave a trace.

Posted: Fri Apr 08, 2005 1:00 am
by Zyx
Zyx wrote:PARTY ATTACK FILTER:
Possibility to trigger a DSA, etc.
Access to the action used (from the combo, like punch/kick,warcry)
Possibility to change damage to be done.
Possibility to change time of recovery.
Refreshing meory... You didn't say if it was possible or not.

Posted: Fri Apr 08, 2005 2:05 am
by Paul Stevens
Mostly possible, I think. Some not as clean as the
other filters because too many parameters come into
play. Its 'ugliness' is one reason I have been putting
it off. If you really need it we can work on it.

But right now I am trying to set up a demonstration of
the custom backgrounds as a proof-of-concept. That
interests me more than the attack filter so that is what I am
doing. When (if?) I finish the demo and nobody needs
me to proceed with it (like doing the walls) then I can get
to your party attack filter business.

Posted: Fri Apr 08, 2005 5:12 pm
by Zyx
Okay, I'll work on the hints in the meantime.

Posted: Fri Apr 08, 2005 5:46 pm
by Paul Stevens
I'll work on the hints
Oh, WOW!!! If you have enough strength to publish a
decent Hint File then ConfluxII will become the Grand
Master of all DM-derived games.....The original DM
and CSB will most definitely have to take a back seat.
I cannot imagine the amount of work you have and
will have put into this. It is staggering.

I hope you also put a lot of the history and interesting
facts about your game into the 'Game Information' so
that it will be sure to survive as long as the game itself
survives. I will for sure be showing off ConfluxII as
THE example of what someone managed to accomplish
using my programs.

What the internet has made possible!

Posted: Mon Apr 11, 2005 1:20 am
by Zyx
Well, I've been working hard on this damned hints file and after formatting 3854 locations, 218 hints and 570 pages, I'm getting weary.

The worst part is linking locations to the hints, and checking there's no error in the location.

Here's an example:

Code: Select all

JUST A ROOM
(2,8,24)(2,9,24)(2,10,24)(2,8,25)(2,9,25)(2,10,25)(3,1,21)
(3,0,21)(3,0,22)(3,2,22)(3,0,23)(3,1,23)(3,2,23)(5,3,14)(5,2,14)
(5,1,15)(5,2,15)(5,3,15)(5,2,16)(5,30,5)(5,30,4)(5,31,4)(5,29,3)
(5,30,3)(5,31,3)(6,30,0)(6,31,0)(6,29,1)(6,30,1)(6,31,1)(6,30,2)
(6,31,2)(6,30,11)(6,30,12)(6,31,12)(6,30,13)(6,31,13)(6,19,8)
(6,20,8)(6,17,9)(6,18,9)(6,19,9)(6,20,9)(6,19,10)(6,20,10)
(6,19,11)(6,20,11)(6,4,18)(6,5,18)(6,4,19)(6,5,19)(6,3,8)
(6,4,8)(6,3,9)(6,4,9)(10,26,24)(10,27,24)(10,26,25)(10,27,25)
(10,27,26)(12,27,10)(12,28,10)(12,26,11)(12,28,11)(12,29,11)
(12,30,11)(12,25,12)(12,26,12)(12,27,12)(12,28,12)(12,29,12)
(12,30,12)(12,28,13)(12,29,13)(12,30,13)(12,31,13)(12,29,14)
(12,30,14)(12,31,14)(12,28,15)(12,29,15)(12,30,15)(12,31,15)
(12,18,24)(12,19,24)(12,20,24)(12,21,24)(12,23,24)(12,19,25)
(12,20,25)(12,21,25)(12,22,25)(12,23,25)(12,21,26)(12,23,26)
(12,25,25)(12,26,25)(12,27,25)(12,28,25)(12,29,25)(12,30,25)
(12,31,25)(12,27,24)(12,30,24)(12,31,24)(12,31,23)(12,26,26)
(12,27,26)(12,28,26)(12,28,27)(12,30,26)(12,31,26)(12,30,27)
(13,15,28)(13,16,28)(13,15,29)(13,16,29)(13,15,30)(13,16,30)
(13,10,12)(13,11,12)(13,11,11)(13,9,13)(13,10,13)(13,11,13)
(13,12,13)(13,9,14)(13,10,14)(13,11,14)(13,10,15)(13,11,15)
(13,12,15)

A treasureless, puzzleless room. Watch for monsters and pits.
But I realize it wouldn't be so hard for you to read these hints and locations from a .txt file with CSBuild, creating a list of hints and displaying their locations on the maps, with red spots for example, allowing adding or removing a location, and saving back to the hint file (a simple txt file. There is a tool for converting to a .htc file).
It would be save weeks of hard work!
Could you do it?

Posted: Mon Apr 11, 2005 2:51 am
by Paul Stevens
I think the hint file is extremely important. I want you to be able
to make the very best possible. I am willing to help. Let us
discuss this off-line. We can probably do something even
more helpful than what you suggest. Perhaps it should be
a formal, permanent part of CSBuild.
it wouldn't be so hard for you
That is easy for you to say!!!!

Posted: Mon May 09, 2005 12:04 am
by Zyx
I think I already reported, this but I can't find it anymore:
when I set a monster to "poisonned", it becomes invisible!

Also, I think that a jump instruction to a line without operation changes the state of the DSA. For example, J10 set the state to 10 if there's nothing at line 10S0. If I put the operation "N", it works fine.

Posted: Wed Jul 04, 2007 1:35 pm
by Adamo
finally I dig into this thread! I wonder why it is in Archives section?