Why is TeleportOptions made different than RaycastParams?


When you use RaycastParams, you build it like this: RaycastParams.new(), but when you do TeleportOptions, you make it like this: Instance.new("TeleportOptions"). I believe that there is another function that uses some constructors like TeleportOptions or RaycastParams, but I forgot the name.


Why use different types of constructors? What’s the point?

1 Like

Hello, move this to #help-and-feedback:scripting-support.


I have no idea. One may be older than the other.

I do know that you are using the instance.new constructor function to create it, so teleportOptions is an instance. RaycastParams is not.

RaycastParams is a Luau datatype and TeleportOptions is an instance.

But why can’t TeleportOptions be a Luau type too?

Again, why use this technique? We could use both.

1 Like

it seems like there isn’t really a good reason for this.

1 Like

So, which one did they choose? The post said, “Pretty soon”, so I’m bound to believe they chose one.

Sometimes their “soon” means around 6 months, or even more. I believe that since some Release Notes still have “pending” as their status.

I’ve seen that, the pending notes also sometimes aren’t pending and are already released for that version.