You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-23 15:16:17 +00:00
[Core] Add scalar versions of Vector* min/max/clamp/snap(ped)
Convenience for a number of cases operating on single values
This commit is contained in:
@@ -163,9 +163,9 @@ void OccluderInstance3DGizmoPlugin::set_handle(const EditorNode3DGizmo *p_gizmo,
|
||||
if (p_id == 2) {
|
||||
Vector2 s = Vector2(intersection.x, intersection.y) * 2.0f;
|
||||
if (snap_enabled) {
|
||||
s = s.snapped(Vector2(snap, snap));
|
||||
s = s.snappedf(snap);
|
||||
}
|
||||
s = s.max(Vector2(0.001, 0.001));
|
||||
s = s.maxf(0.001);
|
||||
qo->set_size(s);
|
||||
} else {
|
||||
float d = intersection[p_id];
|
||||
|
||||
Reference in New Issue
Block a user