1 /**
2 General purpose proximity-detection node.
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.proximitygroup;
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.spatial;
24 import godot.node;
25 /**
26 General purpose proximity-detection node.
27 
28 
29 */
30 @GodotBaseClass struct ProximityGroup
31 {
32 	enum string _GODOT_internal_name = "ProximityGroup";
33 public:
34 @nogc nothrow:
35 	union { godot_object _godot_object; Spatial _GODOT_base; }
36 	alias _GODOT_base this;
37 	alias BaseClasses = AliasSeq!(typeof(_GODOT_base), typeof(_GODOT_base).BaseClasses);
38 	package(godot) __gshared bool _classBindingInitialized = false;
39 	package(godot) static struct _classBinding
40 	{
41 		__gshared:
42 		@GodotName("set_group_name") GodotMethod!(void, String) setGroupName;
43 		@GodotName("get_group_name") GodotMethod!(String) getGroupName;
44 		@GodotName("set_dispatch_mode") GodotMethod!(void, long) setDispatchMode;
45 		@GodotName("get_dispatch_mode") GodotMethod!(ProximityGroup.DispatchMode) getDispatchMode;
46 		@GodotName("set_grid_radius") GodotMethod!(void, Vector3) setGridRadius;
47 		@GodotName("get_grid_radius") GodotMethod!(Vector3) getGridRadius;
48 		@GodotName("broadcast") GodotMethod!(void, String, Variant) broadcast;
49 		@GodotName("_proximity_group_broadcast") GodotMethod!(void, String, Variant) _proximityGroupBroadcast;
50 	}
51 	bool opEquals(in ProximityGroup other) const { return _godot_object.ptr is other._godot_object.ptr; }
52 	ProximityGroup opAssign(T : typeof(null))(T n) { _godot_object.ptr = null; }
53 	bool opEquals(typeof(null) n) const { return _godot_object.ptr is null; }
54 	mixin baseCasts;
55 	static ProximityGroup _new()
56 	{
57 		static godot_class_constructor constructor;
58 		if(constructor is null) constructor = _godot_api.godot_get_class_constructor("ProximityGroup");
59 		if(constructor is null) return typeof(this).init;
60 		return cast(ProximityGroup)(constructor());
61 	}
62 	@disable new(size_t s);
63 	/// 
64 	enum DispatchMode : int
65 	{
66 		/**
67 		
68 		*/
69 		modeProxy = 0,
70 		/**
71 		
72 		*/
73 		modeSignal = 1,
74 	}
75 	/// 
76 	enum Constants : int
77 	{
78 		modeProxy = 0,
79 		modeSignal = 1,
80 	}
81 	/**
82 	
83 	*/
84 	void setGroupName(StringArg0)(in StringArg0 name)
85 	{
86 		checkClassBinding!(typeof(this))();
87 		ptrcall!(void)(_classBinding.setGroupName, _godot_object, name);
88 	}
89 	/**
90 	
91 	*/
92 	String getGroupName() const
93 	{
94 		checkClassBinding!(typeof(this))();
95 		return ptrcall!(String)(_classBinding.getGroupName, _godot_object);
96 	}
97 	/**
98 	
99 	*/
100 	void setDispatchMode(in long mode)
101 	{
102 		checkClassBinding!(typeof(this))();
103 		ptrcall!(void)(_classBinding.setDispatchMode, _godot_object, mode);
104 	}
105 	/**
106 	
107 	*/
108 	ProximityGroup.DispatchMode getDispatchMode() const
109 	{
110 		checkClassBinding!(typeof(this))();
111 		return ptrcall!(ProximityGroup.DispatchMode)(_classBinding.getDispatchMode, _godot_object);
112 	}
113 	/**
114 	
115 	*/
116 	void setGridRadius(in Vector3 radius)
117 	{
118 		checkClassBinding!(typeof(this))();
119 		ptrcall!(void)(_classBinding.setGridRadius, _godot_object, radius);
120 	}
121 	/**
122 	
123 	*/
124 	Vector3 getGridRadius() const
125 	{
126 		checkClassBinding!(typeof(this))();
127 		return ptrcall!(Vector3)(_classBinding.getGridRadius, _godot_object);
128 	}
129 	/**
130 	
131 	*/
132 	void broadcast(StringArg0, VariantArg1)(in StringArg0 name, in VariantArg1 parameters)
133 	{
134 		checkClassBinding!(typeof(this))();
135 		ptrcall!(void)(_classBinding.broadcast, _godot_object, name, parameters);
136 	}
137 	/**
138 	
139 	*/
140 	void _proximityGroupBroadcast(StringArg0, VariantArg1)(in StringArg0 name, in VariantArg1 params)
141 	{
142 		Array _GODOT_args = Array.empty_array;
143 		_GODOT_args.append(name);
144 		_GODOT_args.append(params);
145 		String _GODOT_method_name = String("_proximity_group_broadcast");
146 		this.callv(_GODOT_method_name, _GODOT_args);
147 	}
148 	/**
149 	
150 	*/
151 	@property String groupName()
152 	{
153 		return getGroupName();
154 	}
155 	/// ditto
156 	@property void groupName(String v)
157 	{
158 		setGroupName(v);
159 	}
160 	/**
161 	
162 	*/
163 	@property ProximityGroup.DispatchMode dispatchMode()
164 	{
165 		return getDispatchMode();
166 	}
167 	/// ditto
168 	@property void dispatchMode(long v)
169 	{
170 		setDispatchMode(v);
171 	}
172 	/**
173 	
174 	*/
175 	@property Vector3 gridRadius()
176 	{
177 		return getGridRadius();
178 	}
179 	/// ditto
180 	@property void gridRadius(Vector3 v)
181 	{
182 		setGridRadius(v);
183 	}
184 }