Skip to content

Commit

Permalink
chore: Format
Browse files Browse the repository at this point in the history
  • Loading branch information
HunterBarclay committed Jan 9, 2025
1 parent 0fa19d9 commit 63aa8bb
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
5 changes: 4 additions & 1 deletion fission/src/test/PhysicsSystem.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,10 @@ describe("GodMode", () => {
test("Basic", () => {
const system = new PhysicsSystem()
const box = system.CreateBox(new THREE.Vector3(1, 1, 1), 1, new THREE.Vector3(0, 0, 0), undefined)
const [ghostObject, ghostConstraint] = system.CreateGodModeBody(box.GetID(), JoltRVec3_JoltVec3(box.GetPosition()))
const [ghostObject, ghostConstraint] = system.CreateGodModeBody(
box.GetID(),
JoltRVec3_JoltVec3(box.GetPosition())
)

assert(system.GetBody(ghostObject.GetID()) != undefined)
assert(system.GetBody(box.GetID()) != undefined)
Expand Down
5 changes: 4 additions & 1 deletion fission/src/ui/panels/DebugPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ async function TestGodMode() {
return
}
const robotPosition = World.PhysicsSystem.GetBody(rootNodeId).GetPosition()
const [ghostBody, _ghostConstraint] = World.PhysicsSystem.CreateGodModeBody(rootNodeId, JoltRVec3_JoltVec3(robotPosition))
const [ghostBody, _ghostConstraint] = World.PhysicsSystem.CreateGodModeBody(
rootNodeId,
JoltRVec3_JoltVec3(robotPosition)
)

// Move ghostBody to demonstrate godMode movement
await new Promise(f => setTimeout(f, 1000))
Expand Down
2 changes: 1 addition & 1 deletion fission/src/util/TypeConversions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export function JoltVec3_JoltRVec3(m: Jolt.Vec3): Jolt.RVec3 {
}

export function JoltRVec3_JoltVec3(m: Jolt.RVec3): Jolt.Vec3 {
return new JOLT.Vec3(m.GetX(), m.GetY(), m.GetZ());
return new JOLT.Vec3(m.GetX(), m.GetY(), m.GetZ())
}

export function MirabufTransform_ThreeMatrix4(m: mirabuf.ITransform): THREE.Matrix4 {
Expand Down

0 comments on commit 63aa8bb

Please sign in to comment.