用户工具

站点工具


侧边栏



Unity3D中文文档

script:unityengine:classes:constantforce:constantforce

ConstantForce 恒力

class in UnityEngine/Inherits from: Behaviour

Description 描述

A force applied constantly.

一个不断施加的恒力。

This is a small physics utility class used to apply a continous force to an object.

这是一个小的物理实用类,用于给物体施加恒力。

Rigidbody.AddForce applies a force to the Rigidbody only for one frame, thus you have to keep calling the function. ConstantForce on the other hand will apply the force every frame until you change the force or torque to a new value.

Rigidbody.AddForce仅在一帧给刚体施加一个力,因此你需要一直调用该函数。ConstantForce在另一方面将会在每帧施加该力到物体直到改变该力或者转矩一个新的值。

See Also: Rigidbody.

Variables 变量

forceThe force applied to the rigidbody every frame.
该力每帧都施加于刚体上。
relativeForceThe force - relative to the rigid bodies coordinate system - applied every frame.
该力相对于刚体的坐标系统应用于每帧。
relativeTorqueThe torque - relative to the rigid bodies coordinate system - applied every frame.
该转矩相对于刚体的坐标系统应用于每帧。
torqueThe torque applied to the rigidbody every frame.
该转矩每帧都用于刚体上。
script/unityengine/classes/constantforce/constantforce.txt · 最后更改: 2016/08/02 05:27 (外部编辑)