Style: Cleanup uses of double spaces between words

Or after punctuation. Tried to leave third-party stuff alone, unless it has
been heavily modified for Godot.

(cherry picked from commit c1c76850cb)
This commit is contained in:
Rémi Verschelde 2021-06-07 10:17:32 +02:00
parent b449380235
commit 80e1585a6e
No known key found for this signature in database
GPG Key ID: C3336907360768E1
19 changed files with 30 additions and 81 deletions

View File

@ -112,7 +112,7 @@ Error QuickHull::build(const Vector<Vector3> &p_points, Geometry::MeshData &r_me
}
}
//fourth vertex is the one most further away from the plane
//fourth vertex is the one most further away from the plane
{
real_t maxd = 0;

View File

@ -829,7 +829,7 @@
Anchors the right edge of the node to the origin, the center or the end of its parent control. It changes how the right margin updates when the node moves or changes size. You can use one of the [enum Anchor] constants for convenience.
</member>
<member name="anchor_top" type="float" setter="_set_anchor" getter="get_anchor" default="0.0">
Anchors the top edge of the node to the origin, the center or the end of its parent control. It changes how the top margin updates when the node moves or changes size. You can use one of the [enum Anchor] constants for convenience.
Anchors the top edge of the node to the origin, the center or the end of its parent control. It changes how the top margin updates when the node moves or changes size. You can use one of the [enum Anchor] constants for convenience.
</member>
<member name="focus_mode" type="int" setter="set_focus_mode" getter="get_focus_mode" enum="Control.FocusMode" default="0">
The focus access mode for the control (None, Click or All). Only one Control can be focused at the same time, and it will receive keyboard signals.
@ -841,7 +841,7 @@
Tells Godot which node it should give keyboard focus to if the user presses the left arrow on the keyboard or left on a gamepad by default. You can change the key by editing the [code]ui_left[/code] input action. The node must be a [Control]. If this property is not set, Godot will give focus to the closest [Control] to the left of this one.
</member>
<member name="focus_neighbour_right" type="NodePath" setter="set_focus_neighbour" getter="get_focus_neighbour" default="NodePath(&quot;&quot;)">
Tells Godot which node it should give keyboard focus to if the user presses the right arrow on the keyboard or right on a gamepad by default. You can change the key by editing the [code]ui_right[/code] input action. The node must be a [Control]. If this property is not set, Godot will give focus to the closest [Control] to the bottom of this one.
Tells Godot which node it should give keyboard focus to if the user presses the right arrow on the keyboard or right on a gamepad by default. You can change the key by editing the [code]ui_right[/code] input action. The node must be a [Control]. If this property is not set, Godot will give focus to the closest [Control] to the bottom of this one.
</member>
<member name="focus_neighbour_top" type="NodePath" setter="set_focus_neighbour" getter="get_focus_neighbour" default="NodePath(&quot;&quot;)">
Tells Godot which node it should give keyboard focus to if the user presses the top arrow on the keyboard or top on a gamepad by default. You can change the key by editing the [code]ui_top[/code] input action. The node must be a [Control]. If this property is not set, Godot will give focus to the closest [Control] to the bottom of this one.

View File

@ -24,7 +24,7 @@
</methods>
<members>
<member name="custom_aabb" type="AABB" setter="set_custom_aabb" getter="get_custom_aabb" default="AABB( 0, 0, 0, 0, 0, 0 )">
Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful to avoid unexpected culling when using a shader to offset vertices.
Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful to avoid unexpected culling when using a shader to offset vertices.
</member>
<member name="flip_faces" type="bool" setter="set_flip_faces" getter="get_flip_faces" default="false">
If set, the order of the vertices in each triangle are reversed resulting in the backside of the mesh being drawn.

View File

@ -1681,61 +1681,10 @@ void SkeletonSpatialGizmoPlugin::redraw(EditorSpatialGizmo *p_gizmo) {
surface_tool->add_color(bonecolor);
surface_tool->add_vertex(points[(j + 1) % 4]);
}
/*
bones[0]=parent;
surface_tool->add_bones(bones);
surface_tool->add_weights(weights);
surface_tool->add_color(Color(0.4,1,0.4,0.4));
surface_tool->add_vertex(v0);
bones[0]=i;
surface_tool->add_bones(bones);
surface_tool->add_weights(weights);
surface_tool->add_color(Color(0.4,1,0.4,0.4));
surface_tool->add_vertex(v1);
*/
} else {
grests.write[i] = skel->get_bone_rest(i);
bones.write[0] = i;
}
/*
Transform t = grests[i];
t.orthonormalize();
for (int i=0;i<6;i++) {
Vector3 face_points[4];
for (int j=0;j<4;j++) {
float v[3];
v[0]=1.0;
v[1]=1-2*((j>>1)&1);
v[2]=v[1]*(1-2*(j&1));
for (int k=0;k<3;k++) {
if (i<3)
face_points[j][(i+k)%3]=v[k]*(i>=3?-1:1);
else
face_points[3-j][(i+k)%3]=v[k]*(i>=3?-1:1);
}
}
for(int j=0;j<4;j++) {
surface_tool->add_bones(bones);
surface_tool->add_weights(weights);
surface_tool->add_color(Color(1.0,0.4,0.4,0.4));
surface_tool->add_vertex(t.xform(face_points[j]*0.04));
surface_tool->add_bones(bones);
surface_tool->add_weights(weights);
surface_tool->add_color(Color(1.0,0.4,0.4,0.4));
surface_tool->add_vertex(t.xform(face_points[(j+1)%4]*0.04));
}
}
*/
}
Ref<ArrayMesh> m = surface_tool->commit();

