Game Development Reference
In-Depth Information
Box Collider
X
:
-0.5
,
Y
:
-0.1
, and
Z
:
-0.175
Center
X
:
1.3
,
Y
:
0.5
, and
Z
:
0.35
Size
10. Click on
spine1
in the
Hierarchy
view, go to the
Inspector
view, and set the fol-
lowing:
Box Collider
Center
X
:
-0.32
,
Y
:
0.1
, and
Z
:
-0.175
X
:
1.3
,
Y
:
0.5
, and
Z
:
0.35
Size
11. We just set up the ragdoll for the
AI
game object, but we still need to apply the
collider
and
Rigidbody
components to the
gun
object. So, we will click on the
gun
game object and apply
Rigidbody
to this by navigating to
Component
|
Physics
|
Rigidbody
. Go to the
Inspector
view of this game object and set the
following:
Rigidbody
Mass
3
12. Next, click on the triangle in front of the
gun
game object to bring up the
gun_
model
object, as shown in the following screenshot:
13. Apply the
Box Collider
component to the
gun_model
object (this will make the
gun collide with other objects when it falls down) by going to
Component
|
Physics
|
Box Collider
. We are now done with the creation of the
ro-
botAI_ragdoll
game object.