Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local ReplicatedStorage = game:GetService("ReplicatedStorage")
- local Matter = require(ReplicatedStorage.Shared.Libs.Matter)
- local Components = require(ReplicatedStorage.Shared.Components)
- local function MoveTransforms(world, state)
- for id, transform, velocity in world:query(Components.Transform, Components.Velocity):without(Components.NonShared) do
- world:insert(id, transform:patch({
- Position = transform.Position + velocity.Velocity * Matter.useDeltaTime()
- }))
- end
- end
- return MoveTransforms
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement