Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support type constants #64

Open
Anaminus opened this issue May 7, 2022 · 0 comments
Open

Support type constants #64

Anaminus opened this issue May 7, 2022 · 0 comments
Labels
enhancement New feature or request
Milestone

Comments

@Anaminus
Copy link
Owner

Anaminus commented May 7, 2022

Roblox added constants like Vector3.zero and CFrame.identity. These should be added to rbxmk.

List of constants:

  • CFrame.identity = CFrame.new()
  • Vector3.zero = Vector3.new()
  • Vector3.one = Vector3.new(1, 1, 1)
  • Vector3.xAxis = Vector3.new(1, 0, 0)
  • Vector3.yAxis = Vector3.new(0, 1, 0)
  • Vector3.zAxis = Vector3.new(0, 0, 1)
  • Vector2.zero = Vector2.new()
  • Vector2.one = Vector2.new(1, 1)
  • Vector2.xAxis = Vector2.new(1, 0)
  • Vector2.yAxis = Vector2.new(0, 1)

Implement by adding a Constants field to Reflector. This is similar to Constructors, but adds constant values instead.

Roblox seems to refer to these as "static" values.

@Anaminus Anaminus added the enhancement New feature or request label May 7, 2022
@Anaminus Anaminus added this to the v0.10.0 milestone May 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant