Talk:Actbusy

From Valve Developer Community
Jump to: navigation, search

Image

The image needs to be updated to remove the queue. It could be tweaked to better show the relationship between ai_goal_actbusy & the NPCs it controls. Something like this:

                    ai_goal_actbusy
                     /    |      \
                    /     |       \
                  NPC    NPC      NPC
                  /|      |\      /|\
                 / |      | \    / | \
                /  |      |  \  /  |  \
               /   |      |   \/   |   \
             node node  node node node node

Since each actbusy can point to multiple NPCs, and each NPC can use multiple nodes, including ones that other NPCs would use if they got to them first.

I'm not so happy with this version. Any second opinions would be welcome. [1] --TomEdwards 01:52, 4 Jul 2005 (PDT)
Tom, it's a good job, what weren't you happy with? --wisemx 06:46, 4 Jul 2005 (PDT)
I don't know. It just doesn't seem as well-defined as the others. --TomEdwards 06:52, 4 Jul 2005 (PDT)

Scripting problem

I'm having some problems getting my npc_citizen to sit on the ground. Maybe i missed something, because when i try he just stands in the idle position. Here are some of my specifics if someone is able to help me out.

in actbusy.txt:

"sit_ground_01"

{

"busy_sequence" "ACT_BUSY_SIT_GROUND"

"entry_sequence" "Idle_to_ACT_BUSY_SIT_GROUND"

"exit_sequence" "ACT_BUSY_SIT_GROUND_to_Idle"

"min_time" "10.0"

"max_time" "20.0"

"interrupts" "BA_INT_COMBAT"

}

-I have a 'logic_auto' which has 1 output,

onmapspawn, citizen, wake, 0.0

-I have a 'npc_citizen' under the name of citizen which has 1 output,

onwake, actbusy_01, activate, 0.0


-I have a 'ai_goal_actbusy' under the name of actbusy_01,

actors to affect, citizen

start active, no


-I have a 'info_node_hint' under the name of sit_ground_01, which is right in front of citizen,

hint, 'world: act busy hint

hint activity, sit_ground_01

node FOV, 360 degrees


-all else is still set to its default setting

-all entities are not in the ground, but on or above by little

-please help, I am soooooooo frustrated

-Ethan Swanson

What about Search Range for Busy Hints?—ts2do (Talk | @) 21:56, 5 Jan 2006 (PST)

You don't need the Wake/OnWake stuff. If your citizen doesn't have the "Start Asleep" spawnflag set, it may be ignoring the wake input, and hence not generating the OnWake output. Just hook your logic_auto OnMapSpawn straight to the Actbusy Activate input. Note that the NPC may take up to 10 seconds to act busy, because NPCs don't continuously try to ActBusy. If this doesn't fix it, try manually firing the actbusy to see if your problem is in your entity logic. Use the ent_fire command (i.e. "ent_fire actbusy_01 activate") and see if that fixes it. You can also see entity logic at work by using ent_messages_draw, or setting developer to 2 and reading the console. Once you've got your actbusy correctly activated, if the citizen still isn't acting busy, look in the console for red warning errors. If the citizen is trying to act busy but unable to find the node, the ai_debug_actbusy convar described in the article will help you figure out why (try setting it to 3, and npc_select the citizen). Robin Walker 00:01, 7 Jan 2006 (PST)

Thanks a bunch for the help, it's working now!!!!! -Ethan Swanson