1 /**
2 
3 
4 Copyright:
5 Copyright (c) 2007-2018 Juan Linietsky, Ariel Manzur.  
6 Copyright (c) 2014-2018 Godot Engine contributors (cf. AUTHORS.md)  
7 Copyright (c) 2017-2018 Godot-D contributors  
8 
9 License: $(LINK2 https://opensource.org/licenses/MIT, MIT License)
10 
11 
12 */
13 module godot.animationnodestatemachinetransition;
14 import std.meta : AliasSeq, staticIndexOf;
15 import std.traits : Unqual;
16 import godot.d.meta;
17 import godot.core;
18 import godot.c;
19 import godot.d.bind;
20 import godot.d.reference;
21 import godot.object;
22 import godot.classdb;
23 import godot.resource;
24 import godot.reference;
25 /**
26 
27 */
28 @GodotBaseClass struct AnimationNodeStateMachineTransition
29 {
30 	enum string _GODOT_internal_name = "AnimationNodeStateMachineTransition";
31 public:
32 @nogc nothrow:
33 	union { godot_object _godot_object; Resource _GODOT_base; }
34 	alias _GODOT_base this;
35 	alias BaseClasses = AliasSeq!(typeof(_GODOT_base), typeof(_GODOT_base).BaseClasses);
36 	package(godot) __gshared bool _classBindingInitialized = false;
37 	package(godot) static struct _classBinding
38 	{
39 		__gshared:
40 		@GodotName("set_switch_mode") GodotMethod!(void, long) setSwitchMode;
41 		@GodotName("get_switch_mode") GodotMethod!(AnimationNodeStateMachineTransition.SwitchMode) getSwitchMode;
42 		@GodotName("set_auto_advance") GodotMethod!(void, bool) setAutoAdvance;
43 		@GodotName("has_auto_advance") GodotMethod!(bool) hasAutoAdvance;
44 		@GodotName("set_advance_condition") GodotMethod!(void, String) setAdvanceCondition;
45 		@GodotName("get_advance_condition") GodotMethod!(String) getAdvanceCondition;
46 		@GodotName("set_xfade_time") GodotMethod!(void, double) setXfadeTime;
47 		@GodotName("get_xfade_time") GodotMethod!(double) getXfadeTime;
48 		@GodotName("set_disabled") GodotMethod!(void, bool) setDisabled;
49 		@GodotName("is_disabled") GodotMethod!(bool) isDisabled;
50 		@GodotName("set_priority") GodotMethod!(void, long) setPriority;
51 		@GodotName("get_priority") GodotMethod!(long) getPriority;
52 	}
53 	bool opEquals(in AnimationNodeStateMachineTransition other) const { return _godot_object.ptr is other._godot_object.ptr; }
54 	AnimationNodeStateMachineTransition opAssign(T : typeof(null))(T n) { _godot_object.ptr = null; }
55 	bool opEquals(typeof(null) n) const { return _godot_object.ptr is null; }
56 	mixin baseCasts;
57 	static AnimationNodeStateMachineTransition _new()
58 	{
59 		static godot_class_constructor constructor;
60 		if(constructor is null) constructor = _godot_api.godot_get_class_constructor("AnimationNodeStateMachineTransition");
61 		if(constructor is null) return typeof(this).init;
62 		return cast(AnimationNodeStateMachineTransition)(constructor());
63 	}
64 	@disable new(size_t s);
65 	/// 
66 	enum SwitchMode : int
67 	{
68 		/**
69 		
70 		*/
71 		switchModeImmediate = 0,
72 		/**
73 		
74 		*/
75 		switchModeSync = 1,
76 		/**
77 		
78 		*/
79 		switchModeAtEnd = 2,
80 	}
81 	/// 
82 	enum Constants : int
83 	{
84 		switchModeImmediate = 0,
85 		switchModeSync = 1,
86 		switchModeAtEnd = 2,
87 	}
88 	/**
89 	
90 	*/
91 	void setSwitchMode(in long mode)
92 	{
93 		checkClassBinding!(typeof(this))();
94 		ptrcall!(void)(_classBinding.setSwitchMode, _godot_object, mode);
95 	}
96 	/**
97 	
98 	*/
99 	AnimationNodeStateMachineTransition.SwitchMode getSwitchMode() const
100 	{
101 		checkClassBinding!(typeof(this))();
102 		return ptrcall!(AnimationNodeStateMachineTransition.SwitchMode)(_classBinding.getSwitchMode, _godot_object);
103 	}
104 	/**
105 	
106 	*/
107 	void setAutoAdvance(in bool auto_advance)
108 	{
109 		checkClassBinding!(typeof(this))();
110 		ptrcall!(void)(_classBinding.setAutoAdvance, _godot_object, auto_advance);
111 	}
112 	/**
113 	
114 	*/
115 	bool hasAutoAdvance() const
116 	{
117 		checkClassBinding!(typeof(this))();
118 		return ptrcall!(bool)(_classBinding.hasAutoAdvance, _godot_object);
119 	}
120 	/**
121 	
122 	*/
123 	void setAdvanceCondition(StringArg0)(in StringArg0 name)
124 	{
125 		checkClassBinding!(typeof(this))();
126 		ptrcall!(void)(_classBinding.setAdvanceCondition, _godot_object, name);
127 	}
128 	/**
129 	
130 	*/
131 	String getAdvanceCondition() const
132 	{
133 		checkClassBinding!(typeof(this))();
134 		return ptrcall!(String)(_classBinding.getAdvanceCondition, _godot_object);
135 	}
136 	/**
137 	
138 	*/
139 	void setXfadeTime(in double secs)
140 	{
141 		checkClassBinding!(typeof(this))();
142 		ptrcall!(void)(_classBinding.setXfadeTime, _godot_object, secs);
143 	}
144 	/**
145 	
146 	*/
147 	double getXfadeTime() const
148 	{
149 		checkClassBinding!(typeof(this))();
150 		return ptrcall!(double)(_classBinding.getXfadeTime, _godot_object);
151 	}
152 	/**
153 	
154 	*/
155 	void setDisabled(in bool disabled)
156 	{
157 		checkClassBinding!(typeof(this))();
158 		ptrcall!(void)(_classBinding.setDisabled, _godot_object, disabled);
159 	}
160 	/**
161 	
162 	*/
163 	bool isDisabled() const
164 	{
165 		checkClassBinding!(typeof(this))();
166 		return ptrcall!(bool)(_classBinding.isDisabled, _godot_object);
167 	}
168 	/**
169 	
170 	*/
171 	void setPriority(in long priority)
172 	{
173 		checkClassBinding!(typeof(this))();
174 		ptrcall!(void)(_classBinding.setPriority, _godot_object, priority);
175 	}
176 	/**
177 	
178 	*/
179 	long getPriority() const
180 	{
181 		checkClassBinding!(typeof(this))();
182 		return ptrcall!(long)(_classBinding.getPriority, _godot_object);
183 	}
184 	/**
185 	
186 	*/
187 	@property AnimationNodeStateMachineTransition.SwitchMode switchMode()
188 	{
189 		return getSwitchMode();
190 	}
191 	/// ditto
192 	@property void switchMode(long v)
193 	{
194 		setSwitchMode(v);
195 	}
196 	/**
197 	
198 	*/
199 	@property bool autoAdvance()
200 	{
201 		return hasAutoAdvance();
202 	}
203 	/// ditto
204 	@property void autoAdvance(bool v)
205 	{
206 		setAutoAdvance(v);
207 	}
208 	/**
209 	
210 	*/
211 	@property String advanceCondition()
212 	{
213 		return getAdvanceCondition();
214 	}
215 	/// ditto
216 	@property void advanceCondition(String v)
217 	{
218 		setAdvanceCondition(v);
219 	}
220 	/**
221 	
222 	*/
223 	@property double xfadeTime()
224 	{
225 		return getXfadeTime();
226 	}
227 	/// ditto
228 	@property void xfadeTime(double v)
229 	{
230 		setXfadeTime(v);
231 	}
232 	/**
233 	
234 	*/
235 	@property long priority()
236 	{
237 		return getPriority();
238 	}
239 	/// ditto
240 	@property void priority(long v)
241 	{
242 		setPriority(v);
243 	}
244 	/**
245 	
246 	*/
247 	@property bool disabled()
248 	{
249 		return isDisabled();
250 	}
251 	/// ditto
252 	@property void disabled(bool v)
253 	{
254 		setDisabled(v);
255 	}
256 }