mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-19 06:03:14 +00:00
* Renames delta time to be a more obvious name * updates to our code --------- Co-authored-by: oranges <email@oranges.net.nz> Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
23 lines
1000 B
Plaintext
23 lines
1000 B
Plaintext
/datum/ai_planning_subtree/punpun_shenanigans/SelectBehaviors(datum/ai_controller/monkey/controller, seconds_per_tick)
|
|
|
|
controller.set_trip_mode(mode = FALSE) // pun pun doesn't fuck around
|
|
|
|
if(prob(5))
|
|
controller.queue_behavior(/datum/ai_behavior/use_in_hand)
|
|
|
|
if(!SPT_PROB(MONKEY_SHENANIGAN_PROB, seconds_per_tick))
|
|
return
|
|
|
|
if(!controller.blackboard[BB_MONKEY_CURRENT_PRESS_TARGET])
|
|
controller.queue_behavior(/datum/ai_behavior/find_and_set, BB_MONKEY_CURRENT_PRESS_TARGET, /obj/structure/desk_bell, 2)
|
|
else if(prob(50))
|
|
controller.queue_behavior(/datum/ai_behavior/use_on_object, BB_MONKEY_CURRENT_PRESS_TARGET)
|
|
return SUBTREE_RETURN_FINISH_PLANNING
|
|
|
|
if(!controller.blackboard[BB_MONKEY_CURRENT_GIVE_TARGET])
|
|
controller.queue_behavior(/datum/ai_behavior/find_and_set/pawn_must_hold_item, BB_MONKEY_CURRENT_GIVE_TARGET, /mob/living, 2)
|
|
else if(prob(30))
|
|
controller.queue_behavior(/datum/ai_behavior/give, BB_MONKEY_CURRENT_GIVE_TARGET)
|
|
return SUBTREE_RETURN_FINISH_PLANNING
|
|
|