View File

@ -13,7 +13,7 @@
# There should be no need to change anything below this line.
# Canonicalize by recursively following every symlink in every component of the
# specified filename. This should reproduce the results of the GNU version of
# specified filename. This should reproduce the results of the GNU version of
# readlink with the -f option.
#
# Reference: http://stackoverflow.com/questions/1055671/how-can-i-get-the-behavior-of-gnus-readlink-f-on-a-mac

View File

@ -460,7 +460,7 @@ real_t SpaceBullet::get_param(PhysicsServer::SpaceParameter p_param) {
case PhysicsServer::SPACE_PARAM_BODY_ANGULAR_VELOCITY_DAMP_RATIO:
case PhysicsServer::SPACE_PARAM_CONSTRAINT_DEFAULT_BIAS:
default:
WARN_PRINTS("The SpaceBullet doesn't support this get parameter (" + itos(p_param) + "), 0 is returned.");
WARN_PRINT("The SpaceBullet doesn't support this get parameter (" + itos(p_param) + "), 0 is returned.");
return 0.f;
}
}

View File

@ -1136,8 +1136,8 @@ HashMap<int, R> FBXMeshData::extract_per_vertex_data(
}
const int vertex_index = get_vertex_from_polygon_vertex(p_mesh_indices, polygon_vertex_index);
ERR_FAIL_COND_V_MSG(vertex_index < 0, (HashMap<int, R>()), "FBX file corrupted: #ERR8");
ERR_FAIL_COND_V_MSG(vertex_index >= p_vertex_count, (HashMap<int, R>()), "FBX file seems corrupted: #ERR9.")
ERR_FAIL_COND_V_MSG(p_mapping_data.index[polygon_vertex_index] < 0, (HashMap<int, R>()), "FBX file seems corrupted: #ERR10.")
ERR_FAIL_COND_V_MSG(vertex_index >= p_vertex_count, (HashMap<int, R>()), "FBX file seems corrupted: #ERR9.")
ERR_FAIL_COND_V_MSG(p_mapping_data.index[polygon_vertex_index] < 0, (HashMap<int, R>()), "FBX file seems corrupted: #ERR10.")
ERR_FAIL_COND_V_MSG(p_mapping_data.index[polygon_vertex_index] >= (int)p_mapping_data.data.size(), (HashMap<int, R>()), "FBX file seems corrupted: #ERR11.")
aggregate_vertex_data[vertex_index].push_back({ polygon_id, p_mapping_data.data[p_mapping_data.index[polygon_vertex_index]] });
}

