Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
godot
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
community
godot
Commits
cfa6a1d7
Unverified
Commit
cfa6a1d7
authored
Aug 29, 2018
by
Rémi Verschelde
Committed by
GitHub
Aug 29, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #21563 from marcelofg55/_set_celld
Unexpose TileMap set_celld
parents
907b7a38
20bea1e2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
5 deletions
+5
-5
tile_map_editor_plugin.cpp
editor/plugins/tile_map_editor_plugin.cpp
+2
-2
tile_map.cpp
scene/2d/tile_map.cpp
+2
-2
tile_map.h
scene/2d/tile_map.h
+1
-1
No files found.
editor/plugins/tile_map_editor_plugin.cpp
View file @
cfa6a1d7
...
...
@@ -238,8 +238,8 @@ void TileMapEditor::_create_set_cell_undo(const Vector2 &p_vec, const CellOp &p_
cell_new
[
"transpose"
]
=
p_cell_new
.
tr
;
cell_new
[
"auto_coord"
]
=
p_cell_new
.
ac
;
undo_redo
->
add_undo_method
(
node
,
"set_celld"
,
p_vec
,
cell_old
);
undo_redo
->
add_do_method
(
node
,
"set_celld"
,
p_vec
,
cell_new
);
undo_redo
->
add_undo_method
(
node
,
"
_
set_celld"
,
p_vec
,
cell_old
);
undo_redo
->
add_do_method
(
node
,
"
_
set_celld"
,
p_vec
,
cell_new
);
}
void
TileMapEditor
::
_start_undo
(
const
String
&
p_action
)
{
...
...
scene/2d/tile_map.cpp
View file @
cfa6a1d7
...
...
@@ -726,7 +726,7 @@ void TileMap::set_cellv(const Vector2 &p_pos, int p_tile, bool p_flip_x, bool p_
set_cell
(
p_pos
.
x
,
p_pos
.
y
,
p_tile
,
p_flip_x
,
p_flip_y
,
p_transpose
);
}
void
TileMap
::
set_celld
(
const
Vector2
&
p_pos
,
const
Dictionary
&
p_data
)
{
void
TileMap
::
_
set_celld
(
const
Vector2
&
p_pos
,
const
Dictionary
&
p_data
)
{
set_cell
(
p_pos
.
x
,
p_pos
.
y
,
p_data
[
"id"
],
p_data
[
"flip_h"
],
p_data
[
"flip_y"
],
p_data
[
"transpose"
],
p_data
[
"auto_coord"
]);
}
...
...
@@ -1612,7 +1612,7 @@ void TileMap::_bind_methods() {
ClassDB
::
bind_method
(
D_METHOD
(
"set_cell"
,
"x"
,
"y"
,
"tile"
,
"flip_x"
,
"flip_y"
,
"transpose"
,
"autotile_coord"
),
&
TileMap
::
set_cell
,
DEFVAL
(
false
),
DEFVAL
(
false
),
DEFVAL
(
false
),
DEFVAL
(
Vector2
()));
ClassDB
::
bind_method
(
D_METHOD
(
"set_cellv"
,
"position"
,
"tile"
,
"flip_x"
,
"flip_y"
,
"transpose"
),
&
TileMap
::
set_cellv
,
DEFVAL
(
false
),
DEFVAL
(
false
),
DEFVAL
(
false
));
ClassDB
::
bind_method
(
D_METHOD
(
"
set_celld"
,
"position"
,
"data"
),
&
TileMap
::
set_celld
);
ClassDB
::
bind_method
(
D_METHOD
(
"
_set_celld"
,
"position"
,
"data"
),
&
TileMap
::
_
set_celld
);
ClassDB
::
bind_method
(
D_METHOD
(
"get_cell"
,
"x"
,
"y"
),
&
TileMap
::
get_cell
);
ClassDB
::
bind_method
(
D_METHOD
(
"get_cellv"
,
"position"
),
&
TileMap
::
get_cellv
);
ClassDB
::
bind_method
(
D_METHOD
(
"is_cell_x_flipped"
,
"x"
,
"y"
),
&
TileMap
::
is_cell_x_flipped
);
...
...
scene/2d/tile_map.h
View file @
cfa6a1d7
...
...
@@ -242,7 +242,7 @@ public:
void
set_cell_autotile_coord
(
int
p_x
,
int
p_y
,
const
Vector2
&
p_coord
);
Vector2
get_cell_autotile_coord
(
int
p_x
,
int
p_y
)
const
;
void
set_celld
(
const
Vector2
&
p_pos
,
const
Dictionary
&
p_data
);
void
_
set_celld
(
const
Vector2
&
p_pos
,
const
Dictionary
&
p_data
);
void
set_cellv
(
const
Vector2
&
p_pos
,
int
p_tile
,
bool
p_flip_x
=
false
,
bool
p_flip_y
=
false
,
bool
p_transpose
=
false
);
int
get_cellv
(
const
Vector2
&
p_pos
)
const
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment