qkmaxware / spaceworks Goto Github PK
View Code? Open in Web Editor NEWUnity3d Planetary Terrain and Floating Origin
License: MIT License
Unity3d Planetary Terrain and Floating Origin
License: MIT License
There doesn't appear to be a way to Teleport across large distances, I could set the Foci's position to be where I want it but since it's a UNity Vector 3 and is Floats I can't put any large values in there without losing a lot of precision.
Tried implementing my own method but I have no idea if this is correct, and don't really have any good way to test it yet.
var TargetSector = new WorldPosition( TargetPositionToTeleportTo ).SectorOnly();
var Old = this.sceneCenter;
var Delta = TargetSector - this.sceneCenter;
this.sceneCenter += Delta;
foci.transform.position -= Delta.vector3;
foreach (FloatingTransform tr in monitored)
{
if (tr != null)
{
tr.OnOriginChange(this.sceneCenter, Delta);
if (!tr.worldPosition.SameSector(Old) && tr.worldPosition.SameSector(this.sceneCenter))
{
tr.OnOriginEnter(this.sceneCenter);
}
if (tr.worldPosition.SameSector(Old) && !tr.worldPosition.SameSector(this.sceneCenter))
{
tr.OnOriginExit(this.sceneCenter);
}
}
}
Any idea if this is Correct?
In my project I dont move the object the normal way, Instead Im constantly settings its position from a Decimal Type Sent from a Server, So the Unity Client needs to constantly conver the Decimal Type to some form of Unity Coordinate
Hi,
It is a fantastic asset!
But i in Floating Point Manager has missing the script.
Could you help which script have to use it?
Thank you!
Best Regards,
Patrik
Is it possible to create an earth sized planet using this project?
I am planning on creating a planet with a size close to the earth's one (6000 km radius).
Can your project generate a walkable planet of this scale?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.