Eating filter (CSBwin)
Moderator: Zyx
Forum rules
Please read the Forum rules and policies before posting.
Please read the Forum rules and policies before posting.
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
I posted CSBwin95v52test4. From release notes:
--DSA - &SAY recognizes '/' as line-break
--DSA - Fixed "J10" causes state to change if state 10S0 is <empty>.
--DSA - Fixed "Text too long" error in &SAY
--DSA - Fixed &CHAR! to dead character leaves multiple bones.
--DSA - A 'Size-4' monster now drops implicit items only wwhen last monster of group dies.
--DSA - Fixed "Eating heals even when parameter 19 is zero".
Reported problems I could not fix:
Need example, I guess.
and they both worked for me. Need example.
--DSA - &SAY recognizes '/' as line-break
--DSA - Fixed "J10" causes state to change if state 10S0 is <empty>.
--DSA - Fixed "Text too long" error in &SAY
--DSA - Fixed &CHAR! to dead character leaves multiple bones.
--DSA - A 'Size-4' monster now drops implicit items only wwhen last monster of group dies.
--DSA - Fixed "Eating heals even when parameter 19 is zero".
Reported problems I could not fix:
I tried everything I could think of and it worked for me.Feeding filter parameter 13 affects wisdom
instead of curing poison
Need example, I guess.
The code looks right. I tried both poisin and invisibleSetting monster to poisoned causes it to
become invisible
and they both worked for me. Need example.
>Feeding filter parameter 13 affects wisdom instead of curing poison
It works now with the new version.
>Setting monster to poisoned causes it to become invisible
It seems to be related to the &monster! operation.
The trace shows only 6 parameters by the way:
LOAD INTEGER 7 (14033 10 7)
&Monster@ { 4 17 1000 1 1 1} ()
Also, if I kill 3 monsters out of a group of 4, their number decreases only by one:
Example:
It works now with the new version.
>Setting monster to poisoned causes it to become invisible
It seems to be related to the &monster! operation.
The trace shows only 6 parameters by the way:
LOAD INTEGER 7 (14033 10 7)
&Monster@ { 4 17 1000 1 1 1} ()
Also, if I kill 3 monsters out of a group of 4, their number decreases only by one:
Example:
Code: Select all
DSA:
&Monster@ { 4 17 1000 1 1 1} ()
...
&Monster! { 4 17 999 0 0 0 8} ()
(events)
DSA:
&Monster@ { 3 17 999 0 0 0} ()
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
Here's the new trace:
Code: Select all
DSA:
&Monster@ { 4 17 1000 1 1 1 8} ()
...
&Monster! { 4 17 999 0 0 0 8} ()
(events)
DSA:
&Monster@ { 3 17 999 0 0 0 13} ()
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
help! I`ve got a problem. I want to change special value of one type of food on the whole game (for example: I want all in-game shanks to give +5 mana everytime when eaten; while dragon steaks would increase your health... etc.).
How should I do it?
I tried to change that DSA given by Paul in his "feeding filter demo":
But how to cause changing selected parameters of ALL apples in the game, no matter, where are they placed?
Also - what to do in that example, if I want to change values of another food type (for example cheese)?
I feel that each type of food should have its own DSA (working in the whole game). I know, that object type number of apple = a8/168, but how to place it?
Very sorry for my ignorance - I really tried to learn DSAing, but it`s still a black magic for me.
Thanx for help!
How should I do it?
I tried to change that DSA given by Paul in his "feeding filter demo":
but with my little knowledge of DSAing all I could do, was to change values of an apple, wchich lies in specified (?) tile, by changing parameters and values in C0 line (it`s quite simple - replacing parameters like "food value" [5th parameter] or "hitpoint adjustment" [18th parameter] etc., and their values).S0: L26 L0 &PARAM@ L4 &@ ??{(9,C0)}
C0: L200 &NEG L18 &! L4000 &NEG L5 &! L4000 &NEG L6 &! GT3
T3: L26 L0 &PARAM!
But how to cause changing selected parameters of ALL apples in the game, no matter, where are they placed?
Also - what to do in that example, if I want to change values of another food type (for example cheese)?
I feel that each type of food should have its own DSA (working in the whole game). I know, that object type number of apple = a8/168, but how to place it?
Very sorry for my ignorance - I really tried to learn DSAing, but it`s still a black magic for me.
Thanx for help!
Spoiler
(\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/)
Spoiler
(@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@)
Spoiler
(>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<)
S0: L27 L0 &PARAM@ L3 &@ ??{(174,1S0)}
1S0: L5 L17 &! L27 L0 &PARAM!
The problem is you were using parameter 4, which is the ID of a specific object. Instread, use parameter 3, which is the type ID - ie all shanks, apples, etc. Unlike the usual 'type' command (which has numbers like 10035 for shank) the feeding filter uses the type ID found through CSBuild (look at the number after the object ID, for shanks it is M174 for miscellaneous item, type 174
Note the ??{(174,1S0)} is a case statement. So for cheese (item id 171), you could add the bit ??{(174,1S0)(171,2S0)} and in state 2 have simple or complex code for cheese
So as you can see this way you use state 0 as a sorting area, then the ?? redirects the code to the appropriate state if it is a cheese, shank, or as you sat 168 for apple
1S0: L5 L17 &! L27 L0 &PARAM!
The problem is you were using parameter 4, which is the ID of a specific object. Instread, use parameter 3, which is the type ID - ie all shanks, apples, etc. Unlike the usual 'type' command (which has numbers like 10035 for shank) the feeding filter uses the type ID found through CSBuild (look at the number after the object ID, for shanks it is M174 for miscellaneous item, type 174
Note the ??{(174,1S0)} is a case statement. So for cheese (item id 171), you could add the bit ??{(174,1S0)(171,2S0)} and in state 2 have simple or complex code for cheese
So as you can see this way you use state 0 as a sorting area, then the ?? redirects the code to the appropriate state if it is a cheese, shank, or as you sat 168 for apple
big thanx for help, Beo !!!!!!
everything works fine now, but there`s one problem...
...feeding filter doesn`t work with newest CSBwin v.111 (works with that old one from "feeding filter demo" only and v.76). When I`m trying to eat "modified" food, game hangs up with no info. A bug??
everything works fine now, but there`s one problem...
...feeding filter doesn`t work with newest CSBwin v.111 (works with that old one from "feeding filter demo" only and v.76). When I`m trying to eat "modified" food, game hangs up with no info. A bug??
Spoiler
(\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/)
Spoiler
(@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@)
Spoiler
(>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<)
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
If you are convinced that your DSA is not 'hanging up with no info'
then send me a copy of your dungeon and I will see what's
wrong. Even if it is your DSA at fault, maybe I can make
the thing more fool-proof. There are a lot of illegal
things I never bothered to check for.
Also, send a recording that demonstrats the problem.
then send me a copy of your dungeon and I will see what's
wrong. Even if it is your DSA at fault, maybe I can make
the thing more fool-proof. There are a lot of illegal
things I never bothered to check for.
Also, send a recording that demonstrats the problem.
ok, I have just sent you an email with compressed file and a description of a problem.
Spoiler
(\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/)
Spoiler
(@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@)
Spoiler
(>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<)
- Paul Stevens
- CSBwin Guru
- Posts: 4318
- Joined: Sun Apr 08, 2001 6:00 pm
- Location: Madison, Wisconsin, USA
bumped for myself - I need to get into it once again
Spoiler
(\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/) (\__/)
Spoiler
(@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@) (@.@)
Spoiler
(>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<) (>s<)