Skip to content

Commit

Permalink
Cleanup uses of double spaces between words or after punctuation
Browse files Browse the repository at this point in the history
  • Loading branch information
akien-mga committed Jun 7, 2021
1 parent 08150dc commit 044b6a7
Show file tree
Hide file tree
Showing 28 changed files with 125 additions and 141 deletions.
2 changes: 1 addition & 1 deletion conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@
html_extra_path = ["robots.txt"]

# These paths are either relative to html_static_path
# or fully qualified paths (eg. https://...)
# or fully qualified paths (e.g. https://...)
html_css_files = [
"css/custom.css",
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,5 +75,5 @@ it at runtime.

::

ERROR: open_and_parse: Condition ' String::md5(md5.digest) != String::md5(md5d) ' is true. returned: ERR_FILE_CORRUPT
ERROR: open_and_parse: Condition "String::md5(md5.digest) != String::md5(md5d)" is true. Returning: ERR_FILE_CORRUPT
At: core/io/file_access_encrypted.cpp:103
10 changes: 5 additions & 5 deletions development/cpp/binding_to_external_libraries.rst
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,8 @@ this module:
env_tts = env.Clone()
env_tts.add_source_files(env.modules_sources, "*.cpp") # Add all cpp files to the build
You'll need to install the external library on your machine to get the .a library files. See the library's official
documentation for specific instructions on how to do this for your operation system. We've included the
You'll need to install the external library on your machine to get the .a library files. See the library's official
documentation for specific instructions on how to do this for your operation system. We've included the
installation commands for Linux below, for reference.

.. code-block:: shell
Expand All @@ -135,7 +135,7 @@ installation commands for Linux below, for reference.
Please be sure to check the licenses and terms of use.

The external library will also need to be installed inside your module to make the source
files accessible to the compiler, while also keeping the module code self-contained. The
files accessible to the compiler, while also keeping the module code self-contained. The
festival and speech_tools libraries can be installed from the modules/tts/ directory via
git using the following commands:

Expand All @@ -153,9 +153,9 @@ can link to them instead by adding them as submodules (from within the modules/t
git submodule add https://github.com/festvox/speech_tools
.. important::
Please note that Git submodules are not used in the Godot repository. If
Please note that Git submodules are not used in the Godot repository. If
you are developing a module to be merged into the main Godot repository, you should not
use submodules. If your module doesn't get merged in, you can always try to implement
use submodules. If your module doesn't get merged in, you can always try to implement
the external library as a GDNative C++ plugin.

To add include directories for the compiler to look at you can append it to the
Expand Down
2 changes: 1 addition & 1 deletion development/cpp/configuring_an_ide/code_blocks.rst
Original file line number Diff line number Diff line change
Expand Up @@ -126,4 +126,4 @@ Under **General Settings**, on the **Editor Settings** tab, under **Tab Options*
:figclass: figure-w480
:align: center

That's it. You're ready to start contributing to Godot using the Code::Blocks IDE. Remember to save the project file and the **Workspace**. If you run into any issues, ask for help in one of `Godot's community channels <https://godotengine.org/community>`__.
That's it. You're ready to start contributing to Godot using the Code::Blocks IDE. Remember to save the project file and the **Workspace**. If you run into any issues, ask for help in one of `Godot's community channels <https://godotengine.org/community>`__.
2 changes: 1 addition & 1 deletion development/cpp/custom_resource_format_loaders.rst
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ calls into ``std::istream``.
}
}
int uflow() {
return _file->eof_reached() ? EOF : _file->get_8();
return _file->eof_reached() ? EOF : _file->get_8();
}
private:
Expand Down
2 changes: 1 addition & 1 deletion development/file_formats/tscn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ heading. For example, a capsule collision shape looks like:

::

[sub_resource type="CapsuleShape" id=2]
[sub_resource type="CapsuleShape" id=2]

radius = 0.5
height = 3.0
Expand Down
22 changes: 11 additions & 11 deletions tutorials/2d/2d_sprite_animation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ Introduction
In this tutorial, you'll learn how to create 2D animated
characters with the AnimatedSprite class and the AnimationPlayer. Typically, when you create or download an animated character, it
will come in one of two ways: as individual images or as a single sprite sheet
containing all the animation's frames. Both can be animated in Godot with the AnimatedSprite class.
containing all the animation's frames. Both can be animated in Godot with the AnimatedSprite class.

