mirror of
https://github.com/stan220/godot-docs.git
synced 2026-09-08 17:28:58 +00:00
@@ -448,11 +448,11 @@ Create a new script called ``Bullet_script.gd`` and attach it to the ``Bullet``
|
||||
|
||||
We are going to move the entire bullet object at the root (``Bullet``). We will be using the :ref:`Area <class_Area>` to check whether or not we've collided with something
|
||||
|
||||
.. note:: Why are we using a :ref:`Area <class_Area>` and not a :ref:`RigidBody <class_RigidBody>`? The main reason we're not using a :ref:`RigidBody <class_RigidBody>`
|
||||
.. note:: Why are we using an :ref:`Area <class_Area>` and not a :ref:`RigidBody <class_RigidBody>`? The main reason we're not using a :ref:`RigidBody <class_RigidBody>`
|
||||
is because we do not want the bullet to interact with other :ref:`RigidBody <class_RigidBody>` nodes.
|
||||
By using an :ref:`Area <class_Area>` we are assuring that none of the other :ref:`RigidBody <class_RigidBody>` nodes, including other bullets, will be effected.
|
||||
|
||||
Another reason is simply because it is easier to detect collisions with a :ref:`Area <class_Area>`!
|
||||
Another reason is simply because it is easier to detect collisions with an :ref:`Area <class_Area>`!
|
||||
|
||||
Here's the script that will control our bullet:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user