View File

@ -435,7 +435,7 @@ namespace Godot
#if DEBUG
if (!normal.IsNormalized())
{
throw new ArgumentException("Argument is not normalized", nameof(normal));
throw new ArgumentException("Argument is not normalized", nameof(normal));
}
#endif
return 2 * Dot(normal) * normal - this;

View File

@ -419,7 +419,7 @@ namespace Godot
#if DEBUG
if (!normal.IsNormalized())
{
throw new ArgumentException("Argument is not normalized", nameof(normal));
throw new ArgumentException("Argument is not normalized", nameof(normal));
}
#endif
return 2.0f * Dot(normal) * normal - this;
@ -437,7 +437,7 @@ namespace Godot
#if DEBUG
if (!axis.IsNormalized())
{
throw new ArgumentException("Argument is not normalized", nameof(axis));
throw new ArgumentException("Argument is not normalized", nameof(axis));
}
#endif
return new Basis(axis, phi).Xform(this);

View File

@ -302,7 +302,7 @@ void VideoStreamPlaybackTheora::set_file(const String &p_file) {
}
}
/* and now we have it all. initialize decoders */
/* And now we have it all. Initialize decoders. */
if (theora_p) {
td = th_decode_alloc(&ti, ts);
px_fmt = ti.pixel_fmt;
@ -482,10 +482,10 @@ void VideoStreamPlaybackTheora::update(float p_delta) {
//printf("frame time %f, play time %f, ready %i\n", (float)videobuf_time, get_time(), videobuf_ready);
/* is it already too old to be useful? This is only actually
useful cosmetically after a SIGSTOP. Note that we have to
/* is it already too old to be useful? This is only actually
useful cosmetically after a SIGSTOP. Note that we have to
decode the frame even if we don't show it (for now) due to
keyframing. Soon enough libtheora will be able to deal
keyframing. Soon enough libtheora will be able to deal
with non-keyframe seeks. */
if (videobuf_time >= get_time()) {

View File

@ -4,7 +4,7 @@
A script implemented in the Visual Script programming environment.
</brief_description>
<description>
A script implemented in the Visual Script programming environment. The script extends the functionality of all objects that instance it.
A script implemented in the Visual Script programming environment. The script extends the functionality of all objects that instance it.
[method Object.set_script] extends an existing object, if that object's class matches one of the script's base classes.
You are most likely to use this class via the Visual Script editor or when writing plugins for it.
</description>

View File

@ -1,7 +1,7 @@
@if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
@rem Gradle startup script for Windows
@rem Gradle startup script for Windows
@rem
@rem ##########################################################################
@ -75,7 +75,7 @@ if "%ERRORLEVEL%"=="0" goto mainEnd
:fail
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
rem the _cmd.exe /c_ return code!
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
exit /b 1
:mainEnd

View File

@ -6,7 +6,7 @@
<string name="text_button_resume_cellular">Resume download</string>
<string name="text_button_wifi_settings">Wi-Fi settings</string>
<string name="text_verifying_download">Verifying Download</string>
<string name="text_validation_complete">XAPK File Validation Complete. Select OK to exit.</string>
<string name="text_validation_complete">XAPK File Validation Complete. Select OK to exit.</string>
<string name="text_validation_failed">XAPK File Validation Failed.</string>
<string name="text_button_pause">Pause Download</string>
<string name="text_button_resume">Resume Download</string>

View File

@ -37,8 +37,8 @@
/*
The `config` section and fields are required and defined as follow:
- **name**: name of the plugin
- **binary_type**: can be either `local` or `remote`. The type affects the **binary** field
- **name**: name of the plugin.
- **binary_type**: can be either `local` or `remote`. The type affects the **binary** field.
- **binary**:
- if **binary_type** is `local`, then this should be the filename of the plugin `aar` file in the `res://android/plugins` directory (e.g: `MyPlugin.aar`).
- if **binary_type** is `remote`, then this should be a declaration for a remote gradle binary (e.g: "org.godot.example:my-plugin:0.0.0").

View File

@ -102,7 +102,7 @@ void ContextGL_Windows::swap_buffers() {
if (vsync_via_compositor_now != vsync_via_compositor) {
// The previous frame had a different operating mode than this
// frame. Set the 'vsync_via_compositor' member variable and the
// frame. Set the 'vsync_via_compositor' member variable and the
// OpenGL swap interval to their proper values.
set_use_vsync(true);
}

View File

@ -33,7 +33,7 @@
void GridContainer::_notification(int p_what) {
switch (p_what) {
case NOTIFICATION_SORT_CHILDREN: {
Map<int, int> col_minw; // Max of min_width of all controls in each col (indexed by col).
Map<int, int> col_minw; // Max of min_width of all controls in each col (indexed by col).
Map<int, int> row_minh; // Max of min_height of all controls in each row (indexed by row).
Set<int> col_expanded; // Columns which have the SIZE_EXPAND flag set.
Set<int> row_expanded; // Rows which have the SIZE_EXPAND flag set.

View File

@ -758,12 +758,12 @@ void SpatialMaterial::_update_shader() {
code += "\t\tfloat current_layer_depth = 0.0;\n";
code += "\t\tvec2 P = view_dir.xy * depth_scale;\n";
code += "\t\tvec2 delta = P / num_layers;\n";
code += "\t\tvec2 ofs = base_uv;\n";
code += "\t\tfloat depth = textureLod(texture_depth, ofs,0.0).r;\n";
code += "\t\tvec2 ofs = base_uv;\n";
code += "\t\tfloat depth = textureLod(texture_depth, ofs, 0.0).r;\n";
code += "\t\tfloat current_depth = 0.0;\n";
code += "\t\twhile(current_depth < depth) {\n";
code += "\t\t\tofs -= delta;\n";
code += "\t\t\tdepth = textureLod(texture_depth, ofs,0.0).r;\n";
code += "\t\t\tdepth = textureLod(texture_depth, ofs, 0.0).r;\n";
code += "\t\t\tcurrent_depth += layer_depth;\n";
code += "\t\t}\n";
code += "\t\tvec2 prev_ofs = ofs + delta;\n";

View File

@ -287,7 +287,7 @@ void Reverb::update_parameters() {
c.feedback = (room_offset + room_scale);
}
float auxdmp = params.damp / 2.0 + 0.5; //only half the range (0.5 .. 1.0 is enough)
float auxdmp = params.damp / 2.0 + 0.5; //only half the range (0.5 .. 1.0 is enough)
auxdmp *= auxdmp;
c.damp = expf(-2.0 * Math_PI * auxdmp * 10000 / params.mix_rate); // 0 .. 10khz

View File

@ -81,7 +81,7 @@ public:
//! temp_variables
//!@{
real_t m_currentLimitError; //! How much is violated this limit
real_t m_currentLimitError; //!< How much is violated this limit
int m_currentLimit; //!< 0=free, 1=at lo limit, 2=at hi limit
real_t m_accumulatedImpulse;
//!@}
@ -113,7 +113,7 @@ public:
return (m_enableMotor || m_currentLimit != 0);
}
//! calculates error
//! calculates error
/*!
calculates m_currentLimit and m_currentLimitError.
*/
@ -326,7 +326,7 @@ public:
return &m_angularLimits[index];
}
//! Retrieves the limit informacion
//! Retrieves the limit informacion
G6DOFTranslationalLimitMotorSW *getTranslationalLimitMotor() {
return &m_linearLimits;
}