First, we'll use :ref:`AnimatedSprite <class_AnimatedSprite>` to
animate a collection of individual images. Then we will animate a sprite sheet using this class. Finally, we will learn another way to animate a sprite sheet
animate a collection of individual images. Then we will animate a sprite sheet using this class. Finally, we will learn another way to animate a sprite sheet
with :ref:`AnimationPlayer <class_AnimationPlayer>` and the *Animation*
property of :ref:`Sprite <class_Sprite>`.

Expand Down Expand Up @@ -115,34 +115,34 @@ released.
Sprite sheet with AnimatedSprite
--------------------------------

You can also easily animate from a sprite sheet with the class ``AnimatedSprite``. We will use this public domain sprite sheet:
You can also easily animate from a sprite sheet with the class ``AnimatedSprite``. We will use this public domain sprite sheet:

.. image:: img/2d_animation_frog_spritesheet.png

Right-click the image and choose "Save Image As" to download it, and then copy the image into your project folder.

Set up your scene tree the same way you did previously when using individual images. Select the ``AnimatedSprite`` and in its *SpriteFrames* property, select
Set up your scene tree the same way you did previously when using individual images. Select the ``AnimatedSprite`` and in its *SpriteFrames* property, select
"New SpriteFrames".

Click on the new SpriteFrames resource. This time, when the bottom panel appears, select "Add frames from a Sprite Sheet".
Click on the new SpriteFrames resource. This time, when the bottom panel appears, select "Add frames from a Sprite Sheet".

.. image:: img/2d_animation_add_from_spritesheet.png

You will be prompted to open a file. Select your sprite sheet.
You will be prompted to open a file. Select your sprite sheet.

A new window will open, showing your sprite sheet. The first thing you will need to do is to change the number of vertical and horizontal images in your sprite sheet. In this sprite sheet, we have four images horizontally and two images vertically.
A new window will open, showing your sprite sheet. The first thing you will need to do is to change the number of vertical and horizontal images in your sprite sheet. In this sprite sheet, we have four images horizontally and two images vertically.

.. image:: img/2d_animation_spritesheet_select_rows.png

Next, select the frames from the sprite sheet that you want to include in your animation. We will select the top four, then click "Add 4 frames" to create the animation.
Next, select the frames from the sprite sheet that you want to include in your animation. We will select the top four, then click "Add 4 frames" to create the animation.

.. image:: img/2d_animation_spritesheet_selectframes.png

You will now see your animation under the list of animations in the bottom panel. Double click on default to change the name of the animation to jump.
You will now see your animation under the list of animations in the bottom panel. Double click on default to change the name of the animation to jump.

.. image:: img/2d_animation_spritesheet_animation.png

Finally, check Playing on the AnimatedSprite in the inspector to see your frog jump!
Finally, check Playing on the AnimatedSprite in the inspector to see your frog jump!

.. image:: img/2d_animation_play_spritesheet_animation.png

Expand Down Expand Up @@ -266,4 +266,4 @@ Summary
These examples illustrate the two classes you can use in Godot for
2D animation. ``AnimationPlayer`` is
a bit more complex than ``AnimatedSprite``, but it provides additional functionality, since you can also
animate other properties like position or scale. The class ``AnimationPlayer`` can also be used with an ``AnimatedSprite``. Experiment to see what works best for your needs.
animate other properties like position or scale. The class ``AnimationPlayer`` can also be used with an ``AnimatedSprite``. Experiment to see what works best for your needs.
2 changes: 1 addition & 1 deletion tutorials/3d/procedural_geometry/arraymesh.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ PackedInt32Array, etc.) for each type of information.

- ``ARRAY_VERTEX`` = 0 | PackedVector3Array or PackedVector2Array
- ``ARRAY_NORMAL`` = 1 | PackedVector3Array
- ``ARRAY_TANGENT`` = 2 | PackedFloat32Array of groups of 4 floats. first 3 floats determine the tangent, and
- ``ARRAY_TANGENT`` = 2 | PackedFloat32Array of groups of 4 floats. First 3 floats determine the tangent, and
the last the binormal direction as -1 or 1.
- ``ARRAY_COLOR`` = 3 | PackedColorArray
- ``ARRAY_TEX_UV`` = 4 | PackedVector2Array or PackedVector3Array
Expand Down
2 changes: 1 addition & 1 deletion tutorials/best_practices/data_preferences.rst
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ Contiguous memory stores imply the following operation performance:
This makes only 2 copies of the array (still constant time, but slow)
versus copying roughly 1/2 of the array, on average, N times (linear time).

