mirror of
https://github.com/snowykami/mbcp.git
synced 2024-11-22 06:07:37 +08:00
🐛 修改dead link
This commit is contained in:
parent
253b816a64
commit
60763de407
@ -3,10 +3,10 @@
|
||||
本模块是主模块,提供了一些工具
|
||||
可导入
|
||||
|
||||
[`mbcp.mp_math`](./mp_math):数学工具
|
||||
[`mbcp.mp_math`](./mp_math/):数学工具
|
||||
|
||||
[`mbcp.particle`](./particle):粒子生成工具
|
||||
[`mbcp.particle`](./particle/):粒子生成工具
|
||||
|
||||
[`mbcp.presets`](./presets):预设
|
||||
[`mbcp.presets`](./presets/):预设
|
||||
"""
|
||||
from .mp_math import *
|
||||
|
@ -19,9 +19,9 @@ class Vector3:
|
||||
"""
|
||||
3维向量
|
||||
Args:
|
||||
x: x轴分量
|
||||
y: y轴分量
|
||||
z: z轴分量
|
||||
x ([`float`](https%3A//docs.python.org/3/library/functions.html#float)): x轴分量
|
||||
y (`float`): y轴分量
|
||||
z (`float`): z轴分量
|
||||
"""
|
||||
self.x = x
|
||||
self.y = y
|
||||
@ -31,11 +31,11 @@ class Vector3:
|
||||
"""
|
||||
判断两个向量是否近似相等。
|
||||
Args:
|
||||
other:
|
||||
epsilon:
|
||||
other ([`Vector3`](#class-vector3)): 另一个向量
|
||||
epsilon ([`float`](https%3A//docs.python.org/3/library/functions.html#float)): 误差
|
||||
|
||||
Returns:
|
||||
是否近似相等
|
||||
[`bool`](https%3A//docs.python.org/3/library/functions.html#bool): 是否近似相等
|
||||
"""
|
||||
return all([abs(self.x - other.x) < epsilon, abs(self.y - other.y) < epsilon, abs(self.z - other.z) < epsilon])
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user