Skip to content

Commit 5589314

Browse files
authored
Merge pull request #10329 from esainane/pool-closed
Remove references to PoolVector
2 parents 160b937 + 3f206fd commit 5589314

File tree

2 files changed

+3
-27
lines changed

2 files changed

+3
-27
lines changed

contributing/development/core_and_modules/core_types.rst

Lines changed: 1 addition & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -103,36 +103,12 @@ which are equivalent to new, delete, new[] and delete[].
103103
memnew/memdelete also use a little C++ magic and notify Objects right
104104
after they are created, and right before they are deleted.
105105

106-
For dynamic memory, the PoolVector<> template is provided. PoolVector is a
107-
standard vector class, and is very similar to vector in the C++ standard library.
108-
To create a PoolVector buffer, use this:
109-
110-
.. code-block:: cpp
111-
112-
PoolVector<int> data;
113-
114-
PoolVector can be accessed using the [] operator and a few helpers exist for this:
115-
116-
.. code-block:: cpp
117-
118-
PoolVector<int>::Read r = data.read()
119-
int someint = r[4]
120-
121-
.. code-block:: cpp
122-
123-
PoolVector<int>::Write w = data.write()
124-
w[4] = 22;
125-
126-
These operations allow fast read/write from PoolVectors and keep it
127-
locked until they go out of scope. However, PoolVectors should be used
128-
for small, dynamic memory operations, as read() and write() are too slow for a
129-
large amount of accesses.
106+
For dynamic memory, use Vector<>.
130107

131108
References:
132109
~~~~~~~~~~~
133110

134111
- `core/os/memory.h <https://github.com/godotengine/godot/blob/master/core/os/memory.h>`__
135-
- `core/pool_vector.h <https://github.com/godotengine/godot/blob/master/core/pool_vector.cpp>`__
136112

137113
Containers
138114
----------

tutorials/navigation/navigation_using_navigationlayers.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ In scripts the following helper functions can be used to work with the ``navigat
3737
var path_query_navigation_layers: int = 0
3838
path_query_navigation_layers = enable_bitmask_inx(path_query_navigation_layers, 2)
3939
# get a path that only considers 2-nd layer regions
40-
var path: PoolVector2Array = NavigationServer2D.map_get_path(
40+
var path: PackedVector2Array = NavigationServer2D.map_get_path(
4141
map,
4242
start_position,
4343
target_position,
@@ -120,7 +120,7 @@ In scripts the following helper functions can be used to work with the ``navigat
120120
var path_query_navigation_layers: int = 0
121121
path_query_navigation_layers = enable_bitmask_inx(path_query_navigation_layers, 2)
122122
# get a path that only considers 2-nd layer regions
123-
var path: PoolVector3Array = NavigationServer3D.map_get_path(
123+
var path: PackedVector3Array = NavigationServer3D.map_get_path(
124124
map,
125125
start_position,
126126
target_position,

0 commit comments

Comments
 (0)