- **Get, Set:** Fastest *by position*. Ex. can request 0th, 2nd, 10th record, etc.
- **Get, Set:** Fastest *by position*. E.g. can request 0th, 2nd, 10th record, etc.
but cannot specify which record you want.

- Op: 1 addition operation from array start position up to desired index.
Expand Down
2 changes: 1 addition & 1 deletion tutorials/export/exporting_for_web.rst
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ Any other JavaScript value is returned as ``null``.
HTML5 export templates may be :ref:`built <doc_compiling_for_web>` without
support for the singleton to improve security. With such templates, and on
platforms other than HTML5, calling ``JavaScript.eval`` will also return
``null``. The availability of the singleton can be checked with the
``null``. The availability of the singleton can be checked with the
``JavaScript`` :ref:`feature tag <doc_feature_tags>`::

func my_func3():
Expand Down
2 changes: 1 addition & 1 deletion tutorials/inputs/input_examples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ Keyboard modifiers
~~~~~~~~~~~~~~~~~~

Modifier properties are inherited from
:ref:`InputEventWithModifiers <class_InputEventWithModifiers>`. This allows
:ref:`InputEventWithModifiers <class_InputEventWithModifiers>`. This allows
you to check for modifier combinations using boolean properties. Let's imagine
you want one thing to happen when the :kbd:`T` is pressed, but something
different when it's :kbd:`Shift + T`:
Expand Down
2 changes: 1 addition & 1 deletion tutorials/io/saving_games.rst
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ load function:
{
var saveGame = new File();
if (!saveGame.FileExists("user://savegame.save"))
return; // Error! We don't have a save to load.
return; // Error! We don't have a save to load.

// We need to revert the game state so we're not cloning objects during loading.
// This will vary wildly depending on the needs of a project, so take care with
Expand Down
2 changes: 1 addition & 1 deletion tutorials/math/beziers_and_curves.rst
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ Traversal

The last common use case for the curves is to traverse them. Because of what was mentioned before regarding constant speed, this is also difficult.

To make this easier, the curves need to be *baked* into equidistant points. This way, they can be approximated with regular interpolation (which can be improved further with a cubic option). To do this, just use the :ref:`Curve.interpolate_baked()<class_Curve_method_interpolate_baked>` method together with
To make this easier, the curves need to be *baked* into equidistant points. This way, they can be approximated with regular interpolation (which can be improved further with a cubic option). To do this, just use the :ref:`Curve.interpolate_baked()<class_Curve_method_interpolate_baked>` method together with
:ref:`Curve2D.get_baked_length()<class_Curve2D_method_get_baked_length>`. The first call to either of them will bake the curve internally.

Traversal at constant speed, then, can be done with the following pseudo-code:
Expand Down
24 changes: 12 additions & 12 deletions tutorials/networking/http_request_class.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Below is all the code we need to make it work. The URL points to an online API m
.. tabs::

.. code-tab:: gdscript GDScript

extends CanvasLayer

func _ready():
Expand All @@ -38,23 +38,23 @@ Below is all the code we need to make it work. The URL points to an online API m
func _on_request_completed(result, response_code, headers, body):
var json = JSON.parse(body.get_string_from_utf8())
print(json.result)

.. code-tab:: csharp

class HTTPRequestDemo : CanvasLayer
{
public override void _Ready()
{
GetNode("HTTPRequest").Connect("request_completed", this, "OnRequestCompleted");
GetNode("Button").Connect("pressed", this, "OnButtonPressed");
}

public void OnButtonPressed()
{
HTTPRequest httpRequest = GetNode<HTTPRequest>("HTTPRequest");
httpRequest.Request("http://www.mocky.io/v2/5185415ba171ea3a00704eed");
}

public void OnRequestCompleted(int result, int response_code, string[] headers, byte[] body)
{
JSONParseResult json = JSON.Parse(Encoding.UTF8.GetString(body));
Expand All @@ -71,14 +71,14 @@ Note that you may want to check whether the ``result`` equals ``RESULT_SUCCESS``
Of course, you can also set custom HTTP headers. These are given as a string array, with each string containing a header in the format ``"header: value"``.
For example, to set a custom user agent (the HTTP ``user-agent`` header) you could use the following:

.. tabs::
.. tabs::

.. code-tab:: gdscript GDScript

$HTTPRequest.request("http://www.mocky.io/v2/5185415ba171ea3a00704eed", ["user-agent: YourCustomUserAgent"])

.. code-tab:: csharp

HTTPRequest httpRequest = GetNode<HTTPRequest>("HTTPRequest");
httpRequest.Request("http://www.mocky.io/v2/5185415ba171ea3a00704eed", new string[] { "user-agent: YourCustomUserAgent" });

Expand All @@ -95,16 +95,16 @@ Until now, we have limited ourselves to requesting data from a server. But what
.. tabs::

.. code-tab:: gdscript GDScript

func _make_post_request(url, data_to_send, use_ssl):
# Convert data to json string:
var query = JSON.print(data_to_send)
# Add 'Content-Type' header:
var headers = ["Content-Type: application/json"]
$HTTPRequest.request(url, headers, use_ssl, HTTPClient.METHOD_POST, query)

.. code-tab:: csharp

public void MakePostRequest(string url, object data_to_send, bool use_ssl)
{
string query = JSON.Print(data_to_send);
Expand Down
2 changes: 1 addition & 1 deletion tutorials/performance/gpu_optimization.rst
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ Reuse Shaders and Materials
The Godot renderer is a little different to what is out there. It's designed to
minimize GPU state changes as much as possible. :ref:`StandardMaterial3D
<class_StandardMaterial3D>` does a good job at reusing materials that need similar
shaders. if custom shaders are used, make sure to reuse them as much as
shaders. If custom shaders are used, make sure to reuse them as much as
possible. Godot's priorities are:

- **Reusing Materials:** The fewer different materials in the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ the wave making it look like a wave is moving along the fish.
.. image:: img/wave.gif

The last motion is the twist, which is a panning roll along the spine. Similarly to the pivot,
we first construct a rotation matrix.
we first construct a rotation matrix.

.. code-block:: glsl
Expand All @@ -141,7 +141,7 @@ If we apply all these motions one after another, we get a fluid jelly-like motio
Normal fish swim mostly with the back half of their body. Accordingly, we need to limit the
panning motions to the back half of the fish. To do this, we create a new variable, ``mask``.

``mask`` is a float that goes from ``0`` at the front of the fish to ``1`` at the end using
``mask`` is a float that goes from ``0`` at the front of the fish to ``1`` at the end using
``smoothstep`` to control the point at which the transition from ``0`` to ``1`` happens.

.. code-block:: glsl
Expand Down Expand Up @@ -229,7 +229,7 @@ MultiMeshInstance.

.. note:: If performance is an issue for you, try running the scene with GLES2 or with fewer fish.

Notice how all the fish are all in the same position in their swim cycle? It makes them look very
Notice how all the fish are all in the same position in their swim cycle? It makes them look very
robotic. The next step is to give each fish a different position in the swim cycle so the entire
school looks more organic.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ Then add the following two functions:
}
These functions come from the default :ref:`ParticlesMaterial <class_ParticlesMaterial>`.
They are used to generate a random number from each particle's ``RANDOM_SEED``.
They are used to generate a random number from each particle's ``RANDOM_SEED``.

A unique thing about particle shaders is that some built-in variables are saved across frames.
``TRANSFORM``, ``COLOR``, and ``CUSTOM`` can all be accessed in the Spatial shader of the mesh, and
Expand Down
2 changes: 1 addition & 1 deletion tutorials/physics/physics_introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ to it and the physics engine calculates the resulting movement, including
collisions with other bodies, and collision responses, such as bouncing,
rotating, etc.

You can modify a rigid body's behavior via properties such as "Mass",
You can modify a rigid body's behavior via properties such as "Mass",
"Friction", or "Bounce", which can be set in the Inspector.

The body's behavior is also affected by the world's properties, as set in
Expand Down
Loading

0 comments on commit 044b6a7

Please sign in to comment.