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
a9214bce
Commit
a9214bce
authored
Jan 21, 2019
by
Andrea Catania
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed area overlaps if not move
parent
7ae4cb7f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
space_bullet.cpp
modules/bullet/space_bullet.cpp
+5
-4
No files found.
modules/bullet/space_bullet.cpp
View file @
a9214bce
...
...
@@ -678,11 +678,14 @@ void SpaceBullet::check_ghost_overlaps() {
// For each overlapping
for
(
i
=
ghostOverlaps
.
size
()
-
1
;
0
<=
i
;
--
i
)
{
bool
hasOverlap
=
false
;
btCollisionObject
*
overlapped_bt_co
=
ghostOverlaps
[
i
];
RigidCollisionObjectBullet
*
otherObject
=
static_cast
<
RigidCollisionObjectBullet
*>
(
overlapped_bt_co
->
getUserPointer
());
if
(
!
area
->
is_transform_changed
()
&&
!
otherObject
->
is_transform_changed
())
continue
;
if
(
!
area
->
is_transform_changed
()
&&
!
otherObject
->
is_transform_changed
())
{
hasOverlap
=
true
;
goto
collision_found
;
}
if
(
overlapped_bt_co
->
getUserIndex
()
==
CollisionObjectBullet
::
TYPE_AREA
)
{
if
(
!
static_cast
<
AreaBullet
*>
(
overlapped_bt_co
->
getUserPointer
())
->
is_monitorable
())
...
...
@@ -690,8 +693,6 @@ void SpaceBullet::check_ghost_overlaps() {
}
else
if
(
overlapped_bt_co
->
getUserIndex
()
!=
CollisionObjectBullet
::
TYPE_RIGID_BODY
)
continue
;
bool
hasOverlap
=
false
;
// For each area shape
for
(
y
=
area
->
get_shape_count
()
-
1
;
0
<=
y
;
--
y
)
{
if
(
!
area
->
get_bt_shape
(
y
)
->
isConvex
())
...
...
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