1
2
3
4
5
6
7
8
9
10
11
12 package cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands;import java.util.*;import javax.vecmath.*;import cz.cuni.amis.pogamut.base.communication.messages.*;import cz.cuni.amis.pogamut.base.communication.worldview.*;import cz.cuni.amis.pogamut.base.communication.worldview.event.*;import cz.cuni.amis.pogamut.base.communication.worldview.object.*;import cz.cuni.amis.pogamut.multi.communication.worldview.object.*;import cz.cuni.amis.pogamut.base.communication.translator.event.*;import cz.cuni.amis.pogamut.multi.communication.translator.event.*;import cz.cuni.amis.pogamut.base3d.worldview.object.*;import cz.cuni.amis.pogamut.base3d.worldview.object.event.*;import cz.cuni.amis.pogamut.ut2004.communication.messages.*;import cz.cuni.amis.pogamut.ut2004.communication.worldview.objects.*;import cz.cuni.amis.pogamut.ut2004multi.communication.worldview.objects.*;import cz.cuni.amis.pogamut.ut2004.communication.translator.itemdescriptor.*;import cz.cuni.amis.pogamut.ut2004.communication.messages.ItemType.Category;import cz.cuni.amis.pogamut.unreal.communication.messages.UnrealId;import cz.cuni.amis.utils.exception.*;import cz.cuni.amis.pogamut.base.communication.translator.event.IWorldObjectUpdateResult.Result;import cz.cuni.amis.utils.SafeEquals;import cz.cuni.amis.pogamut.base.agent.*;import cz.cuni.amis.pogamut.multi.agent.*;import cz.cuni.amis.pogamut.multi.communication.worldview.property.*;import cz.cuni.amis.pogamut.ut2004multi.communication.worldview.property.*;import cz.cuni.amis.utils.token.*;import cz.cuni.amis.utils.*;
13
14
15
16
17
18
19
20 public class SetWalk
21 extends CommandMessage
22 {
23
24
25
26 public static final String PROTOTYPE =
27 " {Walk False} {WalkAnim text} {RunAnim text} ";
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48 public SetWalk(
49 Boolean Walk, String WalkAnim, String RunAnim
50 ) {
51
52 this.Walk = Walk;
53
54 this.WalkAnim = WalkAnim;
55
56 this.RunAnim = RunAnim;
57
58 }
59
60
61
62
63
64
65
66
67
68
69
70
71 public SetWalk() {
72 }
73
74
75
76
77
78
79
80 public SetWalk(SetWalk original) {
81
82 this.Walk = original.Walk;
83
84 this.WalkAnim = original.WalkAnim;
85
86 this.RunAnim = original.RunAnim;
87
88 }
89
90
91
92
93
94
95 protected
96 Boolean Walk =
97
98 null
99 ;
100
101
102
103
104
105
106
107
108 public Boolean isWalk()
109
110 {
111 return
112 Walk;
113 }
114
115
116
117
118
119
120
121
122
123 public SetWalk
124 setWalk(Boolean Walk)
125
126 {
127 this.Walk = Walk;
128 return this;
129 }
130
131
132
133
134
135
136 protected
137 String WalkAnim =
138
139 null
140 ;
141
142
143
144
145
146
147
148
149 public String getWalkAnim()
150
151 {
152 return
153 WalkAnim;
154 }
155
156
157
158
159
160
161
162
163
164 public SetWalk
165 setWalkAnim(String WalkAnim)
166
167 {
168 this.WalkAnim = WalkAnim;
169 return this;
170 }
171
172
173
174
175
176
177 protected
178 String RunAnim =
179
180 null
181 ;
182
183
184
185
186
187
188
189
190 public String getRunAnim()
191
192 {
193 return
194 RunAnim;
195 }
196
197
198
199
200
201
202
203
204
205 public SetWalk
206 setRunAnim(String RunAnim)
207
208 {
209 this.RunAnim = RunAnim;
210 return this;
211 }
212
213 public String toString() {
214 return toMessage();
215 }
216
217 public String toHtmlString() {
218 return super.toString() + "[<br/>" +
219
220 "<b>Walk</b> = " +
221 String.valueOf(isWalk()
222 ) +
223 " <br/> " +
224
225 "<b>WalkAnim</b> = " +
226 String.valueOf(getWalkAnim()
227 ) +
228 " <br/> " +
229
230 "<b>RunAnim</b> = " +
231 String.valueOf(getRunAnim()
232 ) +
233 " <br/> " +
234
235 "<br/>]"
236 ;
237 }
238
239 public String toMessage() {
240 StringBuffer buf = new StringBuffer();
241 buf.append("SETWALK");
242
243 if (Walk != null) {
244 buf.append(" {Walk " + Walk + "}");
245 }
246
247 if (WalkAnim != null) {
248 buf.append(" {WalkAnim " + WalkAnim + "}");
249 }
250
251 if (RunAnim != null) {
252 buf.append(" {RunAnim " + RunAnim + "}");
253 }
254
255 return buf.toString();
256 }
257
258
259
260
261
262 }
263