2 * Copyright (C) Volition, Inc. 1999. All rights reserved.
4 * All source code herein is the property of Volition, Inc. You may not sell
5 * or otherwise commercially exploit the source or things you created based on
10 * $Logfile: /Freespace2/code/FRED2/ShipGoalsDlg.h $
15 * Initial orders editor dialog box handling code. This dialog is used for both
16 * ship and wing initial orders, and can support more if need be without modification.
19 * Revision 1.2 2002/06/09 04:41:15 relnev
20 * added copyright header
22 * Revision 1.1.1.1 2002/05/03 03:28:12 root
26 * 2 10/07/98 6:28p Dave
27 * Initial checkin. Renamed all relevant stuff to be Fred2 instead of
28 * Fred. Globalized mission and campaign file extensions. Removed Silent
29 * Threat specific code.
31 * 1 10/07/98 3:01p Dave
33 * 1 10/07/98 3:00p Dave
35 * 13 8/26/97 4:18p Hoffoss
36 * Added error checking to initial orders dialog when ok is clicked.
38 * 12 7/30/97 12:31p Hoffoss
39 * Made improvements to ship goals editor (initial orders) to disallow
42 * 11 5/30/97 4:50p Hoffoss
43 * Added code to allow marked ship editing of data in child dialogs of
46 * 10 3/10/97 5:37p Hoffoss
47 * fixed bug in dock goal selection.
49 * 9 3/03/97 4:32p Hoffoss
50 * Initial orders supports new docking stuff Allender added.
52 * 8 2/17/97 5:28p Hoffoss
53 * Checked RCS headers, added them were missing, changing description to
54 * something better, etc where needed.
59 #include "management.h"
61 #ifndef _SHIPGOALSDLG_H
62 #define _SHIPGOALSDLG_H
64 #define ED_MAX_GOALS 10
66 /////////////////////////////////////////////////////////////////////////////
67 // ShipGoalsDlg dialog
69 class ShipGoalsDlg : public CDialog
73 int verify_orders(int ship = -1);
74 void initialize_multi();
77 void initialize(ai_goal *goals, int ship = cur_ship);
78 ShipGoalsDlg(CWnd* pParent = NULL); // standard constructor
80 int self_ship, self_wing;
81 int m_behavior[ED_MAX_GOALS];
82 int m_object[ED_MAX_GOALS];
83 int m_priority[ED_MAX_GOALS];
84 int m_subsys[ED_MAX_GOALS];
85 int m_dock2[ED_MAX_GOALS];
86 int m_data[ED_MAX_GOALS];
88 CComboBox *m_behavior_box[ED_MAX_GOALS];
89 CComboBox *m_object_box[ED_MAX_GOALS];
90 CComboBox *m_subsys_box[ED_MAX_GOALS];
91 CComboBox *m_dock2_box[ED_MAX_GOALS];
92 CComboBox *m_priority_box[ED_MAX_GOALS];
95 //{{AFX_DATA(ShipGoalsDlg)
96 enum { IDD = IDD_SHIP_GOALS_EDITOR };
100 // ClassWizard generated virtual function overrides
101 //{{AFX_VIRTUAL(ShipGoalsDlg)
103 virtual BOOL Create(LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext = NULL);
105 virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
111 // Generated message map functions
112 //{{AFX_MSG(ShipGoalsDlg)
113 virtual BOOL OnInitDialog();
114 afx_msg void OnSelchangeBehavior1();
115 afx_msg void OnSelchangeBehavior2();
116 afx_msg void OnSelchangeBehavior3();
117 afx_msg void OnSelchangeBehavior4();
118 afx_msg void OnSelchangeBehavior5();
119 afx_msg void OnSelchangeBehavior6();
120 afx_msg void OnSelchangeBehavior7();
121 afx_msg void OnSelchangeBehavior8();
122 afx_msg void OnSelchangeBehavior9();
123 afx_msg void OnSelchangeBehavior10();
124 afx_msg void OnSelchangeObject1();
125 afx_msg void OnSelchangeObject2();
126 afx_msg void OnSelchangeObject3();
127 afx_msg void OnSelchangeObject4();
128 afx_msg void OnSelchangeObject5();
129 afx_msg void OnSelchangeObject6();
130 afx_msg void OnSelchangeObject7();
131 afx_msg void OnSelchangeObject8();
132 afx_msg void OnSelchangeObject9();
133 afx_msg void OnSelchangeObject10();
135 DECLARE_MESSAGE_MAP()
138 void set_item(int item, int init = 0);
139 void update_item(int item, int multi = 0);
140 void set_object(int item);
145 extern char *goal_behaviors[];