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
c7cfe533
Commit
c7cfe533
authored
Apr 02, 2019
by
Michael Alexsander Silva Dias
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make 'ConvexPolygonShape2D' start empty, so it's consistent with other shapes.
parent
9501900e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
8 deletions
+0
-8
convex_polygon_shape.cpp
scene/resources/convex_polygon_shape.cpp
+0
-2
convex_polygon_shape_2d.cpp
scene/resources/convex_polygon_shape_2d.cpp
+0
-6
No files found.
scene/resources/convex_polygon_shape.cpp
View file @
c7cfe533
...
...
@@ -83,6 +83,4 @@ void ConvexPolygonShape::_bind_methods() {
ConvexPolygonShape
::
ConvexPolygonShape
()
:
Shape
(
PhysicsServer
::
get_singleton
()
->
shape_create
(
PhysicsServer
::
SHAPE_CONVEX_POLYGON
))
{
//set_points(Vector3(1,1,1));
}
scene/resources/convex_polygon_shape_2d.cpp
View file @
c7cfe533
...
...
@@ -99,10 +99,4 @@ Rect2 ConvexPolygonShape2D::get_rect() const {
ConvexPolygonShape2D
::
ConvexPolygonShape2D
()
:
Shape2D
(
Physics2DServer
::
get_singleton
()
->
convex_polygon_shape_create
())
{
int
pcount
=
3
;
for
(
int
i
=
0
;
i
<
pcount
;
i
++
)
points
.
push_back
(
Vector2
(
Math
::
sin
(
i
*
Math_PI
*
2
/
pcount
),
-
Math
::
cos
(
i
*
Math_PI
*
2
/
pcount
))
*
10
);
_update_shape
();
}
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