Announcement: Remember: you are giving away your fantastic ideas for free, and somebody else might even make money from them (or appear to). That's just how the world works! If you're worried about it, maybe you shouldn't post your ideas here.


Caravel Forum : DROD Boards : Feature Requests : Set Behavior script command
New Topic New Poll Post Reply
Poster Message
hyperme
Level: Smitemaster
Avatar
Rank Points: 1055
Registered: 06-23-2006
IP: Logged
icon Set Behavior script command (+3)  
Set Behavior is a script command used to set various Character properties and behaviors. Unlike Imperative, which covers a number of categories, Set Behavior only applies to properties that can be On or Off.

UI wise, Set Behavior contains two parts: a list of behaviors, and an On/Off selector. You choose a behavior, and the state you want it set to. Simple and easy.

There are a number of behaviors that may be useful to set, in several categories:

Damage protection - configure if weapons, spike traps, fire traps, hot tiles, explosions or puffs can harm an Character.
Room interaction - configure if an Character drops trapdoors or pushes objects.
Monster interactions - configure if an Character is a Monster Target or an Ally Target
Other stuff - configure things I haven't thought of.

(In theory I could implement this right now but people might have strong feels on messing with internal Character workings.)

____________________________
[Insert witty comment here]
Qzvlkx?
07-19-2018 at 09:26 PM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
Pinnacle
Level: Smitemaster
Avatar
Rank Points: 1126
Registered: 06-10-2004
IP: Logged
icon Re: Set Behavior script command (0)  
Would it be possible to apply these to player roles as well?

____________________________
Once (adv.): Enough.
Twice (adv.): Once too often.
~Ambrose Bierce, The Devil's Dictionary
07-20-2018 at 07:00 PM
View Profile Send Private Message to User Send Email to User Show all user's posts High Scores This architect's holds Quote Reply
Xindaris
Level: Smitemaster
Avatar
Rank Points: 1527
Registered: 06-13-2015
IP: Logged
icon Re: Set Behavior script command (0)  
I would like to throw all of the support that I possibly can behind getting this stuff, and as soon as possible :D

____________________________
109th Skywatcher

Here are some links to Things!
Click here to view the secret text

07-20-2018 at 07:02 PM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
mauvebutterfly
Level: Smitemaster
Avatar
Rank Points: 720
Registered: 05-03-2015
IP: Logged
icon Re: Set Behavior script command (+1)  
Other possible things to include:

-immune to briar (like serpents)
-toggles tokens (like citizen monsters currently)
-pushes platforms?
-can walk on horns/potions? (like guards and slayers)
-can't be pushed to death (single-tile gentryii can't be pushed into a pit, for instance)

General movement stuff would be nice too:

-flies
-swims
-swims (shallow only)
-walks
-wall-movement (seep)

____________________________
106th Skywatcher
07-21-2018 at 01:07 AM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
mauvebutterfly
Level: Smitemaster
Avatar
Rank Points: 720
Registered: 05-03-2015
IP: Logged
icon Re: Set Behavior script command (0)  
I'm not sure if movement falls within what you're proposing here, but having thought about it some more, it would probably be better to have a toggle for being able to cross pits instead of being able to fly, since flight has a bunch of other assumptions built into it. This would make being able to toggle pressure plates a separate command from flight and would allow for distinctions between elements like wraithwings and puffs with regards to hot tiles instead of just assuming some behaviour.

____________________________
106th Skywatcher
07-21-2018 at 06:35 AM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
mrimer
Level: Legendary Smitemaster
Avatar
Rank Points: 5056
Registered: 02-04-2003
IP: Logged
icon Re: Set Behavior script command (0)  
I've approved hyperme's PR for the next major release (5.2). Thank you!

____________________________
Gandalf? Yes... That's what they used to call me.
Gandalf the Grey. That was my name.
I am Gandalf the White.
And I come back to you now at the turn of the tide.
09-22-2020 at 06:26 PM
View Profile Send Private Message to User Send Email to User Show all user's posts High Scores This architect's holds Quote Reply
Nuntar
Level: Smitemaster
Avatar
Rank Points: 4576
Registered: 02-20-2007
IP: Logged
icon Re: Set Behavior script command (+2)  
I'm not sure if this is already included, but one really nice thing to have would be interaction with tunnels. Being able to make entities move through tunnels would be especially nice, but there's an obvious problem with that idea: suppose you have a monster with "can move through tunnels" set, how does a script tell it to make that move? Perhaps just say that if it's on (for example) an east tunnel, and it encounters either a "Move" or "Move to" that would direct it east if the tunnel weren't there, it goes through the tunnel.

Even if going through tunnels is excluded, it would still be nice to be able to give entities standard behaviour (can only move onto tunnels to make a kill), as well as the alternatives "can never move onto tunnels" and "treat tunnels as open floor".

____________________________
50th Skywatcher
10-02-2020 at 02:31 AM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
Kaelyn
Level: Delver
Rank Points: 76
Registered: 01-21-2019
IP: Logged
icon Re: Set Behavior script command (0)  
A few more options off the top of my head:
hyperme wrote:
Damage protection - configure if weapons, spike traps, fire traps, hot tiles, explosions or puffs can harm an Character.
We could add vulnerable to being eaten by adders to that list. Furthermore, if adders can eat this creature, an option for if the adder gets longer, shorter, or stays the same length.

Also whether or not monster attacks will kill the character. Combined with "monster target" and we could create characters that act like decoys -- attractive but also sturdy.
Room interaction - configure if an Character drops trapdoors or pushes objects.
In addition to interacting with tunnels and platforms, this could also include whether or not this character drops thin ice, or even whether or not it will form thin ice when killed over water.

I like mauve's suggestion to separate "activates pressure plates" from flying behavior. I think breaking down flying/swimming into "crosses water", "crosses shallow water", and "crosses pit" (in addition to "crosses walls" and "crosses closed doors" to include seep behavior, and even crazy things like "crosses briar" and "crosses tarstuff" for extra fun) might be a good way to handle it.

Just a few thoughts: Seep can jump out of walls to kill something, but they'll immediately die afterward. Waterskippers can leap out of water to kill something, and they can survive being on land. And while seep can jump into pit and water to kill, and waterskippers will jump into pit, waterskippers won't jump into walls. Meanwhile, landbound creatures like roaches can't walk onto walls, pit, or water to kill. I don't know the best way to encode these kinds of interactions.
Monster interactions - configure if an Character is a Monster Target or an Ally Target
Also whether or not the character is targeted by puffs!
Other stuff - configure things I haven't thought of.
Perhaps whether or not a character acts like a brain for the purposes of granting monsters pathfinding. This is getting out there, but maybe a character could act like a tarstuff mother and grow tarstuff in the room.

What kind of "blood spatter" the creature dies with: normal blood, purple slayer stuff, green seep squares, etc.

Maybe "can be tabbed to" so it acts like a clone.

There's even more options, but this script command is something we can add to over time.
10-02-2020 at 03:37 AM
View Profile Send Private Message to User Show all user's posts Quote Reply
Xindaris
Level: Smitemaster
Avatar
Rank Points: 1527
Registered: 06-13-2015
IP: Logged
icon Re: Set Behavior script command (0)  
I would say that, when it comes to the "exceptional" behavior of a monster jumping out of its "natural" habitat to kill something, what happens at that point is probably best left as the responsibility of the DROD-scripter to properly code up. Like, just use a teleport command and then check what it's "landed" on to decide whether it dies or not, that sort of thing.

However, I heavily second that 'pushes pressure plates' being separate from 'flying' would be very helpful. A certain custom pushable of my own creation would be much better off with such a distinction, for the reason that there are situations where it doesn't "canonically" fly but needs to "mechanically" fly in order to process everything that it's supposed to process. And I feel like the need for something like that, or at least cases where it would be more convenient than other alternatives, is bound to crop up more commonly than one might expect.

____________________________
109th Skywatcher

Here are some links to Things!
Click here to view the secret text


[Last edited by Xindaris at 10-02-2020 04:16 AM]
10-02-2020 at 04:15 AM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
Dragon Fogel
Level: Smitemaster
Rank Points: 2430
Registered: 06-21-2014
IP: Logged
icon Re: Set Behavior script command (0)  
I was looking over other topics (specifically, the one about bodykilling decoys) and noticed that it mentioned that killing Slayer NPCs doesn't break stealth - I'm guessing, but haven't yet tested, that killing NPCs in general doesn't break stealth.

So a behavior that makes them do that (or not do it, if it turns out they do in some cases?) would probably have some uses.
10-09-2020 at 07:19 PM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
New Topic New Poll Post Reply
Caravel Forum : DROD Boards : Feature Requests : Set Behavior script command
Surf To:


Forum Rules:
Can I post a new topic? No
Can I reply? No
Can I read? Yes
HTML Enabled? No
UBBC Enabled? Yes
Words Filter Enable? No

Contact Us | CaravelGames.com

Powered by: tForum tForumHacks Edition b0.98.8
Originally created by Toan Huynh (Copyright © 2000)
Enhanced by the tForumHacks team and the Caravel team.