Nuclide
Software Development Kit for id Technology (BETA)
Schedule.h
1/*
2 * Copyright (c) 2016-2024 Vera Visions LLC.
3 *
4 * Permission to use, copy, modify, and distribute this software for any
5 * purpose with or without fee is hereby granted, provided that the above
6 * copyright notice and this permission notice appear in all copies.
7 *
8 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12 * WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
13 * IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
14 * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15*/
16
89class
91{
92public:
93 void ncSchedule(void);
94
95 /* overrides */
96 virtual void OnRemoveEntity(void);
97
99 nonvirtual ncSchedule CreateSchedule(ncActor targetActor, string scheduleDecl);
100 nonvirtual void SetTarget(ncEntity target);
101 nonvirtual ncEntity GetTarget(void);
102 nonvirtual void Think(void);
103 nonvirtual bool ProgressOnMovement(void);
104 nonvirtual void SetFailSchedule(string);
105
106private:
107 string m_name;
108 int m_taskCount;
109 int m_onTask;
110 ncActor m_controllingActor;
111 ncDict m_scheduleDecl;
112 ncEntity m_eTarget;
113 bool m_inProgress;
114 bool m_bProgressOnMovement;
115 string m_failSchedule;
116
117 nonvirtual bool AssignActor(ncActor targetActor);
118 nonvirtual void Advance(void);
119 nonvirtual void AdvanceLater(float timeDelta);
120 nonvirtual void Cancel(void);
121 nonvirtual void Message(string);
122 nonvirtual bool InProgress(void);
123};
124 // end of npc_schedules
126
This entity class represents an object with choreographed/free-form movement.
Definition: Actor.h:93
This class is responsible for handling groups of key/value pairs.
Definition: Dict.h:35
ncEntity is the lowest of the user-accessible entity class.
Definition: Entity.h:75
This class is responsible for handling core entity functionality.
Definition: IO.h:78
Definition: Schedule.h:91