diff --git a/Libraries/Load.luau b/Libraries/Load.luau index 30c224d..5b77bf7 100644 --- a/Libraries/Load.luau +++ b/Libraries/Load.luau @@ -1,4 +1,7 @@ --!strict +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path + local Load = {} function Load.Help() @@ -6,7 +9,7 @@ function Load.Help() end function Load.Start(ticket: string) - dofile("http://banland.xyz/game/host?ticket=" .. ticket) + dofile(path "game/host?ticket=" .. ticket) end return Load diff --git a/Modules/BaseUrl.luau b/Modules/BaseUrl.luau index 7018912..e35baaa 100644 --- a/Modules/BaseUrl.luau +++ b/Modules/BaseUrl.luau @@ -1,2 +1,15 @@ +--!strict local ContentProvider = game:GetService "ContentProvider" +-- remove www +local url = string.gsub(ContentProvider.BaseUrl, "www.", "") + +local BaseUrl = { + url = url, +} + +function BaseUrl.path(path: string) + return url .. path +end + +return BaseUrl diff --git a/Modules/Polyfill/TweenInfo.luau b/Modules/Polyfill/TweenInfo.luau index 23ca5f2..acf517b 100644 --- a/Modules/Polyfill/TweenInfo.luau +++ b/Modules/Polyfill/TweenInfo.luau @@ -10,7 +10,7 @@ function TweenInfo.new( repeatCount: number?, reverses: boolean?, delayTime: number? -) +): FakeTweenInfo local proxy = newproxy(true) local mt = getmetatable(proxy) @@ -92,7 +92,7 @@ function TweenInfo.new( -- When attempting to assign to properties, throw an error mt.__newindex = function(_, prop) - error(prop .. " cannot be assigned to", math.huge) -- lmfao + error(prop .. " cannot be assigned to", 99) end mt.__tostring = function() diff --git a/defs.d.lua b/defs.d.lua index 7b8ca2f..375e7f7 100644 --- a/defs.d.lua +++ b/defs.d.lua @@ -1,75 +1,61 @@ +--#METADATA#{"CREATABLE_INSTANCES": ["Accoutrement", "Hat", "AdvancedDragger", "Animation", "AnimationController", "AnimationTrackState", "Animator", "Script", "LocalScript", "BindableEvent", "BindableFunction", "BodyAngularVelocity", "BodyForce", "BodyGyro", "BodyPosition", "BodyThrust", "BodyVelocity", "RocketPropulsion", "BoolValue", "BrickColorValue", "CFrameValue", "TextureContentProvider", "Camera", "BodyColors", "CharacterMesh", "Pants", "Shirt", "ShirtGraphic", "Skin", "ClickDetector", "Color3Value", "Configuration", "ContentFilter", "HumanoidController", "SkateboardController", "VehicleController", "CustomEvent", "CustomEventReceiver", "BlockMesh", "CylinderMesh", "FileMesh", "SpecialMesh", "DebugSettings", "DebuggerWatch", "Dialog", "DialogChoice", "DoubleConstrainedValue", "Dragger", "Explosion", "FWService", "Decal", "Texture", "FastLogSettings", "Hole", "MotorFeature", "Fire", "ForceField", "FunctionalTest", "GameSettings", "Frame", "NotificationObject", "ImageButton", "TextButton", "ImageLabel", "TextLabel", "NotificationBox", "TextBox", "BillboardGui", "ScreenGui", "GuiMain", "SurfaceGui", "FloorWire", "SelectionBox", "ArcHandles", "Handles", "SurfaceSelection", "SelectionPartLasso", "SelectionPointLasso", "TextureTrail", "Backpack", "HopperBin", "Tool", "Flag", "PlayerHUD", "Humanoid", "IntConstrainedValue", "IntValue", "RotateP", "RotateV", "Glue", "ManualGlue", "ManualWeld", "Motor", "Motor6D", "Rotate", "Snap", "VelocityMotor", "Weld", "Keyframe", "KeyframeSequence", "PointLight", "SpotLight", "LuaSettings", "Message", "Hint", "ModuleScript", "NetworkSettings", "NumberValue", "ObjectValue", "CornerWedgePart", "Part", "FlagStand", "Seat", "SkateboardPlatform", "SpawnLocation", "WedgePart", "ParallelRampPart", "PrismPart", "PyramidPart", "RightAngleRampPart", "TrussPart", "VehicleSeat", "Model", "PersonalServerService", "PhysicsSettings", "Player", "Pose", "RayValue", "ReflectionMetadata", "ReflectionMetadataCallbacks", "ReflectionMetadataClasses", "ReflectionMetadataEvents", "ReflectionMetadataFunctions", "ReflectionMetadataClass", "ReflectionMetadataMember", "ReflectionMetadataProperties", "ReflectionMetadataYieldFunctions", "RemoteEvent", "RemoteFunction", "RenderHooksService", "RenderSettings", "ScriptInformationProvider", "App", "Sky", "Smoke", "SocialService", "Sound", "StockSound", "Sparkles", "StarterGear", "ProfilingItem", "StringValue", "StudioTool", "TaskScheduler", "Team", "TerrainRegion", "TestService", "UserGameSettings", "Vector3Value"], "SERVICES": ["AssetService", "BadgeService", "CoreGui", "StarterGui", "CacheableContentProvider", "MeshContentProvider", "ChangeHistoryService", "Chat", "ClusterPacketCache", "CollectionService", "ContentProvider", "ContextActionService", "ControllerService", "CookiesService", "DataStoreService", "Debris", "DebugSettings", "FlagStandService", "FriendService", "GamePassService", "GameSettings", "Geometry", "Hopper", "StarterPack", "GuiService", "GuidRegistryService", "HttpService", "InsertService", "InstancePacketCache", "JointsService", "KeyframeSequenceProvider", "Lighting", "LoginService", "LuaSettings", "LuaWebService", "MarketplaceService", "NetworkClient", "NetworkServer", "NetworkSettings", "Workspace", "PhysicsPacketCache", "PhysicsService", "PhysicsSettings", "Players", "RenderSettings", "ReplicatedStorage", "RunService", "RuntimeScriptService", "ScriptContext", "ScriptService", "Selection", "ServerScriptService", "ServerStorage", "SoundService", "SpawnerService", "Stats", "TaskScheduler", "Teams", "TeleportService", "TestService", "TextService", "TimerService", "TweenService", "UserGameSettings", "UserInputService", "VirtualUser", "Visit"]} + -- Based on https://github.com/JohnnyMorganz/luau-lsp/blob/2bd0fb8a122932be67a16412591089e482bc3209/scripts/globalTypes.d.lua --- Many void return types here are listed as `nil` instead of `()`, not fixing it +-- I hope for the love of god this file is finally fixed after eight months of it being slowly edited leading to an anticlimactic three days of work culminating in it finally breaking and me rewriting it with the original script in like twenty minutes type Content = string -type Property = string type ProtectedString = string -type BinaryString = string type QDir = string type QFont = string +type Object = Instance declare class Enum - function GetEnumItems(self): { any } end declare class EnumItem Name: string Value: number - EnumType: Enum - function IsA(self, enumName: string): boolean end -declare debug: { - info: ((thread, number, string) -> R...) & ((number, string) -> R...) & (((A...) -> R1..., string) -> R2...), - traceback: ((string?, number?) -> string) & ((thread, string?, number?) -> string), - profilebegin: (label: string) -> (), - profileend: () -> (), - setmemorycategory: (tag: string) -> (), - resetmemorycategory: () -> (), -} - declare shared: any declare function collectgarbage(mode: "count"): number -declare function warn(...: T...) declare function tick(): number declare function time(): number -declare function elapsedTime(): number declare function wait(seconds: number?): (number, number) -declare function delay(delayTime: number?, callback: (T...) -> ()) declare function Delay(delayTime: number?, callback: (T...) -> ()) -declare function spawn(callback: (T...) -> (), ...: any) -declare function Spawn(callback: (T...) -> (), ...: any) +declare function delay(delayTime: number?, callback: (T...) -> ()) +declare function Spawn(callback: (T...) -> ()) declare function version(): string declare function printidentity(prefix: string?) declare class EnumAASamples extends EnumItem end declare class EnumAASamples_INTERNAL extends Enum - None: EnumAASamples ["4"]: EnumAASamples ["8"]: EnumAASamples + None: EnumAASamples end declare class EnumAccessType extends EnumItem end declare class EnumAccessType_INTERNAL extends Enum - Me: EnumAccessType - Friends: EnumAccessType Everyone: EnumAccessType + Friends: EnumAccessType InviteOnly: EnumAccessType + Me: EnumAccessType end declare class EnumActionType extends EnumItem end declare class EnumActionType_INTERNAL extends Enum + Draw: EnumActionType + Lose: EnumActionType Nothing: EnumActionType Pause: EnumActionType - Lose: EnumActionType - Draw: EnumActionType Win: EnumActionType end declare class EnumAnimationPriority extends EnumItem end declare class EnumAnimationPriority_INTERNAL extends Enum - Idle: EnumAnimationPriority - Movement: EnumAnimationPriority Action: EnumAnimationPriority Core: EnumAnimationPriority + Idle: EnumAnimationPriority + Movement: EnumAnimationPriority end declare class EnumAntialiasing extends EnumItem end declare class EnumAntialiasing_INTERNAL extends Enum @@ -85,31 +71,31 @@ declare class EnumAxis_INTERNAL extends Enum end declare class EnumBinType extends EnumItem end declare class EnumBinType_INTERNAL extends Enum - Script: EnumBinType + Clone: EnumBinType GameTool: EnumBinType Grab: EnumBinType - Clone: EnumBinType Hammer: EnumBinType + Script: EnumBinType end declare class EnumBodyPart extends EnumItem end declare class EnumBodyPart_INTERNAL extends Enum Head: EnumBodyPart - Torso: EnumBodyPart LeftArm: EnumBodyPart - RightArm: EnumBodyPart LeftLeg: EnumBodyPart + RightArm: EnumBodyPart RightLeg: EnumBodyPart + Torso: EnumBodyPart end declare class EnumButton extends EnumItem end declare class EnumButton_INTERNAL extends Enum - Jump: EnumButton Dismount: EnumButton + Jump: EnumButton end declare class EnumButtonStyle extends EnumItem end declare class EnumButtonStyle_INTERNAL extends Enum Custom: EnumButtonStyle - RobloxButtonDefault: EnumButtonStyle RobloxButton: EnumButtonStyle + RobloxButtonDefault: EnumButtonStyle end declare class EnumCameraMode extends EnumItem end declare class EnumCameraMode_INTERNAL extends Enum @@ -123,56 +109,56 @@ declare class EnumCameraPanMode_INTERNAL extends Enum end declare class EnumCameraType extends EnumItem end declare class EnumCameraType_INTERNAL extends Enum - Fixed: EnumCameraType - Watch: EnumCameraType Attach: EnumCameraType - Track: EnumCameraType - Follow: EnumCameraType Custom: EnumCameraType + Fixed: EnumCameraType + Follow: EnumCameraType Scriptable: EnumCameraType + Track: EnumCameraType + Watch: EnumCameraType end declare class EnumCellBlock extends EnumItem end declare class EnumCellBlock_INTERNAL extends Enum + CornerWedge: EnumCellBlock + HorizontalWedge: EnumCellBlock + InverseCornerWedge: EnumCellBlock Solid: EnumCellBlock VerticalWedge: EnumCellBlock - CornerWedge: EnumCellBlock - InverseCornerWedge: EnumCellBlock - HorizontalWedge: EnumCellBlock end declare class EnumCellMaterial extends EnumItem end declare class EnumCellMaterial_INTERNAL extends Enum - Empty: EnumCellMaterial - Grass: EnumCellMaterial - Sand: EnumCellMaterial - Brick: EnumCellMaterial - Granite: EnumCellMaterial - Asphalt: EnumCellMaterial - Iron: EnumCellMaterial Aluminum: EnumCellMaterial - Gold: EnumCellMaterial - WoodPlank: EnumCellMaterial - WoodLog: EnumCellMaterial - Gravel: EnumCellMaterial - CinderBlock: EnumCellMaterial - MossyStone: EnumCellMaterial - Cement: EnumCellMaterial - RedPlastic: EnumCellMaterial + Asphalt: EnumCellMaterial BluePlastic: EnumCellMaterial + Brick: EnumCellMaterial + Cement: EnumCellMaterial + CinderBlock: EnumCellMaterial + Empty: EnumCellMaterial + Gold: EnumCellMaterial + Granite: EnumCellMaterial + Grass: EnumCellMaterial + Gravel: EnumCellMaterial + Iron: EnumCellMaterial + MossyStone: EnumCellMaterial + RedPlastic: EnumCellMaterial + Sand: EnumCellMaterial Water: EnumCellMaterial + WoodLog: EnumCellMaterial + WoodPlank: EnumCellMaterial end declare class EnumCellOrientation extends EnumItem end declare class EnumCellOrientation_INTERNAL extends Enum + NegX: EnumCellOrientation NegZ: EnumCellOrientation X: EnumCellOrientation Z: EnumCellOrientation - NegX: EnumCellOrientation end declare class EnumCenterDialogType extends EnumItem end declare class EnumCenterDialogType_INTERNAL extends Enum - UnsolicitedDialog: EnumCenterDialogType - PlayerInitiatedDialog: EnumCenterDialogType ModalDialog: EnumCenterDialogType + PlayerInitiatedDialog: EnumCenterDialogType QuitDialog: EnumCenterDialogType + UnsolicitedDialog: EnumCenterDialogType end declare class EnumChatColor extends EnumItem end declare class EnumChatColor_INTERNAL extends Enum @@ -187,34 +173,34 @@ declare class EnumChatMode_INTERNAL extends Enum end declare class EnumChatStyle extends EnumItem end declare class EnumChatStyle_INTERNAL extends Enum - Classic: EnumChatStyle Bubble: EnumChatStyle + Classic: EnumChatStyle ClassicAndBubble: EnumChatStyle end declare class EnumConcurrencyModel extends EnumItem end declare class EnumConcurrencyModel_INTERNAL extends Enum - Serial: EnumConcurrencyModel - Safe: EnumConcurrencyModel - Logical: EnumConcurrencyModel Empirical: EnumConcurrencyModel + Logical: EnumConcurrencyModel + Safe: EnumConcurrencyModel + Serial: EnumConcurrencyModel end declare class EnumControlMode extends EnumItem end declare class EnumControlMode_INTERNAL extends Enum - MouseLockSwitch: EnumControlMode Classic: EnumControlMode + MouseLockSwitch: EnumControlMode end declare class EnumCoreGuiType extends EnumItem end declare class EnumCoreGuiType_INTERNAL extends Enum - PlayerList: EnumCoreGuiType - Health: EnumCoreGuiType + All: EnumCoreGuiType Backpack: EnumCoreGuiType Chat: EnumCoreGuiType - All: EnumCoreGuiType + Health: EnumCoreGuiType + PlayerList: EnumCoreGuiType end declare class EnumCreatorType extends EnumItem end declare class EnumCreatorType_INTERNAL extends Enum - User: EnumCreatorType Group: EnumCreatorType + User: EnumCreatorType end declare class EnumCurrencyType extends EnumItem end declare class EnumCurrencyType_INTERNAL extends Enum @@ -225,101 +211,101 @@ end declare class EnumD3DDEVTYPE extends EnumItem end declare class EnumD3DDEVTYPE_INTERNAL extends Enum D3DDEVTYPE_HAL: EnumD3DDEVTYPE + D3DDEVTYPE_NULLREF: EnumD3DDEVTYPE D3DDEVTYPE_REF: EnumD3DDEVTYPE D3DDEVTYPE_SW: EnumD3DDEVTYPE - D3DDEVTYPE_NULLREF: EnumD3DDEVTYPE end declare class EnumD3DFORMAT extends EnumItem end declare class EnumD3DFORMAT_INTERNAL extends Enum - D3DFMT_UNKNOWN: EnumD3DFORMAT - D3DFMT_R8G8B8: EnumD3DFORMAT - D3DFMT_A8R8G8B8: EnumD3DFORMAT - D3DFMT_X8R8G8B8: EnumD3DFORMAT - D3DFMT_R5G6B5: EnumD3DFORMAT - D3DFMT_X1R5G5B5: EnumD3DFORMAT - D3DFMT_A1R5G5B5: EnumD3DFORMAT - D3DFMT_A4R4G4B4: EnumD3DFORMAT - D3DFMT_R3G3B2: EnumD3DFORMAT - D3DFMT_A8: EnumD3DFORMAT - D3DFMT_A8R3G3B2: EnumD3DFORMAT - D3DFMT_X4R4G4B4: EnumD3DFORMAT - D3DFMT_A2B10G10R10: EnumD3DFORMAT - D3DFMT_A8B8G8R8: EnumD3DFORMAT - D3DFMT_X8B8G8R8: EnumD3DFORMAT - D3DFMT_G16R16: EnumD3DFORMAT - D3DFMT_A2R10G10B10: EnumD3DFORMAT D3DFMT_A16B16G16R16: EnumD3DFORMAT - D3DFMT_A8P8: EnumD3DFORMAT - D3DFMT_P8: EnumD3DFORMAT - D3DFMT_L8: EnumD3DFORMAT - D3DFMT_A8L8: EnumD3DFORMAT - D3DFMT_A4L4: EnumD3DFORMAT - D3DFMT_V8U8: EnumD3DFORMAT - D3DFMT_L6V5U5: EnumD3DFORMAT - D3DFMT_X8L8V8U8: EnumD3DFORMAT - D3DFMT_Q8W8V8U8: EnumD3DFORMAT - D3DFMT_V16U16: EnumD3DFORMAT + D3DFMT_A16B16G16R16F: EnumD3DFORMAT + D3DFMT_A1R5G5B5: EnumD3DFORMAT + D3DFMT_A2B10G10R10: EnumD3DFORMAT + D3DFMT_A2R10G10B10: EnumD3DFORMAT D3DFMT_A2W10V10U10: EnumD3DFORMAT - D3DFMT_D16_LOCKABLE: EnumD3DFORMAT - D3DFMT_D32: EnumD3DFORMAT + D3DFMT_A32B32G32R32F: EnumD3DFORMAT + D3DFMT_A4L4: EnumD3DFORMAT + D3DFMT_A4R4G4B4: EnumD3DFORMAT + D3DFMT_A8: EnumD3DFORMAT + D3DFMT_A8B8G8R8: EnumD3DFORMAT + D3DFMT_A8L8: EnumD3DFORMAT + D3DFMT_A8P8: EnumD3DFORMAT + D3DFMT_A8R3G3B2: EnumD3DFORMAT + D3DFMT_A8R8G8B8: EnumD3DFORMAT + D3DFMT_CxV8U8: EnumD3DFORMAT D3DFMT_D15S1: EnumD3DFORMAT - D3DFMT_D24S8: EnumD3DFORMAT - D3DFMT_D24X8: EnumD3DFORMAT - D3DFMT_D24X4S4: EnumD3DFORMAT D3DFMT_D16: EnumD3DFORMAT - D3DFMT_D32F_LOCKABLE: EnumD3DFORMAT + D3DFMT_D16_LOCKABLE: EnumD3DFORMAT D3DFMT_D24FS8: EnumD3DFORMAT - D3DFMT_L16: EnumD3DFORMAT - D3DFMT_VERTEXDATA: EnumD3DFORMAT + D3DFMT_D24S8: EnumD3DFORMAT + D3DFMT_D24X4S4: EnumD3DFORMAT + D3DFMT_D24X8: EnumD3DFORMAT + D3DFMT_D32: EnumD3DFORMAT + D3DFMT_D32F_LOCKABLE: EnumD3DFORMAT + D3DFMT_G16R16: EnumD3DFORMAT + D3DFMT_G16R16F: EnumD3DFORMAT + D3DFMT_G32R32F: EnumD3DFORMAT D3DFMT_INDEX16: EnumD3DFORMAT D3DFMT_INDEX32: EnumD3DFORMAT + D3DFMT_L16: EnumD3DFORMAT + D3DFMT_L6V5U5: EnumD3DFORMAT + D3DFMT_L8: EnumD3DFORMAT + D3DFMT_P8: EnumD3DFORMAT D3DFMT_Q16W16V16U16: EnumD3DFORMAT + D3DFMT_Q8W8V8U8: EnumD3DFORMAT D3DFMT_R16F: EnumD3DFORMAT - D3DFMT_G16R16F: EnumD3DFORMAT - D3DFMT_A16B16G16R16F: EnumD3DFORMAT D3DFMT_R32F: EnumD3DFORMAT - D3DFMT_G32R32F: EnumD3DFORMAT - D3DFMT_A32B32G32R32F: EnumD3DFORMAT - D3DFMT_CxV8U8: EnumD3DFORMAT + D3DFMT_R3G3B2: EnumD3DFORMAT + D3DFMT_R5G6B5: EnumD3DFORMAT + D3DFMT_R8G8B8: EnumD3DFORMAT + D3DFMT_UNKNOWN: EnumD3DFORMAT + D3DFMT_V16U16: EnumD3DFORMAT + D3DFMT_V8U8: EnumD3DFORMAT + D3DFMT_VERTEXDATA: EnumD3DFORMAT + D3DFMT_X1R5G5B5: EnumD3DFORMAT + D3DFMT_X4R4G4B4: EnumD3DFORMAT + D3DFMT_X8B8G8R8: EnumD3DFORMAT + D3DFMT_X8L8V8U8: EnumD3DFORMAT + D3DFMT_X8R8G8B8: EnumD3DFORMAT end declare class EnumDialogPurpose extends EnumItem end declare class EnumDialogPurpose_INTERNAL extends Enum - Quest: EnumDialogPurpose Help: EnumDialogPurpose + Quest: EnumDialogPurpose Shop: EnumDialogPurpose end declare class EnumDialogTone extends EnumItem end declare class EnumDialogTone_INTERNAL extends Enum - Neutral: EnumDialogTone - Friendly: EnumDialogTone Enemy: EnumDialogTone + Friendly: EnumDialogTone + Neutral: EnumDialogTone end declare class EnumEasingDirection extends EnumItem end declare class EnumEasingDirection_INTERNAL extends Enum In: EnumEasingDirection - Out: EnumEasingDirection InOut: EnumEasingDirection + Out: EnumEasingDirection end declare class EnumEasingStyle extends EnumItem end declare class EnumEasingStyle_INTERNAL extends Enum - Linear: EnumEasingStyle - Sine: EnumEasingStyle Back: EnumEasingStyle + Bounce: EnumEasingStyle + Elastic: EnumEasingStyle + Linear: EnumEasingStyle Quad: EnumEasingStyle Quart: EnumEasingStyle Quint: EnumEasingStyle - Bounce: EnumEasingStyle - Elastic: EnumEasingStyle + Sine: EnumEasingStyle end declare class EnumEnviromentalPhysicsThrottle extends EnumItem end declare class EnumEnviromentalPhysicsThrottle_INTERNAL extends Enum + Always: EnumEnviromentalPhysicsThrottle DefaultAuto: EnumEnviromentalPhysicsThrottle Disabled: EnumEnviromentalPhysicsThrottle - Always: EnumEnviromentalPhysicsThrottle + Skip16: EnumEnviromentalPhysicsThrottle Skip2: EnumEnviromentalPhysicsThrottle Skip4: EnumEnviromentalPhysicsThrottle Skip8: EnumEnviromentalPhysicsThrottle - Skip16: EnumEnviromentalPhysicsThrottle end declare class EnumErrorReporting extends EnumItem end declare class EnumErrorReporting_INTERNAL extends Enum @@ -329,27 +315,25 @@ declare class EnumErrorReporting_INTERNAL extends Enum end declare class EnumExplosionType extends EnumItem end declare class EnumExplosionType_INTERNAL extends Enum - NoCraters: EnumExplosionType Craters: EnumExplosionType CratersAndDebris: EnumExplosionType + NoCraters: EnumExplosionType end declare class EnumFilterResult extends EnumItem end declare class EnumFilterResult_INTERNAL extends Enum - Rejected: EnumFilterResult Accepted: EnumFilterResult + Rejected: EnumFilterResult end declare class EnumFont extends EnumItem end declare class EnumFont_INTERNAL extends Enum - Legacy: EnumFont Arial: EnumFont ArialBold: EnumFont + Legacy: EnumFont SourceSans: EnumFont SourceSansBold: EnumFont end declare class EnumFontSize extends EnumItem end declare class EnumFontSize_INTERNAL extends Enum - Size8: EnumFontSize - Size9: EnumFontSize Size10: EnumFontSize Size11: EnumFontSize Size12: EnumFontSize @@ -358,49 +342,51 @@ declare class EnumFontSize_INTERNAL extends Enum Size24: EnumFontSize Size36: EnumFontSize Size48: EnumFontSize + Size8: EnumFontSize + Size9: EnumFontSize end declare class EnumFormFactor extends EnumItem end declare class EnumFormFactor_INTERNAL extends Enum - Symmetric: EnumFormFactor Brick: EnumFormFactor - Plate: EnumFormFactor Custom: EnumFormFactor + Plate: EnumFormFactor + Symmetric: EnumFormFactor end declare class EnumFrameStyle extends EnumItem end declare class EnumFrameStyle_INTERNAL extends Enum - Custom: EnumFrameStyle ChatBlue: EnumFrameStyle - RobloxSquare: EnumFrameStyle - RobloxRound: EnumFrameStyle ChatGreen: EnumFrameStyle ChatRed: EnumFrameStyle + Custom: EnumFrameStyle + RobloxRound: EnumFrameStyle + RobloxSquare: EnumFrameStyle end declare class EnumFramerateManagerMode extends EnumItem end declare class EnumFramerateManagerMode_INTERNAL extends Enum Automatic: EnumFramerateManagerMode - On: EnumFramerateManagerMode Off: EnumFramerateManagerMode + On: EnumFramerateManagerMode end declare class EnumFriendRequestEvent extends EnumItem end declare class EnumFriendRequestEvent_INTERNAL extends Enum - Issue: EnumFriendRequestEvent - Revoke: EnumFriendRequestEvent Accept: EnumFriendRequestEvent Deny: EnumFriendRequestEvent + Issue: EnumFriendRequestEvent + Revoke: EnumFriendRequestEvent end declare class EnumFriendStatus extends EnumItem end declare class EnumFriendStatus_INTERNAL extends Enum - Unknown: EnumFriendStatus - NotFriend: EnumFriendStatus Friend: EnumFriendStatus - FriendRequestSent: EnumFriendStatus FriendRequestReceived: EnumFriendStatus + FriendRequestSent: EnumFriendStatus + NotFriend: EnumFriendStatus + Unknown: EnumFriendStatus end declare class EnumFunctionalTestResult extends EnumItem end declare class EnumFunctionalTestResult_INTERNAL extends Enum + Error: EnumFunctionalTestResult Passed: EnumFunctionalTestResult Warning: EnumFunctionalTestResult - Error: EnumFunctionalTestResult end declare class EnumGearGenreSetting extends EnumItem end declare class EnumGearGenreSetting_INTERNAL extends Enum @@ -409,58 +395,58 @@ declare class EnumGearGenreSetting_INTERNAL extends Enum end declare class EnumGearType extends EnumItem end declare class EnumGearType_INTERNAL extends Enum - MeleeWeapons: EnumGearType - RangedWeapons: EnumGearType - Explosives: EnumGearType - PowerUps: EnumGearType - NavigationEnhancers: EnumGearType - MusicalInstruments: EnumGearType - SocialItems: EnumGearType BuildingTools: EnumGearType + Explosives: EnumGearType + MeleeWeapons: EnumGearType + MusicalInstruments: EnumGearType + NavigationEnhancers: EnumGearType + PowerUps: EnumGearType + RangedWeapons: EnumGearType + SocialItems: EnumGearType Transport: EnumGearType end declare class EnumGenre extends EnumItem end declare class EnumGenre_INTERNAL extends Enum - All: EnumGenre - TownAndCity: EnumGenre - Fantasy: EnumGenre - SciFi: EnumGenre - Ninja: EnumGenre - Scary: EnumGenre - Pirate: EnumGenre Adventure: EnumGenre - Sports: EnumGenre + All: EnumGenre + Fantasy: EnumGenre Funny: EnumGenre - WildWest: EnumGenre - War: EnumGenre + Ninja: EnumGenre + Pirate: EnumGenre + Scary: EnumGenre + SciFi: EnumGenre SkatePark: EnumGenre + Sports: EnumGenre + TownAndCity: EnumGenre Tutorial: EnumGenre + War: EnumGenre + WildWest: EnumGenre end declare class EnumGraphicsMode extends EnumItem end declare class EnumGraphicsMode_INTERNAL extends Enum Automatic: EnumGraphicsMode Direct3D: EnumGraphicsMode - OpenGL: EnumGraphicsMode NoGraphics: EnumGraphicsMode + OpenGL: EnumGraphicsMode end declare class EnumHandlesStyle extends EnumItem end declare class EnumHandlesStyle_INTERNAL extends Enum - Resize: EnumHandlesStyle Movement: EnumHandlesStyle + Resize: EnumHandlesStyle end declare class EnumHttpContentType extends EnumItem end declare class EnumHttpContentType_INTERNAL extends Enum ApplicationJson: EnumHttpContentType - ApplicationXml: EnumHttpContentType ApplicationUrlEncoded: EnumHttpContentType + ApplicationXml: EnumHttpContentType TextPlain: EnumHttpContentType TextXml: EnumHttpContentType end declare class EnumInOut extends EnumItem end declare class EnumInOut_INTERNAL extends Enum + Center: EnumInOut Edge: EnumInOut Inset: EnumInOut - Center: EnumInOut end declare class EnumInfoType extends EnumItem end declare class EnumInfoType_INTERNAL extends Enum @@ -469,125 +455,125 @@ declare class EnumInfoType_INTERNAL extends Enum end declare class EnumInputType extends EnumItem end declare class EnumInputType_INTERNAL extends Enum - NoInput: EnumInputType - LeftTread: EnumInputType - RightTread: EnumInputType - Steer: EnumInputType - Throtle: EnumInputType - UpDown: EnumInputType Action1: EnumInputType Action2: EnumInputType Action3: EnumInputType Action4: EnumInputType Action5: EnumInputType Constant: EnumInputType + LeftTread: EnumInputType + NoInput: EnumInputType + RightTread: EnumInputType Sin: EnumInputType + Steer: EnumInputType + Throtle: EnumInputType + UpDown: EnumInputType end declare class EnumJointType extends EnumItem end declare class EnumJointType_INTERNAL extends Enum + Glue: EnumJointType None: EnumJointType Rotate: EnumJointType RotateP: EnumJointType RotateV: EnumJointType - Glue: EnumJointType - Weld: EnumJointType Snap: EnumJointType + Weld: EnumJointType end declare class EnumKeywordFilterType extends EnumItem end declare class EnumKeywordFilterType_INTERNAL extends Enum - Include: EnumKeywordFilterType Exclude: EnumKeywordFilterType + Include: EnumKeywordFilterType end declare class EnumLeftRight extends EnumItem end declare class EnumLeftRight_INTERNAL extends Enum - Left: EnumLeftRight Center: EnumLeftRight + Left: EnumLeftRight Right: EnumLeftRight end declare class EnumLevelOfDetailSetting extends EnumItem end declare class EnumLevelOfDetailSetting_INTERNAL extends Enum High: EnumLevelOfDetailSetting - Medium: EnumLevelOfDetailSetting Low: EnumLevelOfDetailSetting + Medium: EnumLevelOfDetailSetting end declare class EnumMaterial extends EnumItem end declare class EnumMaterial_INTERNAL extends Enum - Plastic: EnumMaterial - Wood: EnumMaterial - Slate: EnumMaterial + Brick: EnumMaterial Concrete: EnumMaterial CorrodedMetal: EnumMaterial DiamondPlate: EnumMaterial + Fabric: EnumMaterial Foil: EnumMaterial + Granite: EnumMaterial Grass: EnumMaterial Ice: EnumMaterial Marble: EnumMaterial - Granite: EnumMaterial - Brick: EnumMaterial Pebble: EnumMaterial + Plastic: EnumMaterial Sand: EnumMaterial - Fabric: EnumMaterial + Slate: EnumMaterial SmoothPlastic: EnumMaterial + Wood: EnumMaterial end declare class EnumMembershipType extends EnumItem end declare class EnumMembershipType_INTERNAL extends Enum - None: EnumMembershipType BuildersClub: EnumMembershipType - TurboBuildersClub: EnumMembershipType + None: EnumMembershipType OutrageousBuildersClub: EnumMembershipType + TurboBuildersClub: EnumMembershipType end declare class EnumMeshType extends EnumItem end declare class EnumMeshType_INTERNAL extends Enum - Head: EnumMeshType - Torso: EnumMeshType - Wedge: EnumMeshType - Prism: EnumMeshType - Pyramid: EnumMeshType - ParallelRamp: EnumMeshType - RightAngleRamp: EnumMeshType - CornerWedge: EnumMeshType Brick: EnumMeshType - Sphere: EnumMeshType + CornerWedge: EnumMeshType Cylinder: EnumMeshType FileMesh: EnumMeshType + Head: EnumMeshType + ParallelRamp: EnumMeshType + Prism: EnumMeshType + Pyramid: EnumMeshType + RightAngleRamp: EnumMeshType + Sphere: EnumMeshType + Torso: EnumMeshType + Wedge: EnumMeshType end declare class EnumMoveState extends EnumItem end declare class EnumMoveState_INTERNAL extends Enum - Stopped: EnumMoveState + AirFree: EnumMoveState Coasting: EnumMoveState Pushing: EnumMoveState + Stopped: EnumMoveState Stopping: EnumMoveState - AirFree: EnumMoveState end declare class EnumNameOcclusion extends EnumItem end declare class EnumNameOcclusion_INTERNAL extends Enum - OccludeAll: EnumNameOcclusion EnemyOcclusion: EnumNameOcclusion NoOcclusion: EnumNameOcclusion + OccludeAll: EnumNameOcclusion end declare class EnumNormalId extends EnumItem end declare class EnumNormalId_INTERNAL extends Enum - Top: EnumNormalId - Bottom: EnumNormalId Back: EnumNormalId + Bottom: EnumNormalId Front: EnumNormalId - Right: EnumNormalId Left: EnumNormalId + Right: EnumNormalId + Top: EnumNormalId end declare class EnumPacketPriority extends EnumItem end declare class EnumPacketPriority_INTERNAL extends Enum - IMMEDIATE_PRIORITY: EnumPacketPriority HIGH_PRIORITY: EnumPacketPriority - MEDIUM_PRIORITY: EnumPacketPriority + IMMEDIATE_PRIORITY: EnumPacketPriority LOW_PRIORITY: EnumPacketPriority + MEDIUM_PRIORITY: EnumPacketPriority end declare class EnumPacketReliability extends EnumItem end declare class EnumPacketReliability_INTERNAL extends Enum - UNRELIABLE: EnumPacketReliability - UNRELIABLE_SEQUENCED: EnumPacketReliability RELIABLE: EnumPacketReliability RELIABLE_ORDERED: EnumPacketReliability RELIABLE_SEQUENCED: EnumPacketReliability + UNRELIABLE: EnumPacketReliability + UNRELIABLE_SEQUENCED: EnumPacketReliability end declare class EnumPartType extends EnumItem end declare class EnumPartType_INTERNAL extends Enum @@ -615,37 +601,37 @@ declare class EnumPlayerChatType_INTERNAL extends Enum end declare class EnumPriorityMethod extends EnumItem end declare class EnumPriorityMethod_INTERNAL extends Enum - LastError: EnumPriorityMethod AccumulatedError: EnumPriorityMethod FIFO: EnumPriorityMethod + LastError: EnumPriorityMethod +end +declare class EnumPrismSides extends EnumItem end +declare class EnumPrismSides_INTERNAL extends Enum + ["10"]: EnumPrismSides + ["20"]: EnumPrismSides + ["3"]: EnumPrismSides + ["5"]: EnumPrismSides + ["6"]: EnumPrismSides + ["8"]: EnumPrismSides end --- declare class EnumPrismSides extends EnumItem end --- declare class EnumPrismSides_INTERNAL extends Enum --- ["3"]: EnumPrismSides --- ["5"]: EnumPrismSides --- ["6"]: EnumPrismSides --- ["8"]: EnumPrismSides --- ["10"]: EnumPrismSides --- ["20"]: EnumPrismSides --- end declare class EnumPrivilegeType extends EnumItem end declare class EnumPrivilegeType_INTERNAL extends Enum - Owner: EnumPrivilegeType Admin: EnumPrivilegeType - Member: EnumPrivilegeType - Visitor: EnumPrivilegeType Banned: EnumPrivilegeType + Member: EnumPrivilegeType + Owner: EnumPrivilegeType + Visitor: EnumPrivilegeType +end +declare class EnumPyramidSides extends EnumItem end +declare class EnumPyramidSides_INTERNAL extends Enum + ["10"]: EnumPyramidSides + ["20"]: EnumPyramidSides + ["3"]: EnumPyramidSides + ["4"]: EnumPyramidSides + ["5"]: EnumPyramidSides + ["6"]: EnumPyramidSides + ["8"]: EnumPyramidSides end --- declare class EnumPyramidSides extends EnumItem end --- declare class EnumPyramidSides_INTERNAL extends Enum --- ["3"]: EnumPyramidSides --- ["4"]: EnumPyramidSides --- ["5"]: EnumPyramidSides --- ["6"]: EnumPyramidSides --- ["8"]: EnumPyramidSides --- ["10"]: EnumPyramidSides --- ["20"]: EnumPyramidSides --- end declare class EnumQualityLevel extends EnumItem end declare class EnumQualityLevel_INTERNAL extends Enum Automatic: EnumQualityLevel @@ -673,69 +659,70 @@ declare class EnumQualityLevel_INTERNAL extends Enum end declare class EnumResolution extends EnumItem end declare class EnumResolution_INTERNAL extends Enum - Automatic: EnumResolution - ["720x526"]: EnumResolution - ["800x600"]: EnumResolution ["1024x600"]: EnumResolution ["1024x768"]: EnumResolution + ["1152x864"]: EnumResolution + ["1280x1024"]: EnumResolution ["1280x720"]: EnumResolution ["1280x768"]: EnumResolution - ["1152x864"]: EnumResolution ["1280x800"]: EnumResolution - ["1360x768"]: EnumResolution ["1280x960"]: EnumResolution - ["1280x1024"]: EnumResolution + ["1360x768"]: EnumResolution ["1440x900"]: EnumResolution - ["1600x900"]: EnumResolution ["1600x1024"]: EnumResolution ["1600x1200"]: EnumResolution + ["1600x900"]: EnumResolution ["1680x1050"]: EnumResolution ["1920x1080"]: EnumResolution ["1920x1200"]: EnumResolution + ["720x526"]: EnumResolution + ["800x600"]: EnumResolution + Automatic: EnumResolution end declare class EnumReverbType extends EnumItem end declare class EnumReverbType_INTERNAL extends Enum - NoReverb: EnumReverbType - GenericReverb: EnumReverbType - PaddedCell: EnumReverbType - Room: EnumReverbType - Bathroom: EnumReverbType - LivingRoom: EnumReverbType - StoneRoom: EnumReverbType - Auditorium: EnumReverbType - ConcertHall: EnumReverbType - Cave: EnumReverbType - Arena: EnumReverbType - Hangar: EnumReverbType - CarpettedHallway: EnumReverbType - Hallway: EnumReverbType - StoneCorridor: EnumReverbType Alley: EnumReverbType - Forest: EnumReverbType + Arena: EnumReverbType + Auditorium: EnumReverbType + Bathroom: EnumReverbType + CarpettedHallway: EnumReverbType + Cave: EnumReverbType City: EnumReverbType + ConcertHall: EnumReverbType + Forest: EnumReverbType + GenericReverb: EnumReverbType + Hallway: EnumReverbType + Hangar: EnumReverbType + LivingRoom: EnumReverbType Mountains: EnumReverbType - Quarry: EnumReverbType - Plain: EnumReverbType + NoReverb: EnumReverbType + PaddedCell: EnumReverbType ParkingLot: EnumReverbType + Plain: EnumReverbType + Quarry: EnumReverbType + Room: EnumReverbType SewerPipe: EnumReverbType + StoneCorridor: EnumReverbType + StoneRoom: EnumReverbType UnderWater: EnumReverbType end declare class EnumRuntimeUndoBehavior extends EnumItem end declare class EnumRuntimeUndoBehavior_INTERNAL extends Enum Aggregate: EnumRuntimeUndoBehavior - Snapshot: EnumRuntimeUndoBehavior Hybrid: EnumRuntimeUndoBehavior + Snapshot: EnumRuntimeUndoBehavior end declare class EnumSaveFilter extends EnumItem end declare class EnumSaveFilter_INTERNAL extends Enum SaveAll: EnumSaveFilter - SaveWorld: EnumSaveFilter SaveGame: EnumSaveFilter + SaveWorld: EnumSaveFilter end declare class EnumSavedQualitySetting extends EnumItem end declare class EnumSavedQualitySetting_INTERNAL extends Enum Automatic: EnumSavedQualitySetting QualityLevel1: EnumSavedQualitySetting + QualityLevel10: EnumSavedQualitySetting QualityLevel2: EnumSavedQualitySetting QualityLevel3: EnumSavedQualitySetting QualityLevel4: EnumSavedQualitySetting @@ -744,38 +731,37 @@ declare class EnumSavedQualitySetting_INTERNAL extends Enum QualityLevel7: EnumSavedQualitySetting QualityLevel8: EnumSavedQualitySetting QualityLevel9: EnumSavedQualitySetting - QualityLevel10: EnumSavedQualitySetting end declare class EnumShadow extends EnumItem end declare class EnumShadow_INTERNAL extends Enum - Automatic: EnumShadow All: EnumShadow + Automatic: EnumShadow CharacterOnly: EnumShadow Off: EnumShadow end declare class EnumSizeConstraint extends EnumItem end declare class EnumSizeConstraint_INTERNAL extends Enum - RelativeXY: EnumSizeConstraint RelativeXX: EnumSizeConstraint + RelativeXY: EnumSizeConstraint RelativeYY: EnumSizeConstraint end declare class EnumSleepAdjustMethod extends EnumItem end declare class EnumSleepAdjustMethod_INTERNAL extends Enum - None: EnumSleepAdjustMethod - LastSample: EnumSleepAdjustMethod AverageInterval: EnumSleepAdjustMethod + LastSample: EnumSleepAdjustMethod + None: EnumSleepAdjustMethod end -declare class EnumSoundType extends EnumItem end -- this is the most pre-any-decent-level-of-lua-understanding thing I've ever seen +declare class EnumSoundType extends EnumItem end declare class EnumSoundType_INTERNAL extends Enum - NoSound: EnumSoundType Boing: EnumSoundType Bomb: EnumSoundType Break: EnumSoundType Click: EnumSoundType Clock: EnumSoundType - Slingshot: EnumSoundType + NoSound: EnumSoundType Page: EnumSoundType Ping: EnumSoundType + Slingshot: EnumSoundType Snap: EnumSoundType Splat: EnumSoundType Step: EnumSoundType @@ -785,34 +771,34 @@ declare class EnumSoundType_INTERNAL extends Enum end declare class EnumSpecialKey extends EnumItem end declare class EnumSpecialKey_INTERNAL extends Enum - Insert: EnumSpecialKey - Home: EnumSpecialKey - End: EnumSpecialKey - PageUp: EnumSpecialKey - PageDown: EnumSpecialKey ChatHotkey: EnumSpecialKey + End: EnumSpecialKey + Home: EnumSpecialKey + Insert: EnumSpecialKey + PageDown: EnumSpecialKey + PageUp: EnumSpecialKey end declare class EnumStatus extends EnumItem end declare class EnumStatus_INTERNAL extends Enum - Poison: EnumStatus Confusion: EnumStatus + Poison: EnumStatus end declare class EnumStuff extends EnumItem end declare class EnumStuff_INTERNAL extends Enum - Heads: EnumStuff - Faces: EnumStuff - Hats: EnumStuff - TShirts: EnumStuff - Shirts: EnumStuff - Pants: EnumStuff - Gears: EnumStuff - Torsos: EnumStuff - LeftArms: EnumStuff - RightArms: EnumStuff - LeftLegs: EnumStuff - RightLegs: EnumStuff Bodies: EnumStuff Costumes: EnumStuff + Faces: EnumStuff + Gears: EnumStuff + Hats: EnumStuff + Heads: EnumStuff + LeftArms: EnumStuff + LeftLegs: EnumStuff + Pants: EnumStuff + RightArms: EnumStuff + RightLegs: EnumStuff + Shirts: EnumStuff + TShirts: EnumStuff + Torsos: EnumStuff end declare class EnumStyle extends EnumItem end declare class EnumStyle_INTERNAL extends Enum @@ -822,52 +808,52 @@ declare class EnumStyle_INTERNAL extends Enum end declare class EnumSurfaceConstraint extends EnumItem end declare class EnumSurfaceConstraint_INTERNAL extends Enum - None: EnumSurfaceConstraint Hinge: EnumSurfaceConstraint - SteppingMotor: EnumSurfaceConstraint Motor: EnumSurfaceConstraint + None: EnumSurfaceConstraint + SteppingMotor: EnumSurfaceConstraint end declare class EnumSurfaceType extends EnumItem end declare class EnumSurfaceType_INTERNAL extends Enum - Smooth: EnumSurfaceType Glue: EnumSurfaceType - Weld: EnumSurfaceType - Studs: EnumSurfaceType - Inlet: EnumSurfaceType - Universal: EnumSurfaceType Hinge: EnumSurfaceType + Inlet: EnumSurfaceType Motor: EnumSurfaceType - SteppingMotor: EnumSurfaceType - Unjoinable: EnumSurfaceType + Smooth: EnumSurfaceType SmoothNoOutlines: EnumSurfaceType + SteppingMotor: EnumSurfaceType + Studs: EnumSurfaceType + Universal: EnumSurfaceType + Unjoinable: EnumSurfaceType + Weld: EnumSurfaceType end declare class EnumSwipeDirection extends EnumItem end declare class EnumSwipeDirection_INTERNAL extends Enum - Right: EnumSwipeDirection - Left: EnumSwipeDirection - Up: EnumSwipeDirection Down: EnumSwipeDirection + Left: EnumSwipeDirection None: EnumSwipeDirection + Right: EnumSwipeDirection + Up: EnumSwipeDirection end declare class EnumTeleportState extends EnumItem end declare class EnumTeleportState_INTERNAL extends Enum + Failed: EnumTeleportState + InProgress: EnumTeleportState RequestedFromServer: EnumTeleportState Started: EnumTeleportState WaitingForServer: EnumTeleportState - Failed: EnumTeleportState - InProgress: EnumTeleportState end declare class EnumTextXAlignment extends EnumItem end declare class EnumTextXAlignment_INTERNAL extends Enum - Left: EnumTextXAlignment Center: EnumTextXAlignment + Left: EnumTextXAlignment Right: EnumTextXAlignment end declare class EnumTextYAlignment extends EnumItem end declare class EnumTextYAlignment_INTERNAL extends Enum - Top: EnumTextYAlignment - Center: EnumTextYAlignment Bottom: EnumTextYAlignment + Center: EnumTextYAlignment + Top: EnumTextYAlignment end declare class EnumThreadPoolConfig extends EnumItem end declare class EnumThreadPoolConfig_INTERNAL extends Enum @@ -877,23 +863,23 @@ declare class EnumThreadPoolConfig_INTERNAL extends Enum PerCore3: EnumThreadPoolConfig PerCore4: EnumThreadPoolConfig Threads1: EnumThreadPoolConfig + Threads16: EnumThreadPoolConfig Threads2: EnumThreadPoolConfig Threads3: EnumThreadPoolConfig Threads4: EnumThreadPoolConfig Threads8: EnumThreadPoolConfig - Threads16: EnumThreadPoolConfig end declare class EnumTickCountSampleMethod extends EnumItem end declare class EnumTickCountSampleMethod_INTERNAL extends Enum - Fast: EnumTickCountSampleMethod Benchmark: EnumTickCountSampleMethod + Fast: EnumTickCountSampleMethod Precise: EnumTickCountSampleMethod end declare class EnumTopBottom extends EnumItem end declare class EnumTopBottom_INTERNAL extends Enum - Top: EnumTopBottom - Center: EnumTopBottom Bottom: EnumTopBottom + Center: EnumTopBottom + Top: EnumTopBottom end declare class EnumTweenStatus extends EnumItem end declare class EnumTweenStatus_INTERNAL extends Enum @@ -902,9 +888,9 @@ declare class EnumTweenStatus_INTERNAL extends Enum end declare class EnumUploadSetting extends EnumItem end declare class EnumUploadSetting_INTERNAL extends Enum - Never: EnumUploadSetting - Ask: EnumUploadSetting Always: EnumUploadSetting + Ask: EnumUploadSetting + Never: EnumUploadSetting end declare class EnumUserInputState extends EnumItem end declare class EnumUserInputState_INTERNAL extends Enum @@ -915,43 +901,41 @@ declare class EnumUserInputState_INTERNAL extends Enum end declare class EnumUserInputType extends EnumItem end declare class EnumUserInputType_INTERNAL extends Enum + Focus: EnumUserInputType + Keyboard: EnumUserInputType MouseButton1: EnumUserInputType MouseButton2: EnumUserInputType MouseButton3: EnumUserInputType - MouseWheel: EnumUserInputType MouseMovement: EnumUserInputType - Touch: EnumUserInputType - Keyboard: EnumUserInputType - Focus: EnumUserInputType + MouseWheel: EnumUserInputType None: EnumUserInputType + Touch: EnumUserInputType end declare class EnumVideoQualitySettings extends EnumItem end declare class EnumVideoQualitySettings_INTERNAL extends Enum + HighResolution: EnumVideoQualitySettings LowResolution: EnumVideoQualitySettings MediumResolution: EnumVideoQualitySettings - HighResolution: EnumVideoQualitySettings end declare class EnumWaterDirection extends EnumItem end declare class EnumWaterDirection_INTERNAL extends Enum NegX: EnumWaterDirection - X: EnumWaterDirection NegY: EnumWaterDirection - Y: EnumWaterDirection NegZ: EnumWaterDirection + X: EnumWaterDirection + Y: EnumWaterDirection Z: EnumWaterDirection end declare class EnumWaterForce extends EnumItem end declare class EnumWaterForce_INTERNAL extends Enum + Max: EnumWaterForce + Medium: EnumWaterForce None: EnumWaterForce Small: EnumWaterForce - Medium: EnumWaterForce Strong: EnumWaterForce - Max: EnumWaterForce end - - type ENUM_LIST = { AASamples: EnumAASamples_INTERNAL, AccessType: EnumAccessType_INTERNAL, @@ -1022,9 +1006,9 @@ type ENUM_LIST = { PhysicsSendMethod: EnumPhysicsSendMethod_INTERNAL, PlayerChatType: EnumPlayerChatType_INTERNAL, PriorityMethod: EnumPriorityMethod_INTERNAL, - -- PrismSides: EnumPrismSides_INTERNAL, + PrismSides: EnumPrismSides_INTERNAL, PrivilegeType: EnumPrivilegeType_INTERNAL, - -- PyramidSides: EnumPyramidSides_INTERNAL, + PyramidSides: EnumPyramidSides_INTERNAL, QualityLevel: EnumQualityLevel_INTERNAL, Resolution: EnumResolution_INTERNAL, ReverbType: EnumReverbType_INTERNAL, @@ -1070,15 +1054,6 @@ declare class Axes Z: boolean end -declare class Color3 - b: number - g: number - r: number - function Lerp(self, color: Color3, alpha: number): Color3 - function ToHSV(self): (number, number, number) - function ToHex(self): string -end - declare class BrickColor Color: Color3 Name: string @@ -1088,11 +1063,35 @@ declare class BrickColor r: number end -declare class Enums - function GetEnums(self): { Enum } +declare class CFrame + X: number + Y: number + Z: number + function __add(self, other: Vector3): CFrame + function __mul(self, other: CFrame): CFrame + function __mul(self, other: Vector3): Vector3 + function __sub(self, other: Vector3): CFrame + function components(self): (number, number, number, number, number, number, number, number, number, number, number, number) + function inverse(self): CFrame + function pointToObjectSpace(self, v3: Vector3): Vector3 + function pointToWorldSpace(self, v3: Vector3): Vector3 + function toObjectSpace(self, cf: CFrame): CFrame + function toWorldSpace(self, cf: CFrame): CFrame + function vectorToObjectSpace(self, v3: Vector3): Vector3 + function vectorToWorldSpace(self, v3: Vector3): Vector3 + lookVector: Vector3 + p: Vector3 end -declare class Faces -- no, every class doesn't have to be an instance +declare class Color3 + b: number + g: number + r: number +end + + + +declare class Faces Back: boolean Bottom: boolean Front: boolean @@ -1103,7 +1102,27 @@ end declare class RBXScriptConnection connected: boolean - function disconnect(self): nil + function disconnect(self): () +end + + + +declare class Ray + Direction: Vector3 + Origin: Vector3 + Unit: Ray + function ClosestPoint(self, point: Vector3): Vector3 + function Distance(self, point: Vector3): number +end + +declare class Region3 + CFrame: CFrame + Size: Vector3 +end + +declare class Region3int16 + Max: Vector3int16 + Min: Vector3int16 end declare class UDim @@ -1125,24 +1144,16 @@ declare class UDim2 end declare class Vector2 - magnitude: number - unit: Vector2 X: number Y: number - x: number - y: number function __add(self, other: Vector2): Vector2 function __div(self, other: Vector2 | number): Vector2 function __mul(self, other: Vector2 | number): Vector2 function __sub(self, other: Vector2): Vector2 function __unm(self): Vector2 -end - -declare class Rect - Height: number - Max: Vector2 - Min: Vector2 - Width: number + function lerp(self, v: Vector2, alpha: number): Vector2 + magnitude: number + unit: Vector2 end declare class Vector2int16 @@ -1157,19 +1168,12 @@ end declare class Vector3 Magnitude: number - magnitude: number Unit: Vector3 - unit: Vector3 X: number - x: number Y: number - y: number Z: number - z: number - function Angle(self, other: Vector3, axis: Vector3?): number function Cross(self, other: Vector3): Vector3 function Dot(self, other: Vector3): number - function FuzzyEq(self, other: Vector3, epsilon: number): boolean function Lerp(self, goal: Vector3, alpha: number): Vector3 function __add(self, other: Vector3): Vector3 function __div(self, other: Vector3 | number): Vector3 @@ -1178,48 +1182,6 @@ declare class Vector3 function __unm(self): Vector3 end -declare class RaycastResult - Distance: number - Instance: Instance - Material: EnumMaterial - Normal: Vector3 - Position: Vector3 -end - -declare class Ray - Direction: Vector3 - Origin: Vector3 - Unit: Ray - function ClosestPoint(self, point: Vector3): Vector3 - function Distance(self, point: Vector3): number -end - -declare class CFrame - lookVector: Vector3 - p: Vector3 - X: number - Y: number - Z: number - function inverse(self): CFrame - function pointToObjectSpace(self, v3: Vector3): Vector3 - function pointToWorldSpace(self, v3: Vector3): Vector3 - function toEulerAnglesXYZ(self): (number, number, number) - function toObjectSpace(self, cf: CFrame): CFrame - function toWorldSpace(self, cf: CFrame): CFrame - function vectorToObjectSpace(self, v3: Vector3): Vector3 - function vectorToWorldSpace(self, v3: Vector3): Vector3 - function __add(self, other: Vector3): CFrame - function __mul(self, other: CFrame): CFrame - function __mul(self, other: Vector3): Vector3 - function __sub(self, other: Vector3): CFrame -end - -declare class Region3 - CFrame: CFrame - Size: Vector3 - function ExpandToGrid(self, Region: number): Region3 -end - declare class Vector3int16 X: number Y: number @@ -1231,16 +1193,11 @@ declare class Vector3int16 function __unm(self): Vector3int16 end -declare class Region3int16 - Max: Vector3int16 - Min: Vector3int16 -end + export type RBXScriptSignal = { - wait: (self: RBXScriptSignal, time: number?) -> T..., + wait: (self: RBXScriptSignal) -> T..., connect: (self: RBXScriptSignal, callback: (T...) -> ()) -> RBXScriptConnection, - connectParallel: (self: RBXScriptSignal, callback: (T...) -> ()) -> RBXScriptConnection, - once: (self: RBXScriptSignal, callback: (T...) -> ()) -> RBXScriptConnection, } type HttpRequestOptions = { @@ -1258,244 +1215,31 @@ type HttpResponseData = { Body: string?, } --- lots of these types were previously declared as any, for the time being I think it's better to have them as their deprecated types than as any --- perhaps change later depending on whether they're still deprecated in 2013 - --- type Hat = any -declare class Hat extends Accoutrement -end - --- type RocketPropulsion = any -declare class RocketPropulsion extends BodyMover - CartoonFactor: number - MaxSpeed: number - MaxThrust: number - MaxTorque: Vector3 - ReachedTarget: RBXScriptSignal<> - Target: BasePart -- technically Object, but can you really tell? - TargetOffset: Vector3 - TargetRadius: number - ThrustD: number - ThrustP: number - TurnD: number - TurnP: number - - function Abort(self): nil - function Fire(self): nil -end - - --- type Skin = any -declare class Skin extends CharacterAppearance - SkinColor: BrickColor -end - --- type CustomEvent = any -declare class CustomEvent extends Instance - ReceiverConnected: RBXScriptSignal - ReceiverDisconnected: RBXScriptSignal - function GetAttachedReceivers(self): { CustomEventReceiver } -- tested - function SetValue(self, newValue: number): nil -- why only a float? -end - --- type CustomEventReceiver = any -declare class CustomEventReceiver extends Instance - EventConnected: RBXScriptSignal - EventDisconnected: RBXScriptSignal - Source: CustomEvent - SourceValueChange: RBXScriptSignal - function GetCurrentValue(self): number -end - --- type BevelMesh = any -- looong deprecated --- type CylinderMesh = any --- type Hole = any -declare class Hole extends Feature -end - --- type MotorFeature = any -declare class MotorFeature extends Feature -end - -type FunctionalTest = any --- type GuiMain = any -declare class GuiMain extends ScreenGui -end - --- type FloorWire = any -declare class FloorWire extends GuiBase3d -- This thing is awesome, why on earth was it deprecated - -- and I still won't grow up - -- I'm a grown ass kid - -- swear I should be locked up - -- for stupid shit that I did - -- but I'm a champion - -- so I turned tragedy to triumph - -- write code that's fire - -- spit my soul through the FloorWire - CycleOffset: number - From: BasePart - StudsBetweenTextures: number - Texture: Content - TextureSize: Vector2 - To: BasePart - Velocity: number - WireRadius: number -end - --- type SelectionPartLasso = any -declare class SelectionPartLasso extends SelectionLasso - Part: BasePart -end - -declare class GuiItem extends Instance -end - --- type Hopper = any -declare class Hopper extends GuiItem -end - --- type SelectionPointLasso = any -declare class SelectionPointLasso extends SelectionLasso - Point: Vector3 -end - --- type RotateP = any -declare class RotateP extends DynamicRotate -end - --- type RotateV = any -declare class RotateV extends DynamicRotate -end - --- type Glue = any -declare class Glue extends JointInstance - F0: Vector3 - F1: Vector3 - F2: Vector3 - F3: Vector3 -end - - --- type ManualSurfaceJointInstance = any -declare class ManualSurfaceJointInstance extends JointInstance -end - --- type ManualGlue = any -declare class ManualGlue extends ManualSurfaceJointInstance -end - --- type ManualWeld = any -declare class ManualWeld extends ManualSurfaceJointInstance -end - -type Rotate = any -type Snap = any --- type JointsService = any -declare class JointsService extends Instance - function ClearJoinAfterMoveJoints(self): nil - function CreateJoinAfterMoveJoints(self): nil - function SetJoinAfterMoveInstance(self, joinInstance: Instance): nil - function SetJoinAfterMoveTarget(self, joinTarget: Instance): nil - function ShowPermissibleJoints(self): nil -end - --- type Message = any -declare class Message extends Instance - Text: string -end - --- type Hint = any -declare class Hint extends Message -end - --- type FlagStand = any -declare class FlagStand extends Part - FlagCaptured: RBXScriptSignal -- probably player, though difficult to test - TeamColor: BrickColor -end - --- type SkateboardPlatform = any -declare class SkateboardPlatform extends Part - Controller: SkateboardController -- tested..? SkateboradController seems to appear out of nowhere and is parented to somewhere - ControllingHumanoid: Humanoid -- tested -end - --- type HopperBin = any -declare class HopperBin extends BackpackItem - Active: boolean - BinType: EnumBinType - Deselected: RBXScriptSignal<> - Selected: RBXScriptSignal - - function Disable(self): nil - function ToggleSelect(self): nil -end - --- turn it off and on again --- check the power supply --- it worked but now it's gone again --- one more thing that we can try! --- press Ctrl and try again --- it works, we don't know why --- system is alive again --- well thank you for calling, goodbye - --- type Flag = any -declare class Flag extends Tool - TeamColor: BrickColor -end - --- type Status = any -declare class Status extends Model -end - -type PointsService = any --- type DoubleConstrainedValue = any -declare class DoubleConstrainedValue extends Instance - Changed: RBXScriptSignal - ConstrainedValue: number - MaxValue: number - MinValue: number - Value: number -end - --- type IntConstrainedValue = any -declare class IntConstrainedValue extends Instance - Changed: RBXScriptSignal - ConstrainedValue: number - MaxValue: number - MinValue: number - Value: number -end - declare class Instance AncestryChanged: RBXScriptSignal Archivable: boolean - Changed: RBXScriptSignal -- anotha one of them property thingz + Changed: RBXScriptSignal ChildAdded: RBXScriptSignal ChildRemoved: RBXScriptSignal ClassName: string - DataCost: number DescendantAdded: RBXScriptSignal DescendantRemoving: RBXScriptSignal Name: string Parent: Instance? RobloxLocked: boolean - - function ClearAllChildren(self): nil + archivable: boolean + function ClearAllChildren(self): () function Clone(self): Instance - function Destroy(self): nil -- camelCase variant also exists - function Remove(self): nil -- camelCase variant also exists - function FindFirstChild(self, name: string, recursive: boolean?): Instance? -- camelCase variant also exists - function FindFirstDescendant(self, name: string): Instance? + function Destroy(self): () + function FindFirstChild(self, name: string, recursive: boolean?): Instance? function GetChildren(self): { Instance } function GetDebugId(self, scopeLength: number?): string function GetFullName(self): string - function IsA(self, className: string): boolean -- camelCase variant also exists - function IsAncestorOf(self, descendant: Instance): boolean -- deprecated camelCase variant also exists - function IsDescendantOf(self, ancestor: Instance): boolean -- camelCase variant also exists + function IsA(self, className: string): boolean + function IsAncestorOf(self, descendant: Instance): boolean + function IsDescendantOf(self, ancestor: Instance): boolean function WaitForChild(self, name: string): Instance - function WaitForChild(self, name: string, timeout: number): Instance? -- deprecated camelCase variant also exists + function WaitForChild(self, name: string, timeout: number): Instance? end declare class Accoutrement extends Instance @@ -1506,6 +1250,9 @@ declare class Accoutrement extends Instance AttachmentUp: Vector3 end +declare class Hat extends Accoutrement +end + declare class AdvancedDragger extends Instance end @@ -1514,15 +1261,18 @@ declare class Animation extends Instance end declare class AnimationController extends Instance - function LoadAnimation(self, animation: Animation): AnimationTrack + function LoadAnimation(self, animation: Animation): Instance end declare class AnimationTrack extends Instance KeyframeReached: RBXScriptSignal - function AdjustSpeed(self, speed: number?): nil - function AdjustWeight(self, weight: number?, fadeTime: number?): nil - function Play(self, fadeTime: number?, weight: number?, speed: number?): nil - function Stop(self, fadeTime: number?): nil + function AdjustSpeed(self, speed: number?): () + function AdjustWeight(self, weight: number?, fadeTime: number?): () + function Play(self, fadeTime: number?, weight: number?, speed: number?): () + function Stop(self, fadeTime: number?): () +end + +declare class AnimationTrackState extends Instance end declare class Animator extends Instance @@ -1530,42 +1280,35 @@ declare class Animator extends Instance end declare class AssetService extends Instance - function GetAssetVersions(self, placeId: number, pageNum: number): { any } + function GetAssetVersions(self, placeId: number, pageNum: number?): { [any]: any } function GetCreatorAssetID(self, creationID: number): number - function GetPlacePermissions(self, placeId: number): { any } + function GetPlacePermissions(self, placeId: number): { [any]: any } function RevertAsset(self, placeId: number, versionNumber: number): boolean - function SetAssetRevertUrl(self, revertUrl: string): nil - function SetAssetVersionsUrl(self, versionsUrl: string): nil - function SetPlaceAccessUrl(self, accessUrl: string): boolean - function SetPlacePermissions(self, placeId: number, accessType: EnumAccessType, inviteList: { any }): boolean -end - -declare class Backpack extends GuiItem + function SetAssetRevertUrl(self, revertUrl: string): () + function SetAssetVersionsUrl(self, versionsUrl: string): () + function SetPlaceAccessUrl(self, accessUrl: string): () + function SetPlacePermissions(self, placeId: number, accessType: EnumAccessType?, inviteList: { any }?): boolean end declare class BadgeService extends Instance - BadgeAwarded: RBXScriptSignal + BadgeAwarded: RBXScriptSignal function AwardBadge(self, userId: number, badgeId: number): boolean function IsDisabled(self, badgeId: number): boolean function IsLegal(self, badgeId: number): boolean - function SetAwardBadgeUrl(self, url: string): nil - function SetHasBadgeCooldown(self, seconds: number): nil - function SetHasBadgeUrl(self, url: string): nil - function SetIsBadgeDisabledUrl(self, url: string): nil - function SetIsBadgeLegalUrl(self, url: string): nil - function SetPlaceId(self, placeId: number): nil - function GetBadgeInfoAsync(self, badgeId: number): { [any]: any } - function UserHasBadgeAsync(self, userId: number, badgeId: number): boolean + function SetAwardBadgeUrl(self, url: string): () + function SetHasBadgeCooldown(self, seconds: number): () + function SetHasBadgeUrl(self, url: string): () + function SetIsBadgeDisabledUrl(self, url: string): () + function SetIsBadgeLegalUrl(self, url: string): () + function SetPlaceId(self, placeId: number): () + function UserHasBadge(self, userId: number, badgeId: number): boolean end declare class BasePlayerGui extends Instance end --- "Button" exists but isn't usable in any meaningful way - declare class CoreGui extends BasePlayerGui Version: number - RobloxGui: ScreenGui -- graaah end declare class PlayerGui extends BasePlayerGui @@ -1576,7 +1319,25 @@ declare class StarterGui extends BasePlayerGui ResetPlayerGuiOnSpawn: boolean ShowDevelopmentGui: boolean function GetCoreGuiEnabled(self, coreGuiType: EnumCoreGuiType): boolean - function SetCoreGuiEnabled(self, coreGuiType: EnumCoreGuiType, enabled: boolean): nil + function SetCoreGuiEnabled(self, coreGuiType: EnumCoreGuiType, enabled: boolean): () +end + +declare class BaseScript extends Instance + Disabled: boolean + LinkedSource: Content +end + +declare class CoreScript extends BaseScript +end + +declare class StarterScript extends CoreScript +end + +declare class Script extends BaseScript + Source: ProtectedString +end + +declare class LocalScript extends Script end declare class BindableEvent extends Instance @@ -1593,9 +1354,9 @@ declare class BodyMover extends Instance end declare class BodyAngularVelocity extends BodyMover + P: number angularvelocity: Vector3 maxTorque: Vector3 - P: number end declare class BodyForce extends BodyMover @@ -1603,19 +1364,20 @@ declare class BodyForce extends BodyMover end declare class BodyGyro extends BodyMover - cframe: CFrame D: number - maxTorque: Vector3 P: number + cframe: CFrame + maxTorque: Vector3 end declare class BodyPosition extends BodyMover D: number - maxForce: Vector3 P: number - position: Vector3 ReachedTarget: RBXScriptSignal<> - function GetLastForce(self): Vector3 -- lastForce also exists + function GetLastForce(self): Vector3 + function lastForce(self): Vector3 + maxForce: Vector3 + position: Vector3 end declare class BodyThrust extends BodyMover @@ -1624,10 +1386,48 @@ declare class BodyThrust extends BodyMover end declare class BodyVelocity extends BodyMover - maxForce: Vector3 P: number + function GetLastForce(self): Vector3 + function lastForce(self): Vector3 + maxForce: Vector3 velocity: Vector3 - function GetLastForce(self): Vector3 -- lastForce also exists +end + +declare class RocketPropulsion extends BodyMover + CartoonFactor: number + MaxSpeed: number + MaxThrust: number + MaxTorque: Vector3 + ReachedTarget: RBXScriptSignal<> + Target: Object + TargetOffset: Vector3 + TargetRadius: number + ThrustD: number + ThrustP: number + TurnD: number + TurnP: number + function Abort(self): () + function Fire(self): () +end + +declare class BoolValue extends Instance + Changed: RBXScriptSignal + Value: boolean +end + +declare class BrickColorValue extends Instance + Changed: RBXScriptSignal + Value: BrickColor +end + +declare class Button extends Instance + Click: RBXScriptSignal<> + function SetActive(self, active: boolean): () +end + +declare class CFrameValue extends Instance + Changed: RBXScriptSignal + Value: CFrame end declare class CacheableContentProvider extends Instance @@ -1636,44 +1436,41 @@ end declare class MeshContentProvider extends CacheableContentProvider end -declare class TextContentProvider extends CacheableContentProvider +declare class TextureContentProvider extends CacheableContentProvider end declare class Camera extends Instance - CoordinateFrame: CFrame -- no, .CFrame doesn't exist CameraSubject: Humanoid | BasePart | nil CameraType: EnumCameraType + CoordinateFrame: CFrame FieldOfView: number - FirstPersonTransition: RBXScriptSignal Focus: CFrame InterpolationFinished: RBXScriptSignal<> function GetPanSpeed(self): number function GetRoll(self): number function GetTiltSpeed(self): number - function Interpolate(self, endPos: CFrame, endFocus: CFrame, duration: number): nil - function PanUnits(self, units: number): nil - function SetCameraPanMode(self, mode: EnumCameraPanMode?): nil - function SetRoll(self, rollAngle: number): nil - function TiltUnits(self, units: number): nil + function Interpolate(self, endPos: CFrame, endFocus: CFrame, duration: number): () + function PanUnits(self, units: number): () + function SetCameraPanMode(self, mode: EnumCameraPanMode?): () + function SetRoll(self, rollAngle: number): () + function TiltUnits(self, units: number): boolean function Zoom(self, distance: number): boolean end - declare class ChangeHistoryService extends Instance function GetCanRedo(self): any function GetCanUndo(self): any - function Redo(self): nil - function ResetWaypoints(self): nil - function SetEnabled(self, state: boolean): nil - function SetWaypoint(self, name: string): nil - function Undo(self): nil + function Redo(self): () + function ResetWaypoints(self): () + function SetEnabled(self, state: boolean): () + function SetWaypoint(self, name: string): () + function Undo(self): () end declare class CharacterAppearance extends Instance end declare class BodyColors extends CharacterAppearance - -- rip no colour3s HeadColor: BrickColor LeftArmColor: BrickColor LeftLegColor: BrickColor @@ -1701,14 +1498,19 @@ declare class Shirt extends Clothing end declare class ShirtGraphic extends CharacterAppearance - Graphic: Content -- warning lel + Graphic: Content end - +declare class Skin extends CharacterAppearance + SkinColor: BrickColor +end declare class Chat extends Instance Chatted: RBXScriptSignal - function Chat(self, partOrCharacter: Instance, message: string, color: EnumChatColor?): nil + function Chat(self, partOrCharacter: Instance, message: string, color: EnumChatColor?): () +end + +declare class ChatFilter extends Instance end declare class ClickDetector extends Instance @@ -1724,41 +1526,46 @@ end declare class CollectionService extends Instance ItemAdded: RBXScriptSignal ItemRemoved: RBXScriptSignal - function GetCollection(self, tag: string): { Instance } + function GetCollection(self, class: string): { Instance } +end + +declare class Color3Value extends Instance + Changed: RBXScriptSignal + Value: Color3 end declare class Configuration extends Instance end declare class ContentFilter extends Instance - function SetFilterLimits(self, outstandingRequests: number, cacheSize: number): nil - function SetFilterUrl(self, url: string): nil + function SetFilterLimits(self, outstandingRequests: number, cacheSize: number): () + function SetFilterUrl(self, url: string): () end declare class ContentProvider extends Instance BaseUrl: string RequestQueueSize: number - function Preload(self, contentId: string): nil - function SetAssetUrl(self, url: string): nil - function SetBaseUrl(self, url: string): nil - function SetCacheSize(self, size: number): nil - function SetThreadPool(self, count: number): nil + function Preload(self, contentId: Content): () + function SetAssetUrl(self, url: string): () + function SetBaseUrl(self, url: string): () + function SetCacheSize(self, count: number): () + function SetThreadPool(self, count: number): () end declare class ContextActionService extends Instance ContextButtonEnabled: boolean LocalToolEquipped: RBXScriptSignal LocalToolUnequipped: RBXScriptSignal - function ActivateLocalTool(self): nil - function DeactivateLocalTool(self): nil + function ActivateLocalTool(self): () + function DeactivateLocalTool(self): () function GetCurrentLocalToolIcon(self): string end declare class Controller extends Instance ButtonChanged: RBXScriptSignal - function BindButton(self, button: EnumButton, caption: string): nil + function BindButton(self, button: EnumButton, caption: string): () function GetButton(self, button: EnumButton): boolean - function UnbindButton(self, button: EnumButton): nil + function UnbindButton(self, button: EnumButton): () end declare class HumanoidController extends Controller @@ -1777,10 +1584,21 @@ declare class ControllerService extends Instance end declare class CookiesService extends Instance - -- "An error occurred" when calling any of these methods - function DeleteCookieValue(self, key: string): nil - function GetCookieValue(self, key: string): string - function SetCookieValue(self, key: string, value: string): nil +end + +declare class CustomEvent extends Instance + ReceiverConnected: RBXScriptSignal + ReceiverDisconnected: RBXScriptSignal + function GetAttachedReceivers(self): { Instance } + function SetValue(self, newValue: number): () +end + +declare class CustomEventReceiver extends Instance + EventConnected: RBXScriptSignal + EventDisconnected: RBXScriptSignal + Source: Object + SourceValueChanged: RBXScriptSignal + function GetCurrentValue(self): number end declare class DataModelMesh extends Instance @@ -1789,10 +1607,13 @@ declare class DataModelMesh extends Instance VertexColor: Vector3 end -declare class BlockMesh extends DataModelMesh -- technically extends BevelMesh, but that's deprecated +declare class BevelMesh extends DataModelMesh end -declare class CylinderMesh extends DataModelMesh -- same +declare class BlockMesh extends BevelMesh +end + +declare class CylinderMesh extends BevelMesh end declare class FileMesh extends DataModelMesh @@ -1804,57 +1625,74 @@ declare class SpecialMesh extends FileMesh MeshType: EnumMeshType end -declare class DataStoreInfo extends Instance - CreatedTime: number - DataStoreName: string - UpdatedTime: number -end - -declare class DataStoreKey extends Instance - KeyName: string -end - -declare class DataStoreKeyInfo extends Instance - CreatedTime: number - UpdatedTime: number - Version: string - function GetMetadata(self): { [any]: any } - function GetUserIds(self): { number } -end - -declare class DataStoreObjectVersionInfo extends Instance - CreatedTime: number - IsDeleted: boolean - Version: string -end - -declare class DataStoreOptions extends Instance - AllScopes: boolean - function SetExperimentalFeatures(self, experimentalFeatures: { [any]: any }): nil -end - declare class DataStoreService extends Instance - function GetGlobalDataStore(self): GlobalDataStore + function GetGlobalDataStore(self): Instance end declare class Debris extends Instance - function AddItem(self, item: Instance, lifetime: number?): nil - function SetLegacyMaxItems(self, enabled: boolean): nil + function AddItem(self, item: Instance, lifetime: number?): () + function SetLegacyMaxItems(self, enabled: boolean): () end declare class DebugSettings extends Instance + AltCdnFailureCount: number + AltCdnSuccessCount: number + AvailablePhysicalMemory: number + BlockMeshSize: number + CPU: string + CdnFailureCount: number + CdnResponceTime: number + CdnSuccessCount: number + CpuCount: number + CpuSpeed: number DataModel: number + ElapsedTime: number + EnforceInstanceCountLimit: boolean + ErrorReporting: EnumErrorReporting + GfxCard: string InstanceCount: number + InstanceCountLimit: number + IsFmodProfilingEnabled: boolean + IsProfilingEnabled: boolean IsScriptStackTracingEnabled: boolean JobCount: number - PlayerCount: number - ReportSoundWarnings: boolean - RobloxVersion: string - TickCountPreciseOverride: EnumTickCountSampleMethod - + LastCdnFailureTimeSpan: number LuaRamLimit: number - - function LegacyScriptMode(self): nil + NameDatabaseBytes: number + NameDatabaseSize: number + OsIs64Bit: boolean + OsPlatform: string + OsPlatformId: number + OsVer: string + PageFaultsPerSecond: number + PageFileBytes: number + PixelShaderModel: number + PlayerCount: number + PrivateBytes: number + PrivateWorkingSetBytes: number + ProcessCores: number + ProcessorTime: number + ProfilingWindow: number + RAM: number + ReportExtendedMachineConfiguration: boolean + ReportSoundWarnings: boolean + Resolution: string + RobloxFailureCount: number + RobloxProductName: string + RobloxRespoceTime: number + RobloxSuccessCount: number + RobloxVersion: string + SIMD: string + SystemProductName: string + TickCountPreciseOverride: EnumTickCountSampleMethod + TotalPhysicalMemory: number + TotalProcessorTime: number + VertexShaderModel: number + VideoMemory: number + VirtualBytes: number + function LegacyScriptMode(self): () + function ResetCdnFailureCounts(self): any + function SetBlockingRemove(self, value: boolean): () end declare class DebuggerBreakpoint extends Instance @@ -1868,53 +1706,54 @@ declare class DebuggerManager extends Instance DebuggerRemoved: RBXScriptSignal DebuggingEnabled: boolean function AddDebugger(self, script: Instance): Instance - function EnableDebugging(self): nil + function EnableDebugging(self): () function GetDebuggers(self): { Instance } end declare class DebuggerWatch extends Instance Expression: string + function CheckSyntax(self): () end declare class Dialog extends Instance ConversationDistance: number DialogChoiceSelected: RBXScriptSignal - GoodbyeChoiceActive: boolean - GoodbyeDialog: string InUse: boolean InitialPrompt: string Purpose: EnumDialogPurpose Tone: EnumDialogTone - TriggerDistance: number - TriggerOffset: Vector3 - function GetCurrentPlayers(self): { Player } - function SetPlayerIsUsing(self, player: Instance, isUsing: boolean): nil - function SignalDialogChoiceSelected(self, player: Instance, dialogChoice: Instance): nil + function SignalDialogChoiceSelected(self, player: Instance, dialogChoice: Instance): () end declare class DialogChoice extends Instance - GoodbyeChoiceActive: boolean - GoodbyeDialog: string ResponseDialog: string UserDialog: string end +declare class DoubleConstrainedValue extends Instance + Changed: RBXScriptSignal + ConstrainedValue: number + MaxValue: number + MinValue: number + Value: number +end + declare class Dragger extends Instance - function AxisRotate(self, axis: EnumAxis?): nil - function MouseDown(self, mousePart: Instance, pointOnMousePart: Vector3, parts: { Instance }): nil - function MouseMove(self, mouseRay: Ray): nil - function MouseUp(self): nil + function AxisRotate(self, axis: EnumAxis?): () + function MouseDown(self, mousePart: Instance, pointOnMousePart: Vector3, parts: { Instance }): () + function MouseMove(self, mouseRay: Ray): () + function MouseUp(self): () end declare class Explosion extends Instance BlastPressure: number BlastRadius: number - DestroyJointRadiusPercent: number ExplosionType: EnumExplosionType Hit: RBXScriptSignal Position: Vector3 - TimeScale: number - Visible: boolean +end + +declare class FWService extends Instance end declare class FaceInstance extends Instance @@ -1922,20 +1761,23 @@ declare class FaceInstance extends Instance end declare class Decal extends FaceInstance - Color3: Color3 - LocalTransparencyModifier: number + Shiny: number + Specular: number Texture: Content Transparency: number - ZIndex: number end declare class Texture extends Decal - OffsetStudsU: number - OffsetStudsV: number StudsPerTileU: number StudsPerTileV: number end +declare class FastLogSettings extends Instance + function DumpLogs(self, filename: string): () + function Print(self, message: string): () + function SetVariable(self, group: string, channel: string?): () +end + declare class Feature extends Instance FaceId: EnumNormalId InOut: EnumInOut @@ -1943,81 +1785,77 @@ declare class Feature extends Instance TopBottom: EnumTopBottom end +declare class Hole extends Feature +end + +declare class MotorFeature extends Feature +end + declare class Fire extends Instance Color: Color3 Enabled: boolean Heat: number SecondaryColor: Color3 Size: number - TimeScale: number - function FastForward(self, numFrames: number): nil end declare class FlagStandService extends Instance end --- (sing to the tune of "you give love a bad name") --- THIS INTEGRATION IS GOING TO HELL --- YOU PROMISED ME JSON AND SENT XML --- YOU SAY IT WORKS IN A RESTFUL WAY --- THEN YOUR ERRORS COME BACK AS *200 OK* - declare class ForceField extends Instance - Visible: boolean end --- WHOAAOA IT'S NO SURPRISE --- METHOD NAMES IN URIS --- YOUR DATA WON'T EVEN DESERIALIZE - --- YOUR API IS A HALL OF SHAME --- YOU GIVE REST A BAD NAME --- IT FALLS APART AND WE TAKE THE BLAME --- YOU GIVE REST A BAD NAME --- YOU GIVE REST --- A BAD NAME - declare class FriendService extends Instance - function SetBreakFriendUrl(self, url: string): nil - function SetCreateFriendRequestUrl(self, url: string): nil - function SetDeleteFriendRequestUrl(self, url: string): nil - function SetEnabled(self, enable: boolean): nil - function SetFriendsOnlineUrl(self, url: string): nil - function SetGetFriendsUrl(self, url: string): nil - function SetMakeFriendUrl(self, url: string): nil + function SetBreakFriendUrl(self, url: string): () + function SetCreateFriendRequestUrl(self, url: string): () + function SetDeleteFriendRequestUrl(self, url: string): () + function SetEnabled(self, enable: boolean): () + function SetFriendsOnlineUrl(self, url: string): () + function SetGetFriendsUrl(self, url: string): () + function SetMakeFriendUrl(self, url: string): () end --- BROKEN METHODS, MISSING DOCS --- UPDATES FAIL CUZ OF DATABASE LOCKS --- BREAKING CHANGES, EVERY TIME --- YOUR EVERY RELEASE TAKES OUR SYSTEM OFFLINE --- [chorus] +declare class FunctionalTest extends Instance + Description: string + function Error(self, message: string?): () + function Failed(self, message: string?): () + function Pass(self, message: string?): () + function Passed(self, message: string?): () + function Warn(self, message: string?): () +end declare class GamePassService extends Instance - function PlayerHasPass(self, player: Player, gamePassId: number): boolean - function SetPlayerHasPassUrl(self, playerHasPassUrl: string): nil + function PlayerHasPass(self, player: Instance, gamePassId: number): boolean + function SetPlayerHasPassUrl(self, playerHasPassUrl: string): () end declare class GameSettings extends Instance + BubbleChatLifetime: number + BubbleChatMaxBubbles: number + ChatHistory: number + ChatScrollLength: number + CollisionSoundEnabled: boolean + CollisionSoundVolume: number + HardwareMouse: boolean + ImageUploadPromptBehavior: EnumUploadSetting + MaxCollisionSounds: number + ReportAbuseChatHistory: number + SoftwareSound: boolean + SoundEnabled: boolean VideoCaptureEnabled: boolean - VideoRecording: boolean + VideoQuality: EnumVideoQualitySettings VideoRecordingChangeRequest: RBXScriptSignal end -declare class GamepadService extends Instance - GamepadCursorEnabled: boolean - GamepadThumbstick1Changed: RBXScriptSignal - function DisableGamepadCursor(self): nil - function EnableGamepadCursor(self, guiObject: Instance): nil - function GetGamepadCursorPosition(self): Vector2 - function SetGamepadCursorPosition(self, position: Vector2): nil +declare class Geometry extends Instance end declare class GlobalDataStore extends Instance - function GetAsync(self, key: string): (any, DataStoreKeyInfo) - function IncrementAsync(self, key: string, delta: number?): (number, DataStoreKeyInfo) - function SetAsync(self, key: string, value: any): string - function UpdateAsync(self, key: string, transformFunction: ((any, DataStoreKeyInfo) -> (any, { number }?, {}?))): (any, DataStoreKeyInfo) + function GetAsync(self, key: string): (any, { [string]: any }) + function IncrementAsync(self, key: string, delta: number?, userIds: { number }?, options: { [string]: any }?): (number, { [string]: any }) + function OnUpdate(self, key: string, callback: ((...any) -> ...any)): RBXScriptConnection + function SetAsync(self, key: string, value: any, userIds: { number }?, options: { [string]: any }?): string + function UpdateAsync(self, key: string, transformFunction: ((any, { [string]: any }) -> (any, { number }?, {}?))): (any, { [string]: any }) end declare class GuiBase extends Instance @@ -2030,30 +1868,24 @@ end declare class GuiObject extends GuiBase2d Active: boolean - AnchorPoint: Vector2 BackgroundColor3: Color3 BackgroundTransparency: number BorderColor3: Color3 BorderSizePixel: number ClipsDescendants: boolean - InputBegan: RBXScriptSignal - InputChanged: RBXScriptSignal - InputEnded: RBXScriptSignal - Interactable: boolean - LayoutOrder: number + DragBegin: RBXScriptSignal + DragStopped: RBXScriptSignal + Draggable: boolean + InputBegan: RBXScriptSignal + InputChanged: RBXScriptSignal + InputEnded: RBXScriptSignal MouseEnter: RBXScriptSignal MouseLeave: RBXScriptSignal MouseMoved: RBXScriptSignal MouseWheelBackward: RBXScriptSignal MouseWheelForward: RBXScriptSignal - NextSelectionDown: GuiObject - NextSelectionLeft: GuiObject - NextSelectionRight: GuiObject - NextSelectionUp: GuiObject Position: UDim2 Rotation: number - Selectable: boolean - SelectionOrder: number Size: UDim2 SizeConstraint: EnumSizeConstraint TouchLongPress: RBXScriptSignal<{ Vector2 }, EnumUserInputState> @@ -2074,8 +1906,10 @@ declare class Frame extends GuiObject Style: EnumFrameStyle end +declare class NotificationObject extends Frame +end + declare class GuiButton extends GuiObject - Activated: RBXScriptSignal AutoButtonColor: boolean Modal: boolean MouseButton1Click: RBXScriptSignal<> @@ -2086,6 +1920,7 @@ declare class GuiButton extends GuiObject MouseButton2Up: RBXScriptSignal Selected: boolean Style: EnumButtonStyle + function SetVerb(self, verb: string): () end declare class ImageButton extends GuiButton @@ -2095,25 +1930,19 @@ declare class ImageButton extends GuiButton end declare class TextButton extends GuiButton - ContentText: string Font: EnumFont - LineHeight: number - LocalizedText: string - MaxVisibleGraphemes: number - RichText: boolean + FontSize: EnumFontSize Text: string TextBounds: Vector2 TextColor3: Color3 TextFits: boolean TextScaled: boolean - TextSize: number TextStrokeColor3: Color3 TextStrokeTransparency: number TextTransparency: number TextWrapped: boolean TextXAlignment: EnumTextXAlignment TextYAlignment: EnumTextYAlignment - function SetTextFromInput(self, text: string): nil end declare class GuiLabel extends GuiObject @@ -2126,58 +1955,47 @@ declare class ImageLabel extends GuiLabel end declare class TextLabel extends GuiLabel - ContentText: string Font: EnumFont - LineHeight: number + FontSize: EnumFontSize Text: string TextBounds: Vector2 TextColor3: Color3 TextFits: boolean TextScaled: boolean - TextSize: number TextStrokeColor3: Color3 TextStrokeTransparency: number TextTransparency: number TextWrapped: boolean TextXAlignment: EnumTextXAlignment TextYAlignment: EnumTextYAlignment +end - FontSize: EnumFontSize +declare class NotificationBox extends GuiObject +end + +declare class Scale9Frame extends GuiObject + ScaleEdgeSize: Vector2int16 + SlicePrefix: string end declare class TextBox extends GuiObject ClearTextOnFocus: boolean - FocusLost: RBXScriptSignal + FocusLost: RBXScriptSignal Font: EnumFont - LineHeight: number - ManualFocusRelease: boolean - MaxVisibleGraphemes: number + FontSize: EnumFontSize MultiLine: boolean - OverlayNativeInput: boolean - PlaceholderColor3: Color3 - PlaceholderText: string - ReturnPressedFromOnScreenKeyboard: RBXScriptSignal<> - RichText: boolean - SelectionStart: number - ShowNativeInput: boolean Text: string TextBounds: Vector2 TextColor3: Color3 - TextEditable: boolean TextFits: boolean TextScaled: boolean - TextSize: number TextStrokeColor3: Color3 TextStrokeTransparency: number TextTransparency: number TextWrapped: boolean TextXAlignment: EnumTextXAlignment TextYAlignment: EnumTextYAlignment - function CaptureFocus(self): nil - function IsFocused(self): boolean - function ReleaseFocus(self, submitted: boolean?): nil - function ResetKeyboardMode(self): nil - function SetTextFromInput(self, text: string): nil + function CaptureFocus(self): () end declare class LayerCollector extends GuiBase2d @@ -2185,85 +2003,52 @@ end declare class BillboardGui extends LayerCollector Active: boolean - Adornee: Instance + Adornee: Object AlwaysOnTop: boolean - Brightness: number - ClipsDescendants: boolean - CurrentDistance: number - DistanceLowerLimit: number - DistanceStep: number - DistanceUpperLimit: number + Enabled: boolean ExtentsOffset: Vector3 - ExtentsOffsetWorldSpace: Vector3 - LightInfluence: number - MaxDistance: number - PlayerToHideFrom: Instance + PlayerToHideFrom: Object Size: UDim2 SizeOffset: Vector2 StudsOffset: Vector3 - StudsOffsetWorldSpace: Vector3 - function GetScreenSpaceBounds(self): any -end - -declare class PluginGui extends LayerCollector - PluginDragDropped: RBXScriptSignal<{ [any]: any }> - PluginDragEntered: RBXScriptSignal<{ [any]: any }> - PluginDragLeft: RBXScriptSignal<{ [any]: any }> - PluginDragMoved: RBXScriptSignal<{ [any]: any }> - Title: string - WindowFocusReleased: RBXScriptSignal<> - WindowFocused: RBXScriptSignal<> - function BindToClose(self, func: ((...any) -> ...any)?): nil - function GetRelativeMousePosition(self): Vector2 -end - -declare class QWidgetPluginGui extends PluginGui end declare class ScreenGui extends LayerCollector end +declare class GuiMain extends ScreenGui +end - -declare class SurfaceGuiBase extends LayerCollector +declare class SurfaceGui extends LayerCollector Active: boolean - Adornee: Instance + Adornee: Object + CanvasSize: Vector2 + Enabled: boolean Face: EnumNormalId end -declare class SurfaceGui extends SurfaceGuiBase - AlwaysOnTop: boolean - Brightness: number - CanvasSize: Vector2 - ClipsDescendants: boolean - HorizontalCurvature: number - LightInfluence: number - PixelsPerStud: number - ToolPunchThroughDistance: number - ZOffset: number -end - declare class GuiBase3d extends GuiBase - Color3: Color3 + Color: BrickColor Transparency: number Visible: boolean end - - -declare class InstanceAdornment extends GuiBase3d - Adornee: Instance? -end - -declare class SelectionBox extends InstanceAdornment - LineThickness: number - StudioSelectionBox: boolean - SurfaceColor3: Color3 - SurfaceTransparency: number +declare class FloorWire extends GuiBase3d + CycleOffset: number + From: Object + StudsBetweenTextures: number + Texture: Content + TextureSize: Vector2 + To: Object + Velocity: number + WireRadius: number end declare class PVAdornment extends GuiBase3d - Adornee: PVInstance + Adornee: Object +end + +declare class SelectionBox extends PVAdornment end declare class PartAdornment extends GuiBase3d @@ -2297,86 +2082,97 @@ declare class SurfaceSelection extends PartAdornment end declare class SelectionLasso extends GuiBase3d - Humanoid: Humanoid + Humanoid: Object +end + +declare class SelectionPartLasso extends SelectionLasso + Part: Object +end + +declare class SelectionPointLasso extends SelectionLasso + Point: Vector3 +end + +declare class TextureTrail extends GuiBase3d +end + +declare class GuiItem extends Instance +end + +declare class Backpack extends GuiItem +end + +declare class BackpackItem extends GuiItem + TextureId: Content +end + +declare class HopperBin extends BackpackItem + Active: boolean + BinType: EnumBinType + Deselected: RBXScriptSignal<> + Selected: RBXScriptSignal + function Disable(self): () + function ToggleSelect(self): () +end + +declare class Tool extends BackpackItem + Activated: RBXScriptSignal<> + CanBeDropped: boolean + Deactivated: RBXScriptSignal<> + Enabled: boolean + Equipped: RBXScriptSignal + Grip: CFrame + GripForward: Vector3 + GripPos: Vector3 + GripRight: Vector3 + GripUp: Vector3 + ToolTip: string + Unequipped: RBXScriptSignal<> +end + +declare class Flag extends Tool + TeamColor: BrickColor +end + +declare class ButtonBindingWidget extends GuiItem +end + +declare class GuiRoot extends GuiItem +end + +declare class Hopper extends GuiItem +end + +declare class LocalBackpack extends GuiItem + function GetOldSchoolBackpack(self): boolean + function SetOldSchoolBackpack(self, show: boolean): () +end + +declare class PlayerHUD extends GuiItem +end + +declare class StarterPack extends GuiItem end declare class GuiService extends Instance - AutoSelectGuiEnabled: boolean - CloseInspectMenuRequest: RBXScriptSignal<> - CoreGuiNavigationEnabled: boolean - CoreGuiRenderOverflowed: RBXScriptSignal<> - EmotesMenuOpenChanged: RBXScriptSignal - GuiNavigationEnabled: boolean - InspectMenuEnabledChangedSignal: RBXScriptSignal - InspectPlayerFromUserIdWithCtxRequest: RBXScriptSignal - KeyPressed: RBXScriptSignal - MenuClosed: RBXScriptSignal<> - MenuIsOpen: boolean - MenuOpened: RBXScriptSignal<> - NativeClose: RBXScriptSignal<> - NetworkPausedEnabledChanged: RBXScriptSignal - Open9SliceEditor: RBXScriptSignal - PreferredTransparency: number - PurchasePromptShown: RBXScriptSignal<> - ReducedMotionEnabled: boolean - SafeZoneOffsetsChanged: RBXScriptSignal<> - SelectedCoreObject: GuiObject - SelectedObject: GuiObject? - SendCoreUiNotification: (title: string, text: string) -> nil - SendNotification: (self: GuiService, title: string, text: string, text2: string, number: number, callback: (any) -> any) -> nil - ShowLeaveConfirmation: RBXScriptSignal<> - SpecialKeyPressed: RBXScriptSignal - TouchControlsEnabled: boolean - - EscapeKeyPressed: RBXScriptSignal<> BrowserWindowClosed: RBXScriptSignal<> - IsWindows: boolean + EscapeKeyPressed: RBXScriptSignal<> IsModalDialog: boolean + IsWindows: boolean + KeyPressed: RBXScriptSignal + ShowLegacyPlayerList: boolean + SpecialKeyPressed: RBXScriptSignal UseLuaChat: boolean - - function AddCenterDialog(self, dialog: Instance, centerDialogType: EnumCenterDialogType, showFunction: ((...any) -> ...any), hideFunction: ((...any) -> ...any)): nil - function AddKey(self, key: string): nil - function AddSelectionParent(self, selectionName: string, selectionParent: Instance): nil - function AddSelectionTuple(self, selectionName: string, selections: any): nil - function AddSpecialKey(self, key: EnumSpecialKey): nil - function BroadcastNotification(self, data: string, notificationType: number): nil - function ClearError(self): nil - function CloseInspectMenu(self): nil - function CloseStatsBasedOnInputString(self, input: string): boolean - function ForceTenFootInterface(self, isForced: boolean): nil - function GetBrickCount(self): number - function GetClosestDialogToPosition(self, position: Vector3): Instance - function GetEmotesMenuOpen(self): boolean - function GetGameplayPausedNotificationEnabled(self): boolean - function GetGuiInset(self): (Vector2, Vector2) - function GetInspectMenuEnabled(self): boolean - function GetNotificationTypeList(self): { [any]: any } - function GetResolutionScale(self): number - function GetSafeZoneOffsets(self): { [any]: any } + Version: number + function AddCenterDialog(self, dialog: Instance, centerDialogType: EnumCenterDialogType, showFunction: ((...any) -> ...any), hideFunction: ((...any) -> ...any)): () + function AddKey(self, key: string): () + function AddSpecialKey(self, key: EnumSpecialKey): () function GetScreenResolution(self): Vector2 - function GetUiMessage(self): string - function InspectPlayerFromUserId(self, userId: number): nil - function InspectPlayerFromUserIdWithCtx(self, userId: number, ctx: string): nil - function IsMemoryTrackerEnabled(self): boolean - function IsTenFootInterface(self): boolean - function RemoveCenterDialog(self, dialog: Instance): nil - function RemoveKey(self, key: string): nil - function RemoveSelectionGroup(self, selectionName: string): nil - function RemoveSpecialKey(self, key: EnumSpecialKey): nil - function Select(self, selectionParent: Instance): nil - function SetEmotesMenuOpen(self, isOpen: boolean): nil - function SetGameplayPausedNotificationEnabled(self, enabled: boolean): nil - function SetGlobalGuiInset(self, x1: number, y1: number, x2: number, y2: number): nil - function SetHardwareSafeAreaInsets(self, left: number, top: number, right: number, bottom: number): nil - function SetInspectMenuEnabled(self, enabled: boolean): nil - function SetMenuIsOpen(self, open: boolean, menuName: string?): nil - function SetPurchasePromptIsShown(self, isShown: boolean): nil - function SetSafeZoneOffsets(self, top: number, bottom: number, left: number, right: number): nil - function ShowStatsBasedOnInputString(self, input: string): boolean - function ToggleFullscreen(self): nil - - function OpenBrowserWindow(self, url: string): nil - function SetGlobalSizeOffsetPixel(self, x: number, y: number): nil + function OpenBrowserWindow(self, url: string): () + function RemoveCenterDialog(self, dialog: Instance): () + function RemoveKey(self, key: string): () + function SendNotification(self, title: string, text: string, image: string, duration: number, callback: ((...any) -> ...any)): () + function SetGlobalGuiInset(self, x1: number, y1: number, x2: number, y2: number): () end declare class GuidRegistryService extends Instance @@ -2384,15 +2180,17 @@ end declare class HttpService extends Instance HttpEnabled: boolean - function GetAsync(self, url: string, nocache: boolean?, headers: any): string + function GetAsync(self, url: string, nocache: boolean?): string function JSONDecode(self, input: string): any function JSONEncode(self, input: any): string - function PostAsync(self, url: string, data: string, content_type: EnumHttpContentType?, compress: boolean?, headers: any): string + function PostAsync(self, url: string, data: string, content_type: EnumHttpContentType?): string function UrlEncode(self, input: string): string end declare class Humanoid extends Instance Climbing: RBXScriptSignal + CustomStatusAdded: RBXScriptSignal + CustomStatusRemoved: RBXScriptSignal Died: RBXScriptSignal<> FallingDown: RBXScriptSignal FreeFalling: RBXScriptSignal @@ -2401,60 +2199,76 @@ declare class Humanoid extends Instance HealthChanged: RBXScriptSignal Jump: boolean Jumping: RBXScriptSignal + LeftLeg: Object MaxHealth: number NameOcclusion: EnumNameOcclusion PlatformStand: boolean PlatformStanding: RBXScriptSignal Ragdoll: RBXScriptSignal + RightLeg: Object Running: RBXScriptSignal - Seated: RBXScriptSignal + Seated: RBXScriptSignal Sit: boolean + StatusAdded: RBXScriptSignal + StatusRemoved: RBXScriptSignal Strafing: RBXScriptSignal Swimming: RBXScriptSignal TargetPoint: Vector3 + Torso: Object WalkSpeed: number WalkToPart: BasePart? WalkToPoint: Vector3 - function EquipTool(self, tool: Tool): nil - function GetMoveVelocity(self): Vector3 - function MoveTo(self, location: Vector3, part: BasePart?): nil - function RemoveAccessories(self): nil - function SetClickToWalkEnabled(self, enabled: boolean): nil - function TakeDamage(self, amount: number): nil - function UnequipTools(self): nil -end - -declare class InputObject extends Instance - Delta: Vector3 - Position: Vector3 - UserInputState: EnumUserInputState - UserInputType: EnumUserInputType + function AddCustomStatus(self, status: string): boolean + function AddStatus(self, status: EnumStatus?): boolean + function EquipTool(self, tool: Tool): () + function GetStatuses(self): { any } + function HasCustomStatus(self, status: string): boolean + function HasStatus(self, status: EnumStatus?): boolean + function LoadAnimation(self, animation: Animation): Instance + function MoveTo(self, location: Vector3, part: BasePart): () + function RemoveCustomStatus(self, status: string): boolean + function RemoveStatus(self, status: EnumStatus?): boolean + function SetClickToWalkEnabled(self, enabled: boolean): () + function TakeDamage(self, amount: number): () + function UnequipTools(self): () end declare class InsertService extends Instance - AllowClientInsertModels: boolean function GetBaseSets(self): { any } function GetCollection(self, categoryId: number): { any } function GetFreeDecals(self, searchText: string, pageNum: number): { any } function GetFreeModels(self, searchText: string, pageNum: number): { any } - function GetLatestAssetVersionAsync(self, assetId: number): number - function GetLocalFileContents(self, contentId: string): string function GetUserSets(self, userId: number): { any } + function Insert(self, instance: Instance): () function LoadAsset(self, assetId: number): Instance function LoadAssetVersion(self, assetVersionId: number): Instance - function LoadAssetWithFormat(self, assetId: number, format: string): { Instance } - function LoadLocalAsset(self, assetPath: string): Instance - function LoadPackageAsset(self, url: Content): { Instance } - function LoadPackageAssetAsync(self, url: Content): { Instance } + function SetAdvancedResults(self, enable: boolean, user: boolean?): () + function SetAssetUrl(self, assetUrl: string): () + function SetAssetVersionUrl(self, assetVersionUrl: string): () + function SetBaseCategoryUrl(self, baseSetsUrl: string): () + function SetBaseSetsUrl(self, baseSetsUrl: string): () + function SetCollectionUrl(self, collectionUrl: string): () + function SetFreeDecalUrl(self, freeDecalUrl: string): () + function SetFreeModelUrl(self, freeModelUrl: string): () + function SetTrustLevel(self, trustLevel: number): () + function SetUserCategoryUrl(self, userSetsUrl: string): () + function SetUserSetsUrl(self, userSetsUrl: string): () +end - function SetAssetUrl(self, assetUrl: string): nil - function SetAssetVersionUrl(self, assetVersionUrl: string): nil - function SetBaseSetsUrl(self, baseSetsUrl: string): nil - function SetCollectionUrl(self, collectionUrl: string): nil - function SetUserSetsUrl(self, userSetsUrl: string): nil - function SetTrustLevel(self, trustLevel: number): nil - function SetFreeModelUrl(self, freeModelUrl: string): nil - function SetFreeDecalUrl(self, freeDecalUrl: string): nil +declare class InstancePacketCache extends Instance +end + +declare class IntConstrainedValue extends Instance + Changed: RBXScriptSignal + ConstrainedValue: number + MaxValue: number + MinValue: number + Value: number +end + +declare class IntValue extends Instance + Changed: RBXScriptSignal + Value: number end declare class JointInstance extends Instance @@ -2468,50 +2282,81 @@ declare class DynamicRotate extends JointInstance BaseAngle: number end +declare class RotateP extends DynamicRotate +end + +declare class RotateV extends DynamicRotate +end + +declare class Glue extends JointInstance + F0: Vector3 + F1: Vector3 + F2: Vector3 + F3: Vector3 +end + +declare class ManualSurfaceJointInstance extends JointInstance +end + +declare class ManualGlue extends ManualSurfaceJointInstance +end + +declare class ManualWeld extends ManualSurfaceJointInstance +end + declare class Motor extends JointInstance CurrentAngle: number DesiredAngle: number MaxVelocity: number - function SetDesiredAngle(self, value: number): nil + function SetDesiredAngle(self, value: number): () end declare class Motor6D extends Motor - ChildName: string - ParentName: string - Transform: CFrame +end + +declare class Rotate extends JointInstance +end + +declare class Snap extends JointInstance end declare class VelocityMotor extends JointInstance CurrentAngle: number DesiredAngle: number - Hole: Hole + Hole: Object MaxVelocity: number end declare class Weld extends JointInstance end +declare class JointsService extends Instance + function ClearJoinAfterMoveJoints(self): () + function CreateJoinAfterMoveJoints(self): () + function SetJoinAfterMoveInstance(self, joinInstance: Instance): () + function SetJoinAfterMoveTarget(self, joinTarget: Instance): () + function ShowPermissibleJoints(self): () +end + declare class Keyframe extends Instance Time: number - function AddPose(self, pose: Pose): nil + function AddPose(self, pose: Pose): () function GetPoses(self): { Instance } - function RemovePose(self, pose: Pose): nil + function RemovePose(self, pose: Pose): () end declare class KeyframeSequence extends Instance Loop: boolean Priority: EnumAnimationPriority - - function AddKeyframe(self, keyframe: Keyframe): nil - function GetKeyframes(self): { Keyframe } -- todo test probably keyframe argh, nevermind I am absolutely taking chances now - function RemoveKeyframe(self, keyframe: Keyframe): nil + function AddKeyframe(self, keyframe: Keyframe): () + function GetKeyframes(self): { Instance } + function RemoveKeyframe(self, keyframe: Keyframe): () end declare class KeyframeSequenceProvider extends Instance - function GetAnimations(self, userId: number, page: number?): Instance + function GetAnimations(self, userId: number, page: number?): { [any]: any } function GetKeyframeSequence(self, assetId: Content): Instance function GetKeyframeSequenceById(self, assetId: number, useCache: boolean): Instance - function GetMemStats(self): { [any]: any } function RegisterActiveKeyframeSequence(self, keyframeSequence: Instance): Content function RegisterKeyframeSequence(self, keyframeSequence: Instance): Content end @@ -2533,21 +2378,11 @@ declare class SpotLight extends Light Range: number end -declare class SurfaceLight extends Light - Angle: number - Face: EnumNormalId - Range: number -end - declare class Lighting extends Instance Ambient: Color3 Brightness: number - ClockTime: number ColorShift_Bottom: Color3 ColorShift_Top: Color3 - EnvironmentDiffuseScale: number - EnvironmentSpecularScale: number - ExposureCompensation: number FogColor: Color3 FogEnd: number FogStart: number @@ -2555,21 +2390,20 @@ declare class Lighting extends Instance GlobalShadows: boolean LightingChanged: RBXScriptSignal OutdoorAmbient: Color3 - ShadowSoftness: number - TempUseNewSkyRemovalBehaviour: boolean + Outlines: boolean + ShadowColor: Color3 TimeOfDay: string function GetMinutesAfterMidnight(self): number function GetMoonDirection(self): Vector3 function GetMoonPhase(self): number function GetSunDirection(self): Vector3 - function SetMinutesAfterMidnight(self, minutes: number): nil + function SetMinutesAfterMidnight(self, minutes: number): () +end + +declare class LocalWorkspace extends Instance end declare class LoginService extends Instance - LoginFailed: RBXScriptSignal - LoginSucceeded: RBXScriptSignal - function Logout(self): nil - function PromptLogin(self): nil end declare class LuaSettings extends Instance @@ -2582,48 +2416,36 @@ declare class LuaSettings extends Instance WaitingThreadsBudget: number end -declare class BaseScript extends Instance - Disabled: boolean - LinkedSource: Content -end - -declare class CoreScript extends BaseScript -end - -declare class Script extends BaseScript - Source: ProtectedString - function GetHash(self): string -end - -declare class LocalScript extends Script -end - -declare class ModuleScript extends Instance - LinkedSource: Content - Source: ProtectedString -end - declare class LuaWebService extends Instance end declare class MarketplaceService extends Instance ClientPurchaseSuccess: RBXScriptSignal + PromptProductPurchaseFinished: RBXScriptSignal + PromptProductPurchaseRequested: RBXScriptSignal PromptPurchaseFinished: RBXScriptSignal PromptPurchaseRequested: RBXScriptSignal - PromptRobloxPurchaseRequested: RBXScriptSignal - PromptSubscriptionPurchaseRequested: RBXScriptSignal ServerPurchaseVerification: RBXScriptSignal<{ [any]: any }> - function GetProductInfo(self, assetId: number, infoType: EnumInfoType?): { [any]: any } function PlayerOwnsAsset(self, player: Player, assetId: number): boolean - function PromptProductPurchase(self, player: Player, productId: number, equipIfPurchased: boolean?, currencyType: EnumCurrencyType?): nil - function PromptPurchase(self, player: Player, assetId: number, equipIfPurchased: boolean?, currencyType: EnumCurrencyType?): nil - function SetDevProductInfoUrl(self, url: string): nil - function SetPlayerOwnsAssetUrl(self, url: string): nil - function SetProductInfoUrl(self, url: string): nil - function SignalClientPurchaseSuccess(self, ticket: string, playerId: number, productId: number): nil - function SignalPromptProductPurchaseFinished(self, player: Instance, productId: number, success: boolean): nil - function SignalPromptPurchaseFinished(self, player: Instance, assetId: number, success: boolean): nil + function PromptProductPurchase(self, player: Player, productId: number, equipIfPurchased: boolean?, currencyType: EnumCurrencyType?): () + function PromptPurchase(self, player: Player, assetId: number, equipIfPurchased: boolean?, currencyType: EnumCurrencyType?): () + function SetDevProductInfoUrl(self, url: string): () + function SetPlayerOwnsAssetUrl(self, url: string): () + function SetProductInfoUrl(self, url: string): () + function SignalClientPurchaseSuccess(self, ticket: string, playerId: number, productId: number): () + function SignalPromptProductPurchaseFinished(self, userId: number, productId: number, success: boolean): () + function SignalPromptPurchaseFinished(self, player: Instance, assetId: number, success: boolean): () +end + +declare class Message extends Instance + Text: string +end + +declare class Hint extends Message +end + +declare class ModuleScript extends Instance end declare class Mouse extends Instance @@ -2638,8 +2460,8 @@ declare class Mouse extends Instance KeyUp: RBXScriptSignal Move: RBXScriptSignal<> Origin: CFrame - Target: BasePart - TargetFilter: Instance + Target: Object + TargetFilter: Object TargetSurface: EnumNormalId UnitRay: Ray ViewSizeX: number @@ -2661,52 +2483,44 @@ declare class NetworkMarker extends Instance end declare class NetworkPeer extends Instance - function SetOutgoingKBPSLimit(self, limit: number): nil + function SetOutgoingKBPSLimit(self, limit: number): () end declare class NetworkClient extends NetworkPeer ConnectionAccepted: RBXScriptSignal - ConnectionRejected: RBXScriptSignal ConnectionFailed: RBXScriptSignal + ConnectionRejected: RBXScriptSignal Ticket: string - -- function Connect(self, serverAddress: string, serverPort: number, id: number, threadSleepTime: number): nil -- I don't think this method actually exists - function Disconnect(self, blockDuration: number?): nil - function PlayerConnect(self, userId: number, server: string, serverPort: number, clientPort: number?, threadSleepTime: number?, userName: string?): Player + function Disconnect(self, blockDuration: number?): () + function PlayerConnect(self, userId: number, server: string, serverPort: number, clientPort: number?, threadSleepTime: number?): Instance end declare class NetworkServer extends NetworkPeer DataBasicFiltered: RBXScriptSignal DataCustomFiltered: RBXScriptSignal - IncommingConnection: RBXScriptSignal -- LOL + IncommingConnection: RBXScriptSignal Port: number function GetClientCount(self): number - function SetIsPlayerAuthenticationRequired(self, value: boolean): nil - function Start(self, port: number?, threadSleepTime: number?): nil - function Stop(self, blockDuration: number?): nil + function Start(self, port: number?, threadSleepTime: number?): () + function Stop(self, blockDuration: number?): () end declare class NetworkReplicator extends Instance - Disconnection: RBXScriptSignal + Disconnection: RBXScriptSignal MachineAddress: string Port: number - function CloseConnection(self): nil - function DisableProcessPackets(self): nil - function EnableProcessPackets(self): nil - function GetPlayer(self): Instance -- probably Player but I can't check this + function CloseConnection(self): () + function DisableProcessPackets(self): () + function EnableProcessPackets(self): () + function GetPlayer(self): Instance function GetRakStatsString(self, verbosityLevel: number?): string - function RequestCharacter(self): nil + function RequestCharacter(self): () function SendMarker(self): Instance - function SetPropSyncExpiration(self, secondso: number): nil + function SetPropSyncExpiration(self, seconds: number): () end declare class ServerReplicator extends NetworkReplicator TicketProcessed: RBXScriptSignal - DeleteFilter: (deletingItem: Instance) -> EnumFilterResult - EventFilter: (firingItem: Instance, event: string) -> EnumFilterResult - NewFilter: (newItem: Instance, parent: Instance) -> EnumFilterResult - PropertyFilter: (changingItem: Instance, member: string, value: any) -> EnumFilterResult - function PreventTerrainChanges(self): nil - function SetBasicFilteringEnabled(self, value: boolean): nil end declare class NetworkSettings extends Instance @@ -2721,7 +2535,7 @@ declare class NetworkSettings extends Instance ExtraMemoryUsed: number FreeMemoryMBytes: number FreeMemoryPoolMBytes: number - IncommingReplicationLag: number -- bruh + IncommingReplicationLag: number IsQueueErrorComputed: boolean IsThrottledByCongestionControl: boolean IsThrottledByOutgoingBandwidthLimit: boolean @@ -2747,6 +2561,17 @@ declare class NetworkSettings extends Instance TrackPhysicsDetails: boolean UseInstancePacketCache: boolean UsePhysicsPacketCache: boolean + WaitingForCharacterLogRate: number +end + +declare class NumberValue extends Instance + Changed: RBXScriptSignal + Value: number +end + +declare class ObjectValue extends Instance + Changed: RBXScriptSignal + Value: Instance? end declare class PVInstance extends Instance @@ -2757,25 +2582,24 @@ declare class BasePart extends PVInstance BackParamA: number BackParamB: number BackSurface: EnumSurfaceType - BackSurfaceInput: EnumSurfaceType + BackSurfaceInput: EnumInputType BottomParamA: number BottomParamB: number BottomSurface: EnumSurfaceType - BottomSurfaceInput: EnumSurfaceType + BottomSurfaceInput: EnumInputType BrickColor: BrickColor CFrame: CFrame CanCollide: boolean - Color: Color3 Elasticity: number Friction: number FrontParamA: number FrontParamB: number FrontSurface: EnumSurfaceType - FrontSurfaceInput: EnumSurfaceType + FrontSurfaceInput: EnumInputType LeftParamA: number LeftParamB: number LeftSurface: EnumSurfaceType - LeftSurfaceInput: EnumSurfaceType + LeftSurfaceInput: EnumInputType Locked: boolean Material: EnumMaterial Position: Vector3 @@ -2786,25 +2610,26 @@ declare class BasePart extends PVInstance RightParamA: number RightParamB: number RightSurface: EnumSurfaceType - RightSurfaceInput: EnumSurfaceType - Rotation: Vector3 + RightSurfaceInput: EnumInputType RotVelocity: Vector3 + Rotation: Vector3 Size: Vector3 - SpecificGravity: number -- might be awesome actually? - TopParamA: number -- now back to these params again + SpecificGravity: number + StoppedTouching: RBXScriptSignal + TopParamA: number TopParamB: number TopSurface: EnumSurfaceType - TopSurfaceInput: EnumSurfaceType + TopSurfaceInput: EnumInputType TouchEnded: RBXScriptSignal - Touched: RBXScriptSignal -- even 2013 has better apis than modern js frameworks, it was truly ten years ahead of its time + Touched: RBXScriptSignal Transparency: number Velocity: Vector3 - function BreakJoints(self): nil + function BreakJoints(self): () function GetConnectedParts(self, recursive: boolean?): { BasePart } function GetMass(self): number function GetRootPart(self): BasePart function IsGrounded(self): boolean - function MakeJoints(self): nil + function MakeJoints(self): () function Resize(self, normalId: EnumNormalId, deltaAmount: number): boolean end @@ -2812,13 +2637,19 @@ declare class CornerWedgePart extends BasePart end declare class FormFactorPart extends BasePart - FormFactor: EnumFormFactor -- formFactor also exists + FormFactor: EnumFormFactor + formFactor: EnumFormFactor end declare class Part extends FormFactorPart Shape: EnumPartType end +declare class FlagStand extends Part + FlagCaptured: RBXScriptSignal + TeamColor: BrickColor +end + declare class Platform extends Part end @@ -2826,6 +2657,18 @@ declare class Seat extends Part Disabled: boolean end +declare class SkateboardPlatform extends Part + Controller: Object + ControllingHumanoid: Object + Equipped: RBXScriptSignal + MoveStateChanged: RBXScriptSignal + Steer: number + StickyWheels: boolean + Throttle: number + Unequipped: RBXScriptSignal + function ApplySpecificImpulse(self, impulseWorld: Vector3): () +end + declare class SpawnLocation extends Part AllowTeamChangeOnTouch: boolean Duration: number @@ -2836,39 +2679,35 @@ end declare class WedgePart extends FormFactorPart end --- various other part types do exist, including WedgePart, PrismPart, PyramidPart, ParallelRampPart, RightAngleRampPart, etc --- since they are NotBrowsable, they and their associated enums are not included +declare class ParallelRampPart extends BasePart +end ---[[ - declare class ParallelRampPart extends BasePart - end - - declare class PrismPart extends BasePart - Sides: EnumPrismSides - end - - declare class PyramidPart extends BasePart - Sides: EnumPyramidSides - end - - declare class RightAngleRampPart extends BasePart - end -]] +declare class PrismPart extends BasePart + Sides: EnumPrismSides +end + +declare class PyramidPart extends BasePart + Sides: EnumPyramidSides +end + +declare class RightAngleRampPart extends BasePart +end declare class Terrain extends BasePart MaxExtents: Region3int16 function AutowedgeCell(self, x: number, y: number, z: number): boolean - function AutowedgeCells(self, region: Region3int16): boolean + function AutowedgeCells(self, region: Region3int16): () function CellCenterToWorld(self, x: number, y: number, z: number): Vector3 function CellCornerToWorld(self, x: number, y: number, z: number): Vector3 - function Clear(self): nil - function CopyRegion(self, region: Region3int16): Instance -- "CopyRegion is not available" ?? bruh + function Clear(self): () + function CopyRegion(self, region: Region3int16): TerrainRegion function CountCells(self): number - function GetCell(self, x: number, y: number, z: number): { any } -- not quite sure what this returns - function GetWaterCell(self, x: number, y: number, z: number): { any } -- "tuple" - function PasteRegion(self, region: TerrainRegion, corner: Vector3int16, pasteEmptyCells: boolean): nil - function SetCell(self, x: number, y: number, z: number, material: EnumCellMaterial, block: EnumCellBlock, orientation: EnumCellOrientation): nil - function SetWaterCell(self, x: number, y: number, z: number, force: EnumWaterForce, direction: EnumWaterDirection): nil + function GetCell(self, x: number, y: number, z: number): any + function GetWaterCell(self, x: number, y: number, z: number): any + function PasteRegion(self, region: TerrainRegion, corner: Vector3int16, pasteEmptyCells: boolean): () + function SetCell(self, x: number, y: number, z: number, material: EnumCellMaterial, block: EnumCellBlock, orientation: EnumCellOrientation): () + function SetCells(self, region: Region3int16, material: EnumCellMaterial, block: EnumCellBlock, orientation: EnumCellOrientation): () + function SetWaterCell(self, x: number, y: number, z: number, force: EnumWaterForce, direction: EnumWaterDirection): () function WorldToCell(self, position: Vector3): Vector3 function WorldToCellPreferEmpty(self, position: Vector3): Vector3 function WorldToCellPreferSolid(self, position: Vector3): Vector3 @@ -2891,74 +2730,54 @@ end declare class Model extends PVInstance PrimaryPart: BasePart? - function BreakJoints(self): nil + function BreakJoints(self): () function GetModelCFrame(self): CFrame function GetModelSize(self): Vector3 - function MakeJoints(self): nil - function MoveTo(self, location: Vector3): nil - function ResetOrientationToIdentity(self): nil - function SetIdentityOrientation(self): nil - function TranslateBy(self, offset: Vector3): nil + function MakeJoints(self): () + function MoveTo(self, location: Vector3): () + function ResetOrientationToIdentity(self): () + function SetIdentityOrientation(self): () + function TranslateBy(self, offset: Vector3): () end -declare class BackpackItem extends Model - TextureId: Content -end - -declare class Tool extends BackpackItem - Activated: RBXScriptSignal<> - CanBeDropped: boolean - Deactivated: RBXScriptSignal<> - Enabled: boolean - Equipped: RBXScriptSignal - Grip: CFrame - GripForward: Vector3 - GripPos: Vector3 - GripRight: Vector3 - GripUp: Vector3 - ManualActivationOnly: boolean - RequiresHandle: boolean - ToolTip: string - Unequipped: RBXScriptSignal<> - function Activate(self): nil - function Deactivate(self): nil -end - - - - -declare class RootInstance extends Model -- huh +declare class RootInstance extends Model end declare class Workspace extends RootInstance - AirDensity: number - AllowThirdPartySales: boolean - CurrentCamera: Camera + CurrentCamera: Object DistributedGameTime: number - FallenPartsDestroyHeight: number - GlobalWind: Vector3 - Gravity: number - PersistentLoaded: RBXScriptSignal - StreamingEnabled: boolean -- brand -- spanking -- new -- + StreamingEnabled: boolean Terrain: Terrain - function CalculateJumpDistance(self, gravity: number, jumpPower: number, walkSpeed: number): number - function CalculateJumpHeight(self, gravity: number, jumpPower: number): number - function CalculateJumpPower(self, gravity: number, jumpHeight: number): number - function ExperimentalSolverIsEnabled(self): boolean + function BreakJoints(self, objects: { Instance }): () + function FindPartOnRay(self, ray: Ray, ignoreDescendentsInstance: Instance?, terrainCellsAreCubes: boolean?): any + function FindPartOnRayWithIgnoreList(self, ray: Ray, ignoreDescendentsTable: { Instance }, terrainCellsAreCubes: boolean?): any + function FindPartsInRegion3(self, region: Region3, ignoreDescendentsInstance: Instance?, maxParts: number?): { Instance } + function FindPartsInRegion3WithIgnoreList(self, region: Region3, ignoreDescendentsTable: { Instance }, maxParts: number?): { Instance } function GetNumAwakeParts(self): number function GetPhysicsThrottling(self): number function GetRealPhysicsFPS(self): number - function GetServerTimeNow(self): number - function PGSIsEnabled(self): boolean - function SetPhysicsThrottleEnabled(self, value: boolean): nil - function ZoomToExtents(self): nil + function InsertContent(self, url: Content): { Instance } + function IsRegion3Empty(self, region: Region3, ignoreDescendentsInstance: Instance?): boolean + function IsRegion3EmptyWithIgnoreList(self, region: Region3, ignoreDescendentsTable: { Instance }): boolean + function MakeJoints(self, objects: { Instance }): () + function SetPhysicsThrottleEnabled(self, value: boolean): () + function ZoomToExtents(self): () +end - function FindPartOnRay(self, ray: Ray, ignoreDescendantsInstance: Instance?, terrainCellsAreCubes: boolean?, ignoreWater: boolean?): { BasePart } -- deprecated camelCase variant also exists - function FindPartOnRayWithIgnoreList(self, ray: Ray, ignoreDescendantsTable: { Instance }, terrainCellsAreCubes: boolean?, ignoreWater: boolean?): { BasePart } - function FindPartsInRegion3(self, region: Region3, ignoreDescendantsInstance: Instance?, maxParts: number?): { BasePart } -- deprecated camelCase variant also exists - function InsertContent(self, url: Content): { Instance } -- yep, it's { Instance } - function IsRegion3Empty(self, region: Region3, ignoreDescendantsInstance: Instance?): boolean - function IsRegion3EmptyWithIgnoreList(self, region: Region3, ignoreDescendantsTable: { Instance }): boolean +declare class Status extends Model +end + +declare class PersonalServerService extends Instance + RoleSets: string + function Demote(self, player: Instance): () + function GetRoleSets(self, placeId: number): string + function Promote(self, player: Instance): () + function SetPersonalServerGetRankUrl(self, personalServerGetRankUrl: string): () + function SetPersonalServerRoleSetsUrl(self, personalServerRoleSetsUrl: string): () + function SetPersonalServerSetRankUrl(self, personalServerSetRankUrl: string): () +end + +declare class PhysicsPacketCache extends Instance end declare class PhysicsService extends Instance @@ -2981,7 +2800,7 @@ declare class PhysicsSettings extends Instance AreWorldCoordsShown: boolean IsReceiveAgeShown: boolean IsTreeShown: boolean - ParallelPhysics: boolean -- 'ooh's and 'aah's all round + ParallelPhysics: boolean PhysicsEnvironmentalThrottle: EnumEnviromentalPhysicsThrottle ThrottleAdjustTime: number end @@ -2999,11 +2818,11 @@ declare class Player extends Instance Chatted: RBXScriptSignal DataComplexity: number DataComplexityLimit: number - DataReady: boolean -- wow am I glad DataStores exist - FriendStatusChanged: RBXScriptSignal - Guest: boolean -- pfft + DataReady: boolean + FriendStatusChanged: RBXScriptSignal + Guest: boolean HasBuildTools: boolean - Idled: RBXScriptSignal -- You have been disconnected for being idle for 27 minutes. + Idled: RBXScriptSignal MaximumSimulationRadius: number MembershipType: EnumMembershipType Neutral: boolean @@ -3011,112 +2830,101 @@ declare class Player extends Instance PersonalServerRank: number SimulationRadius: number TeamColor: BrickColor - userId: number - - -- unsure if these exist at all times, they're children of Player - Backpack: Backpack - StarterGear: StarterGear - PlayerGui: PlayerGui - - function ClearCharacterAppearance(self): nil + function ClearCharacterAppearance(self): () function DistanceFromCharacter(self, point: Vector3): number - function GetFriendStatus(self, player: Player): EnumFriendStatus - function GetFriendsOnline(self, maxFriends: number?): { any } + function GetFriendStatus(self, player: Instance): EnumFriendStatus + function GetFriendsOnline(self, maxFriends: number?): { [any]: any } function GetMouse(self): Mouse function GetRankInGroup(self, groupId: number): number function GetRoleInGroup(self, groupId: number): string function GetUnder13(self): boolean - function GetWebPersonalServerRank(self): number -- "[backend]" ?? + function GetWebPersonalServerRank(self): string function IsBestFriendsWith(self, userId: number): boolean function IsFriendsWith(self, userId: number): boolean function IsInGroup(self, groupId: number): boolean - function JumpCharacter(self): nil -- "An error occured" because of course it did - function Kick(self, message: string?): nil + function JumpCharacter(self): () + function Kick(self): () function LoadBoolean(self, key: string): boolean - function LoadCharacter(self, inGame: boolean?): nil - function LoadCharacterAppearance(self, assetInstance: Instance): nil - function LoadData(self): nil + function LoadCharacter(self, inGame: boolean?): () + function LoadCharacterAppearance(self, assetInstance: Instance): () + function LoadData(self): () function LoadInstance(self, key: string): Instance function LoadNumber(self, key: string): number - function LoadString(self, key: string): string -- lelelamayo - function MoveCharacter(self, walkDirection: Vector2, maxWalkDelta: number): nil -- interestingly accepts a Vector2, :Move() won't exist until 163 (13/08/2014) - function RemoveCharacter(self): nil - function RequestFriendship(self, player: Player): nil - function RevokeFriendship(self, player: Player): nil - function SaveBoolean(self, key: string, value: boolean): nil - function SaveData(self): nil - function SaveInstance(self, key: string, value: Instance): nil - function SaveLeaderboardData(self): nil - function SaveNumber(self, key: string, value: number): nil - function SaveString(self, key: string, value: string): nil - function SetAccountAge(self, accountAge: number): nil - function SetMembershipType(self, membershipType: EnumMembershipType): nil - function SetSuperSafeChat(self, value: boolean): nil - function SetWebPersonalServerRank(self, rank: number): nil -- "WritePlayerSecurity" ??? - function WaitForDataReady(self): nil - - function SetUnder13(self, value: boolean): nil -- of course "An error occured", may be either deprecated at an unknown time or could be one of the longest deprecated methods in API history + function LoadString(self, key: string): string + function MoveCharacter(self, walkDirection: Vector2, maxWalkDelta: number): () + function RemoveCharacter(self): () + function RequestFriendship(self, player: Instance): () + function RevokeFriendship(self, player: Instance): () + function SaveBoolean(self, key: string, value: boolean): () + function SaveData(self): () + function SaveInstance(self, key: string, value: Instance): () + function SaveLeaderboardData(self): () + function SaveNumber(self, key: string, value: number): () + function SaveString(self, key: string, value: string): () + function SetAccountAge(self, accountAge: number): () + function SetMembershipType(self, membershipType: EnumMembershipType): () + function SetSuperSafeChat(self, value: boolean): () + function WaitForDataReady(self): boolean + userId: number end declare class Players extends Instance BubbleChat: boolean CharacterAutoLoads: boolean ClassicChat: boolean - FriendRequestEvent: RBXScriptSignal + FriendRequestEvent: RBXScriptSignal GameAnnounce: RBXScriptSignal LocalPlayer: Player - MaxPlayers: number NumPlayers: number PlayerAdded: RBXScriptSignal - PlayerAddedEarly: RBXScriptSignal + PlayerAddedEarly: RBXScriptSignal PlayerChatted: RBXScriptSignal PlayerRemoving: RBXScriptSignal - PlayerRemovingLate: RBXScriptSignal - function AddLeaderboardKey(self, key: string): nil -- this exists?? can't tell if it works - function Chat(self, message: string): nil - function CreateLocalPlayer(self, id: number): Player - function GetPlayerByID(self, userId: number): Player? + PlayerRemovingLate: RBXScriptSignal + function AddLeaderboardKey(self, key: string): () + function Chat(self, message: string): () + function CreateLocalPlayer(self, userId: number): Instance + function GetPlayerByID(self, userID: number): Instance function GetPlayerFromCharacter(self, character: Model): Player? function GetPlayers(self): { Player } - function ReportAbuse(self, player: Player, reason: string, optionalMessage: string): nil -- >be me >reviewing 2013 api at 4am >`optionalMessage` >required argument - function SetAbuseReportUrl(self, url: string): nil - function SetBuildUserPermissionsUrl(self, url: string): nil - function SetChatFilterUrl(self, url: string): nil - function SetChatStyle(self, style: EnumChatStyle?): nil - function SetLoadDataUrl(self, url: string): nil - function SetSaveDataUrl(self, url: string): nil - function SetSaveLeaderboardDataUrl(self, url: string): nil - function SetSysStatsUrl(self, url: string): nil - function SetSysStatsUrlId(self, urlId: string): nil - function TeamChat(self, message: string): nil - function WhisperChat(self, message: string, player: Instance): nil -- todo test it's probably Player as well + function ReportAbuse(self, player: Instance, reason: string, optionalMessage: string): () + function SetChatStyle(self, style: EnumChatStyle?): () + function SetLoadDataUrl(self, url: string): () + function SetSaveDataUrl(self, url: string): () + function SetSaveLeaderboardDataUrl(self, url: string): () + function SetSysStatsUrl(self, url: string): () + function SetSysStatsUrlId(self, urlId: string): () + function TeamChat(self, message: string): () + function WhisperChat(self, message: string, player: Instance): () end declare class Plugin extends Instance Deactivation: RBXScriptSignal<> - function Activate(self, exclusiveMouse: boolean): nil + function Activate(self, exclusiveMouse: boolean): () function CreateToolbar(self, name: string): Instance function GetMouse(self): PluginMouse function GetSetting(self, key: string): any function GetStudioUserId(self): number - function SaveSelectedToRoblox(self): nil - function SetSetting(self, key: string, value: any): nil + function SaveSelectedToRoblox(self): () + function SetSetting(self, key: string, value: any): () end declare class PluginManager extends Instance - function CreatePlugin(self): Plugin -- probably fucking Plugin, todo test AGAIN + function CreatePlugin(self): Instance end declare class Pose extends Instance CFrame: CFrame MaskWeight: number Weight: number - function AddSubPose(self, pose: Pose): nil -- finally, a typed return that isn't just Instance - -- in Haskell you have the universal type, string -> string - -- in 2013, we have Instance -> nil instead - -- this bad boy can fit so much unclarity in it + function AddSubPose(self, pose: Pose): () function GetSubPoses(self): { Instance } - function RemoveSubPose(self, pose: Pose): nil + function RemoveSubPose(self, pose: Pose): () +end + +declare class RayValue extends Instance + Changed: RBXScriptSignal + Value: Ray end declare class ReflectionMetadata extends Instance @@ -3141,7 +2949,6 @@ declare class ReflectionMetadataItem extends Instance summary: string end --- confusing ass name broke the defs.d.lua parser I wrote in 20 seconds declare class ReflectionMetadataClass extends ReflectionMetadataItem ExplorerImageIndex: number ExplorerOrder: number @@ -3157,8 +2964,6 @@ end declare class ReflectionMetadataYieldFunctions extends Instance end --- Revel in this, you don't get it often. --- Event-based programming over the network truly is timeless. Did I mention that 2013 was ten years ahead of its time? declare class RemoteEvent extends Instance OnClientEvent: RBXScriptSignal<...any> OnServerEvent: RBXScriptSignal<(Player, ...any)> @@ -3167,8 +2972,6 @@ declare class RemoteEvent extends Instance function FireServer(self, ...: any): () end --- Functionality that was brand new at the time, and in the decade since then, hasn't changed a jot. --- Revolutionary then, now a staple of development and still something back-of-the-frontend/front-of-the-backend Typescript developers go wild for today. declare class RemoteFunction extends Instance OnClientInvoke: (...any) -> ...any OnServerInvoke: (player: Player, ...any) -> ...any @@ -3177,10 +2980,10 @@ declare class RemoteFunction extends Instance end declare class RenderHooksService extends Instance - function CaptureMetrics(self): nil - function DisableQueue(self, qId: number): nil - function EnableAdorns(self, enabled: boolean): nil - function EnableQueue(self, qId: number): nil + function CaptureMetrics(self): () + function DisableQueue(self, qId: number): () + function EnableAdorns(self, enabled: boolean): () + function EnableQueue(self, qId: number): () function GetDeltaAve(self): number function GetGPUDelay(self): number function GetPresentTime(self): number @@ -3188,9 +2991,9 @@ declare class RenderHooksService extends Instance function GetRenderConfMax(self): number function GetRenderConfMin(self): number function GetRenderStd(self): number - function PrintScene(self): nil - function ReloadShaders(self): nil - function ResizeWindow(self, width: number, height: number): nil + function PrintScene(self): () + function ReloadShaders(self): () + function ResizeWindow(self, width: number, height: number): () end declare class RenderSettings extends Instance @@ -3202,7 +3005,6 @@ declare class RenderSettings extends Instance EagerBulkExecution: boolean EnableFRM: boolean FrameRateManager: EnumFramerateManagerMode - graphicsMode: EnumGraphicsMode IsAggregationShown: boolean IsSynchronizedWithPhysics: boolean MeshCacheSize: number @@ -3213,6 +3015,7 @@ declare class RenderSettings extends Instance TextureCacheSize: number UsesPaintMessage: boolean function GetMaxQualityLevel(self): number + graphicsMode: EnumGraphicsMode end declare class ReplicatedStorage extends Instance @@ -3220,30 +3023,31 @@ end declare class RunService extends Instance Heartbeat: RBXScriptSignal - RenderStepped: RBXScriptSignal - Stepped: RBXScriptSignal -- "(double time, double step)" double time? no way - function Pause(self): nil - function Run(self): nil - function Stop(self): nil + RenderStepped: RBXScriptSignal<> + Stepped: RBXScriptSignal + function Pause(self): () + function Run(self): () + function Stop(self): () end declare class RuntimeScriptService extends Instance end declare class ScriptContext extends Instance - CamelCaseViolation: RBXScriptSignal -- LOLL (also instance is probably a BaseScript or something) - Error: RBXScriptSignal + CamelCaseViolation: RBXScriptSignal GarbageCollectionFrequency: number GarbageCollectionLimit: number ScriptsDisabled: boolean - function AddCoreScript(self, assetId: number, parent: Instance, name: string): nil -- player or instance - function AddStarterScript(self, assetId: number): nil - function GetHeapStats(self): { any } -- no clue - function LibraryRegistrationComplete(self): nil - function RegisterLibrary(self, libraryName: string, assetId: string): nil - function RegisterRobloxLibrary(self, libraryName: string, assetId: string): nil -- must try this out and see wtf it does - function SetCollectScriptStats(self, enable: boolean?): nil - function SetTimeout(self, seconds: number): nil + function AddCoreScript(self, assetId: number, parent: Instance, name: string): () + function AddStarterScript(self, assetId: number): () + function GetHeapStats(self, clearHighwaterMark: boolean?): any + function GetScriptStats(self): { any } + function LibraryRegistrationComplete(self): () + function RegisterDevelopmentLibrary(self, libraryName: string, scriptInstance: Instance): () + function RegisterLibrary(self, libraryName: string, assetId: string): () + function RegisterRobloxLibrary(self, libraryName: string, assetId: string): () + function SetCollectScriptStats(self, enable: boolean?): () + function SetTimeout(self, seconds: number): () end declare class ScriptDebugger extends Instance @@ -3254,33 +3058,38 @@ declare class ScriptDebugger extends Instance IsDebugging: boolean IsPaused: boolean Resuming: RBXScriptSignal<> - Script: Instance + Script: Object WatchAdded: RBXScriptSignal WatchRemoved: RBXScriptSignal function AddWatch(self, expression: string): Instance function GetBreakpoints(self): { Instance } - function GetGlobals(self, stackFrame: number?): { [any]: any } + function GetGlobals(self): { [any]: any } function GetLocals(self, stackFrame: number?): { [any]: any } function GetStack(self): { any } function GetUpvalues(self, stackFrame: number?): { [any]: any } function GetWatchValue(self, watch: Instance): any function GetWatches(self): { Instance } - function SetBreakpoint(self, line: number, isContextDependentBreakpoint: boolean): Instance - function SetGlobal(self, name: string, value: any, stackFrame: number): nil - function SetLocal(self, name: string, value: any, stackFrame: number?): nil - function SetUpvalue(self, name: string, value: any, stackFrame: number?): nil - function StepIn(self): nil - function StepOut(self): nil - function StepOver(self): nil + function Resume(self): () + function SetBreakpoint(self, line: number): Instance + function SetGlobal(self, name: string, value: any): () + function SetLocal(self, name: string, value: any, stackFrame: number?): () + function SetUpvalue(self, name: string, value: any, stackFrame: number?): () + function StepIn(self): () + function StepOut(self): () + function StepOver(self): () end -declare class ScriptService extends Instance -- you've heard of ServerScriptService, +declare class ScriptInformationProvider extends Instance + function SetAssetUrl(self, url: string): () +end + +declare class ScriptService extends Instance end declare class Selection extends Instance - SelectionChanged: RBXScriptSignal<> -- "something changed! good luck figuring out what lmao" + SelectionChanged: RBXScriptSignal<> function Get(self): { Instance } - function Set(self, selection: { Instance }): nil + function Set(self, selection: { Instance }): () end declare class ServerScriptService extends Instance @@ -3289,181 +3098,40 @@ end declare class ServerStorage extends Instance end -declare class ThumbnailGenerator extends Instance -- Tap in rcc before carrot gets it - function Click(self, format: "PNG" | "OBJ", x: number, y: number, hideSky: boolean, crop: boolean?): string -end -- "Stop looking back, what God has for you, you have not seen before and it's not back there!! #NewCreature #GetOutofYourOwnWay #RCCService" - Josh Brown @JoshLB, sometime in 2016 - declare class ServiceProvider extends Instance Close: RBXScriptSignal<> CloseLate: RBXScriptSignal<> ServiceAdded: RBXScriptSignal ServiceRemoving: RBXScriptSignal - - AssetService: AssetService - BadgeService: BadgeService - CacheableContentProvider: CacheableContentProvider - ChangeHistoryService: ChangeHistoryService - Chat: Chat - ClusterPacketCache: ClusterPacketCache - CollectionService: CollectionService - ContentProvider: ContentProvider - ContextActionService: ContextActionService - ControllerService: ControllerService - CookiesService: CookiesService - CoreGui: CoreGui - DataStoreService: DataStoreService - Debris: Debris - DebuggerManager: DebuggerManager - FlagStandService: FlagStandService - FriendService: FriendService - GamePassService: GamePassService - GamepadService: GamepadService - GuiService: GuiService - GuidRegistryService: GuidRegistryService - HttpService: HttpService - InsertService: InsertService - KeyframeSequenceProvider: KeyframeSequenceProvider - Lighting: Lighting - LoginService: LoginService - LuaWebService: LuaWebService - MarketplaceService: MarketplaceService - MeshContentProvider: MeshContentProvider - NetworkClient: NetworkClient - NetworkServer: NetworkServer - NetworkSettings: NetworkSettings - PhysicsService: PhysicsService - Players: Players - RenderSettings: RenderSettings - ReplicatedStorage: ReplicatedStorage - RunService: RunService - RuntimeScriptService: RuntimeScriptService - ScriptContext: ScriptContext - ScriptService: ScriptService - Selection: Selection - ServerScriptService: ServerScriptService - ServerStorage: ServerStorage - SocialService: SocialService - SoundService: SoundService - SpawnerService: SpawnerService - StarterGui: StarterGui - StarterPack: StarterPack - StarterPlayer: StarterPlayer - Stats: Stats - TaskScheduler: TaskScheduler - TeamCreateData: TeamCreateData - TeamCreateService: TeamCreateService - Teams: Teams - TeleportService: TeleportService - TestService: TestService - TimerService: TimerService - UserInputService: UserInputService - VirtualUser: VirtualUser - Visit: Visit - Workspace: Workspace - - LoadingGuiService: any - ScriptInformationProvider: ScriptInformationProvider - JointsService: JointsService - ThumbnailGenerator: ThumbnailGenerator - function FindService(self, className: string): Instance - function GetService(self, service: "AssetService"): AssetService - function GetService(self, service: "BadgeService"): BadgeService - function GetService(self, service: "CacheableContentProvider"): CacheableContentProvider - function GetService(self, service: "ChangeHistoryService"): ChangeHistoryService - function GetService(self, service: "Chat"): Chat - function GetService(self, service: "ClusterPacketCache"): ClusterPacketCache - function GetService(self, service: "CollectionService"): CollectionService - function GetService(self, service: "ContentProvider"): ContentProvider - function GetService(self, service: "ContextActionService"): ContextActionService - function GetService(self, service: "ControllerService"): ControllerService - function GetService(self, service: "CookiesService"): CookiesService - function GetService(self, service: "CoreGui"): CoreGui - function GetService(self, service: "DataStoreService"): DataStoreService - function GetService(self, service: "Debris"): Debris - function GetService(self, service: "DebuggerManager"): DebuggerManager - function GetService(self, service: "FlagStandService"): FlagStandService - function GetService(self, service: "FriendService"): FriendService - function GetService(self, service: "GamePassService"): GamePassService - function GetService(self, service: "GamepadService"): GamepadService - function GetService(self, service: "GuiService"): GuiService - function GetService(self, service: "GuidRegistryService"): GuidRegistryService - function GetService(self, service: "Hopper"): Hopper - function GetService(self, service: "HttpService"): HttpService - function GetService(self, service: "InsertService"): InsertService - function GetService(self, service: "JointsService"): JointsService - function GetService(self, service: "KeyframeSequenceProvider"): KeyframeSequenceProvider - function GetService(self, service: "Lighting"): Lighting - function GetService(self, service: "LoginService"): LoginService - function GetService(self, service: "LuaWebService"): LuaWebService - function GetService(self, service: "MarketplaceService"): MarketplaceService - function GetService(self, service: "MeshContentProvider"): MeshContentProvider - function GetService(self, service: "NetworkClient"): NetworkClient - function GetService(self, service: "NetworkServer"): NetworkServer - function GetService(self, service: "NetworkSettings"): NetworkSettings - function GetService(self, service: "PhysicsService"): PhysicsService - function GetService(self, service: "Players"): Players - function GetService(self, service: "PointsService"): PointsService - function GetService(self, service: "RenderSettings"): RenderSettings - function GetService(self, service: "ReplicatedStorage"): ReplicatedStorage - function GetService(self, service: "RunService"): RunService - function GetService(self, service: "RuntimeScriptService"): RuntimeScriptService - function GetService(self, service: "ScriptContext"): ScriptContext - function GetService(self, service: "ScriptService"): ScriptService - function GetService(self, service: "Selection"): Selection - function GetService(self, service: "ServerScriptService"): ServerScriptService - function GetService(self, service: "ServerStorage"): ServerStorage - function GetService(self, service: "SocialService"): SocialService - function GetService(self, service: "SoundService"): SoundService - function GetService(self, service: "SpawnerService"): SpawnerService - function GetService(self, service: "StarterGui"): StarterGui - function GetService(self, service: "StarterPack"): StarterPack - function GetService(self, service: "StarterPlayer"): StarterPlayer - function GetService(self, service: "Stats"): Stats - function GetService(self, service: "TaskScheduler"): TaskScheduler - function GetService(self, service: "TeamCreateData"): TeamCreateData - function GetService(self, service: "TeamCreateService"): TeamCreateService - function GetService(self, service: "Teams"): Teams - function GetService(self, service: "TeleportService"): TeleportService - function GetService(self, service: "TestService"): TestService - function GetService(self, service: "TimerService"): TimerService - function GetService(self, service: "TweenService"): nil - function GetService(self, service: "UserInputService"): UserInputService - function GetService(self, service: "VirtualUser"): VirtualUser - function GetService(self, service: "Visit"): Visit - function GetService(self, service: "Workspace"): Workspace - - function GetService(self, service: "ScriptInformationProvider"): ScriptInformationProvider - function GetService(self, service: "LoadingGuiService"): any - function GetService(self, service: "PersonalServerService"): PersonalServerService - function GetService(self, service: "Terrain"): Terrain - function GetService(self, service: "ThumbnailGenerator"): ThumbnailGenerator + function GetService(self, className: string): Instance end declare class DataModel extends ServiceProvider - AllowedGearTypesChanged: RBXScriptSignal<> + AllowedGearTypeChanged: RBXScriptSignal<> CreatorId: number CreatorType: EnumCreatorType GearGenreSetting: EnumGearGenreSetting Genre: EnumGenre GraphicsQualityChangeRequest: RBXScriptSignal - ItemChanged: RBXScriptSignal -- api ref says "Property" and I haven't a clue what that might mean, oh turns out it's just a string + IsPersonalServer: boolean + ItemChanged: RBXScriptSignal JobId: string Loaded: RBXScriptSignal<> LocalSaveEnabled: boolean PlaceId: number PlaceVersion: number - RequestShutdown: (...any) -> ...any - Workspace: Workspace - function AddStat(self, displayName: string, stat: string): nil - function ClearContent(self, resettingSimulation: boolean): nil - function ClearMessage(self): nil + RequestShutdown: () -> boolean + Workspace: Object + function AddStat(self, displayName: string, stat: string): () + function ClearContent(self, resettingSimulation: boolean): () + function ClearMessage(self): () function CreatePlace(self, placeName: string, templatePlaceID: number): number - function FinishShutdown(self, localSave: boolean): nil + function FinishShutdown(self, localSave: boolean): () function GetJobIntervalPeakFraction(self, jobname: string, greaterThan: number): number + function GetJobTimePeakFraction(self, jobname: string, greaterThan: number): number function GetJobsExtendedStats(self): { any } function GetJobsInfo(self): { any } - function GetJobTimePeakFraction(self, jobname: string, greaterThan: number): number function GetObjects(self, url: Content): { Instance } function GetRemoteBuildMode(self): boolean function HttpGet(self, url: string, synchronous: boolean?): string @@ -3472,48 +3140,47 @@ declare class DataModel extends ServiceProvider function HttpPostAsync(self, url: string, data: string): string function IsGearTypeAllowed(self, gearType: EnumGearType): boolean function IsLoaded(self): boolean - function Load(self, url: Content): nil - -- function Loaded(self): nil -- can't park there mate - function LoadGame(self, assetID: number): nil - function LoadPlugins(self): nil - function LoadWorld(self, assetID: number): nil - function RemoveStat(self, stat: string): nil - function ReportMeasurement(self, id: string, key1: string, value1: string, key2: string, value2: string): nil - function Save(self, url: Content): nil - function SavePlace(self, saveFilter: EnumSaveFilter?): ...any - function SaveStats(self): nil + function Load(self, url: Content): () + function LoadGame(self, assetID: number): () + function LoadWorld(self, assetID: number): () + function RemoveStat(self, stat: string): () + function ReportMeasurement(self, id: string, key1: string, value1: string, key2: string, value2: string): () + function SavePlace(self, saveFilter: EnumSaveFilter?): any + function SaveStats(self): () function SaveToRoblox(self): boolean - function ServerSave(self): nil - function SetCreatorId(self, creatorId: number, creatorType: EnumCreatorType): nil - function SetGearSettings(self, genreRestriction: EnumGearGenreSetting, allowedGenres: number): nil - function SetGenre(self, genre: EnumGenre): nil - function SetJobsExtendedStatsWindow(self, seconds: number): nil - function SetMessage(self, message: string): nil - function SetMessageBrickCount(self): nil - function SetPlaceId(self, placeId: number, robloxPlace: boolean?): nil - function SetPlaceVersion(self, placeId: number): nil - function SetRemoteBuildMode(self, buildModeEnabled: boolean): nil - function SetScreenshotInfo(self, info: string): nil - function SetServerSaveUrl(self, url: string): nil - function SetVideoInfo(self, info: string): nil - function Shutdown(self): nil - function ToggleTools(self): nil + function ServerSave(self): () + function SetCreatorId(self, creatorId: number, creatorType: EnumCreatorType): () + function SetGearSettings(self, genreRestriction: EnumGearGenreSetting, allowedGenres: number): () + function SetGenre(self, genre: EnumGenre): () + function SetJobsExtendedStatsWindow(self, seconds: number): () + function SetMessage(self, message: string): () + function SetMessageBrickCount(self): () + function SetPlaceId(self, placeId: number, robloxPlace: boolean?): () + function SetPlaceVersion(self, placeId: number): () + function SetRemoteBuildMode(self, buildModeEnabled: boolean): () + function SetScreenshotInfo(self, info: string): () + function SetServerSaveUrl(self, url: string): () + function SetVideoInfo(self, info: string): () + function Shutdown(self): () + function ToggleTools(self): () end -declare class App extends DataModel -- this class lasted about 20 versions, with 2013 being smack dab in the middle of its tiny lifespan +declare class App extends DataModel Id: number - function ConnectToGame(self, placeId: number, actionName: string): nil - function FollowUser(self, userId: number): nil - function GetCreations(self, userId: number, page: number?): { [any]: any } -- just says "Dictionary" and I'm not testing this. BETTER A WIDE TYPE THAN A WRONG ONE - function SetAppId(self, newId: number): nil - function UnloadGame(self): nil + function ConnectToGame(self, placeId: number, actionName: string?): () + function FollowUser(self, userId: number): () + function GetCreations(self, userId: number, page: number?): { [any]: any } + function SetAppId(self, newId: number): () + function UnloadGame(self): () end declare class GenericSettings extends ServiceProvider end declare class UserSettings extends GenericSettings - function Reset(self): nil + GameSettings: UserGameSettings + function GetService(self, service: "UserGameSettings"): UserGameSettings + function Reset(self): () end declare class Sky extends Instance @@ -3536,25 +3203,26 @@ declare class Smoke extends Instance end declare class SocialService extends Instance - function SetBestFriendUrl(self, bestFriendUrl: string): nil - function SetFriendUrl(self, friendUrl: string): nil - function SetGroupRankUrl(self, groupRankUrl: string): nil - function SetGroupRoleUrl(self, groupRoleUrl: string): nil - function SetGroupUrl(self, groupUrl: string): nil - function SetPackageContentsUrl(self, stuffUrl: string): nil - function SetStuffUrl(self, stuffUrl: string): nil -- only 2013 would have a class, method, and url relating to "Stuff" that would still be in use four years later + function SetBestFriendUrl(self, bestFriendUrl: string): () + function SetFriendUrl(self, friendUrl: string): () + function SetGroupRankUrl(self, groupRankUrl: string): () + function SetGroupRoleUrl(self, groupRoleUrl: string): () + function SetGroupUrl(self, groupUrl: string): () + function SetPackageContentsUrl(self, stuffUrl: string): () + function SetStuffUrl(self, stuffUrl: string): () end declare class Sound extends Instance IsPaused: boolean IsPlaying: boolean Looped: boolean + Pitch: number PlayOnRemove: boolean SoundId: Content Volume: number - function Pause(self): nil - function Play(self): nil - function Stop(self): nil + function Pause(self): () + function Play(self): () + function Stop(self): () end declare class StockSound extends Sound @@ -3565,10 +3233,7 @@ declare class SoundService extends Instance DistanceFactor: number DopplerScale: number RolloffScale: number - function PlayStockSound(self, sound: EnumSoundType): nil - -- Every time I reload the language server to test it and it fails, I die a little inside - -- just glad the Luau LSP actually shows errors in definition files now - -- the hard bass of 7th Flicker is helping me cope + function PlayStockSound(self, sound: EnumSoundType): () end declare class Sparkles extends Instance @@ -3583,38 +3248,13 @@ end declare class StarterGear extends Instance end -declare class StarterPack extends GuiItem -end - -declare class PlayerHUD extends GuiItem -- we're DEEP deep in the api now (aka it's now 5am) -end - -declare class GuiRoot extends GuiItem -end - -declare class ButtonBindingWidget extends GuiItem -end - -declare class LocalBackpack extends GuiItem - function GetOldSchoolBackpack(self): boolean -- I'm glad I have the Finobe OST to keep me company through these trying times - function SetOldSchoolBackpack(self, show: boolean): nil -- is anybody going to use any of these functions? is anybody going to use any of these classes? is anybody here? -end - -declare class StarterPlayer extends Instance - CameraMaxZoomDistance: number - CameraMinZoomDistance: number - CameraMode: EnumCameraMode - HealthDisplayDistance: number - NameDisplayDistance: number -end - declare class Stats extends Instance MinReportInterval: number ReporterType: string - function Report(self, category: string, data: { [any]: any }): nil -- oh, copilot is also here to keep me company! say hi copilot (copilot's response: "hi") - function ReportJobsWindow(self): nil - function ReportTaskScheduler(self, includeJobs: boolean?): nil - function SetReportUrl(self, url: string): nil + function Report(self, category: string, data: { [any]: any }): () + function ReportJobsStepWindow(self): () + function ReportTaskScheduler(self, includeJobs: boolean?): () + function SetReportUrl(self, url: string): () end declare class StatsItem extends Instance @@ -3622,9 +3262,9 @@ declare class StatsItem extends Instance function GetValueString(self): string end -declare class ProfilingItem extends StatsItem -- dude what am I documenting, who's using this it was removed eight years ago - function GetTimes(self, window: number?): ...any - function GetTimesForFrames(self, frames: number?): ...any -- just saw that great talk from the creator of the Roc lang about why static typing is gonna take over the world and incremental typing isn't gonna cut it, now I see why +declare class ProfilingItem extends StatsItem + function GetTimes(self, window: number?): any + function GetTimesForFrames(self, frames: number?): any end declare class RunningAverageItemDouble extends StatsItem @@ -3639,19 +3279,21 @@ end declare class TotalCountTimeIntervalItem extends StatsItem end -declare class StudioTool extends Instance -- I'm going insane +declare class StringValue extends Instance + Changed: RBXScriptSignal + Value: string +end + +declare class StudioTool extends Instance Activated: RBXScriptSignal<> Deactivated: RBXScriptSignal<> Enabled: boolean - Equipped: RBXScriptSignal -- Test this it's probably a mouse cuz the api name says so + Equipped: RBXScriptSignal Unequipped: RBXScriptSignal<> end --- `Studio` doesn't even exist --- glad I've been testing to see whether methods return correct results on a class that won't exist for another five years - declare class TaskScheduler extends Instance - AreArbitersThrottled: boolean -- Uhh carrot just got the Arbiter + AreArbitersThrottled: boolean Concurrency: EnumConcurrencyModel NumRunningJobs: number NumSleepingJobs: number @@ -3664,7 +3306,7 @@ declare class TaskScheduler extends Instance ThreadPoolConfig: EnumThreadPoolConfig ThreadPoolSize: number ThrottledJobSleepTime: number - function AddDummyJob(self, exclusive: boolean?, fps: number?): nil + function AddDummyJob(self, exclusive: boolean?, fps: number?): () end declare class Team extends Instance @@ -3672,34 +3314,28 @@ declare class Team extends Instance AutoColorCharacters: boolean Score: number TeamColor: BrickColor -end - -declare class TeamCreateData extends Instance -end - -declare class TeamCreateService extends Instance - ToggleManageCollaborators: RBXScriptSignal<> - function CloseGameIfUserDoesntHavePerms(self): nil + function GetPlayers(self): { Player } end declare class Teams extends Instance - function GetTeams(self): { Team } - function RebalanceTeams(self): nil + function RebalanceTeams(self): () end -declare class TeleportService extends Instance -- copilot and the Finobe OST (currently playing Whaley's World) may be the only things keeping me company at this time, but https://robloxapi.github.io/ref/ is still my guiding light and true companion through the night - MenuTeleportAttempt: RBXScriptSignal<> - function SetTeleportGui(self, gui: GuiObject): nil - function Teleport(self, placeId: number, player: Player?, teleportData: any, customLoadingScreen: GuiObject?): nil - function TeleportCancel(self): nil - function TeleportToSpawnByName(self, placeId: number, spawnName: string, player: Player?, teleportData: any, customLoadingScreen: GuiObject?): nil +declare class TeleportService extends Instance + ConfirmationCallback: (message: string, placeId: number, spawnName: string) -> boolean + CustomizedTeleportUI: boolean + ErrorCallback: (message: string) -> () + function Teleport(self, placeId: number, player: Player?): () + function TeleportCancel(self): () + function TeleportImpl(self, placeId: number, spawnName: string): () + function TeleportToSpawnByName(self, placeId: number, spawnName: string, player: Player?): () end declare class TerrainRegion extends Instance SizeInCells: Vector3 end -declare class TestService extends Instance -- the comments I'm writing are beginning to actually help now, I can't remember the class I documented five seconds ago so I ctrl+F for the comment I just wrote instead +declare class TestService extends Instance AutoRuns: boolean Description: string ErrorCount: number @@ -3707,39 +3343,42 @@ declare class TestService extends Instance -- the comments I'm writing are begin IsPhysicsEnvironmentalThrottled: boolean IsSleepAllowed: boolean NumberOfPlayers: number - ServerCollectConditionalResult: RBXScriptSignal -- deep in thought now, wondering why RBXScriptSignal connection arguments don't have names attached - ServerCollectResult: RBXScriptSignal -- presumably because you add your own names in the function definition + ServerCollectConditionalResult: RBXScriptSignal + ServerCollectResult: RBXScriptSignal TestCount: number Timeout: number WarnCount: number - function Check(self, condition: boolean, description: string, source: Instance?, line: number?): nil - function Checkpoint(self, text: string, source: Instance?, line: number?): nil - function DoCommand(self, name: string): nil - function Done(self): nil - function Error(self, description: string, source: Instance?, line: number?): nil - function Fail(self, description: string, source: Instance?, line: number?): nil - function GetCommandNames(self): { string } -- it's most certainly { string } but I'm not taking any chances at this point (edit: yeah it is, after opening up Mercury studio and typing `for i,v in pairs(thing) do print(i,v) end` for the hundredth time today) + function Check(self, condition: boolean, description: string, source: Instance?, line: number?): () + function Checkpoint(self, text: string, source: Instance?, line: number?): () + function DoCommand(self, name: string): () + function Done(self): () + function Error(self, description: string, source: Instance?, line: number?): () + function Fail(self, description: string, source: Instance?, line: number?): () + function GetCommandNames(self): { any } function IsCommandChecked(self, name: string): boolean - function IsCommandEnabled(self, name: string): boolean -- what's killing me is the knowledge this file was machine-generated and I could probably have written a script to, in a fraction of a second, do what took me several months - function Message(self, text: string, source: Instance?, line: number?): nil -- but I'm in too deep now, and the file has been cut from like 8000 to 4000 lines in the last couple days, so it feels so close - function Require(self, condition: boolean, description: string, source: Instance?, line: number?): nil - function Run(self): nil - function Warn(self, condition: boolean, description: string, source: Instance?, line: number?): nil + function IsCommandEnabled(self, name: string): boolean + function Message(self, text: string, source: Instance?, line: number?): () + function Require(self, condition: boolean, description: string, source: Instance?, line: number?): () + function Run(self): () + function Warn(self, condition: boolean, description: string, source: Instance?, line: number?): () end -declare class TextService extends Instance -- dear diary, today I stumbled apon another class which seems to be timeless yet had no methods or properties until years, or in some cases, decades later +declare class TextService extends Instance end -declare class TimerService extends Instance -- what are they? accidentally exposed internal things? placeholders that were forgotten and given a new purpose later? or maybe it's part of the master plan, the grand design, the ultimate vision (rdc17 reference), it's David Baszucki's metaversal time travel 5D chess and we're all just board pieces +declare class TimerService extends Instance end declare class Toolbar extends Instance - function CreateButton(self, text: string, tooltip: string, iconname: string): Instance -- not enough brain power to think of what this could be + function CreateButton(self, text: string, tooltip: string, iconname: string): Instance end declare class TouchTransmitter extends Instance end +declare class TweenService extends Instance +end + declare class UserGameSettings extends Instance AllTutorialsDisabled: boolean ControlMode: EnumControlMode @@ -3748,96 +3387,34 @@ declare class UserGameSettings extends Instance SavedQualityLevel: EnumSavedQualitySetting StudioModeChanged: RBXScriptSignal VideoUploadPromptBehavior: EnumUploadSetting - function GetTutorialState(self, tutorialId: string): boolean function InFullScreen(self): boolean function InStudioMode(self): boolean - function SetTutorialState(self, tutorialId: string, value: boolean): nil + function SetTutorialState(self, tutorialId: string, value: boolean): () end declare class UserInputService extends Instance GamepadEnabled: boolean - InputBegan: RBXScriptSignal - InputChanged: RBXScriptSignal - InputEnded: RBXScriptSignal + InputBegan: RBXScriptSignal + InputChanged: RBXScriptSignal + InputEnded: RBXScriptSignal JumpRequest: RBXScriptSignal<> KeyboardEnabled: boolean ModalEnabled: boolean MouseEnabled: boolean - TouchEnded: RBXScriptSignal -- does every class must been an Instance - TouchLongPress: RBXScriptSignal<{ Vector2 }, EnumUserInputState> -- I'm losing comprehension of the world around me - TouchMoved: RBXScriptSignal -- Agn🔵sia + TouchEnabled: boolean + TouchEnded: RBXScriptSignal + TouchLongPress: RBXScriptSignal<{ Vector2 }, EnumUserInputState> + TouchMoved: RBXScriptSignal TouchPan: RBXScriptSignal<{ Vector2 }, Vector2, Vector2, EnumUserInputState> TouchPinch: RBXScriptSignal<{ Vector2 }, number, number, EnumUserInputState> TouchRotate: RBXScriptSignal<{ Vector2 }, number, number, EnumUserInputState> - TouchStarted: RBXScriptSignal + TouchStarted: RBXScriptSignal TouchSwipe: RBXScriptSignal TouchTap: RBXScriptSignal<{ Vector2 }> - - function IsLuaTouchControls(self): boolean -- Mercury will never get mobile, I can feel it - function RotateCamera(self, positionDelta: Vector2): nil - function ZoomCamera(self, zoomDelta: number): nil -end - -declare class BinaryStringValue extends Instance - Changed: RBXScriptSignal -end - -declare class BoolValue extends Instance - Changed: RBXScriptSignal - Value: boolean -end - -declare class BrickColorValue extends Instance - Changed: RBXScriptSignal - Value: BrickColor -end - -declare class CFrameValue extends Instance - Changed: RBXScriptSignal - Value: CFrame -end - -declare class Color3Value extends Instance - Changed: RBXScriptSignal - Value: Color3 -end - - -declare class ScriptInformationProvider extends Instance - function SetAccessKey(self, access: string): nil - function SetAssetUrl(self, url: string): nil -end - -declare class PersonalServerService extends Instance - function Promote(self, player: Player): nil - function Demote(self, player: Player): nil -end - - -declare class IntValue extends Instance - Changed: RBXScriptSignal - Value: number -end - -declare class NumberValue extends Instance - Changed: RBXScriptSignal - Value: number -end - -declare class ObjectValue extends Instance - Changed: RBXScriptSignal - Value: Instance? -end - -declare class RayValue extends Instance - Changed: RBXScriptSignal - Value: Ray -end - -declare class StringValue extends Instance - Changed: RBXScriptSignal - Value: string + function IsLuaTouchControls(self): boolean + function RotateCamera(self, positionDelta: Vector2): () + function ZoomCamera(self, zoomDelta: number): () end declare class Vector3Value extends Instance @@ -3846,167 +3423,30 @@ declare class Vector3Value extends Instance end declare class VirtualUser extends Instance - function Button1Down(self, position: Vector2, camera: CFrame?): nil -- is the Identity CFrame like the Identity Matrix or like the Identity Function? Is that like the zero value in Go? Is that similar to all the nils that rust definitely doesn't have? - function Button1Up(self, position: Vector2, camera: CFrame?): nil - function Button2Down(self, position: Vector2, camera: CFrame?): nil - function Button2Up(self, position: Vector2, camera: CFrame?): nil - function CaptureController(self): nil -- be nice if some of this stuff worked, it "An error occured" last time I checked I think and I'm not testing it again - function ClickButton1(self, position: Vector2, camera: CFrame?): nil - function ClickButton2(self, position: Vector2, camera: CFrame?): nil - function MoveMouse(self, position: Vector2, camera: CFrame?): nil - function SetKeyDown(self, key: string): nil - function SetKeyUp(self, key: string): nil - function StartRecording(self): nil -- smh + function Button1Down(self, position: Vector2, camera: CFrame?): () + function Button1Up(self, position: Vector2, camera: CFrame?): () + function Button2Down(self, position: Vector2, camera: CFrame?): () + function Button2Up(self, position: Vector2, camera: CFrame?): () + function CaptureController(self): () + function ClickButton1(self, position: Vector2, camera: CFrame?): () + function ClickButton2(self, position: Vector2, camera: CFrame?): () + function MoveMouse(self, position: Vector2, camera: CFrame?): () + function SetKeyDown(self, key: string): () + function SetKeyUp(self, key: string): () + function StartRecording(self): () function StopRecording(self): string - function TypeKey(self, key: string): nil + function TypeKey(self, key: string): () end declare class Visit extends Instance - function GetUploadUrl(self): string -- are we almost finished here? I can't tell anymore - function SetPing(self, pingUrl: string, interval: number): nil - function SetUploadUrl(self, url: string): nil + function SetPing(self, pingUrl: string, interval: number): () + function SetUploadUrl(self, url: string): () end declare Instance: { - new: ((className: "Accoutrement", parent: Instance?) -> Accoutrement) - & ((className: "Hat", parent: Instance?) -> Hat) - & ((className: "AdvancedDragger", parent: Instance?) -> AdvancedDragger) - & ((className: "Animation", parent: Instance?) -> Animation) - & ((className: "CurveAnimation", parent: Instance?) -> CurveAnimation) - & ((className: "KeyframeSequence", parent: Instance?) -> KeyframeSequence) - & ((className: "AnimationController", parent: Instance?) -> AnimationController) - & ((className: "Animator", parent: Instance?) -> Animator) - & ((className: "Backpack", parent: Instance?) -> Backpack) - & ((className: "BindableEvent", parent: Instance?) -> BindableEvent) - & ((className: "BindableFunction", parent: Instance?) -> BindableFunction) - & ((className: "BodyAngularVelocity", parent: Instance?) -> BodyAngularVelocity) - & ((className: "BodyForce", parent: Instance?) -> BodyForce) - & ((className: "BodyGyro", parent: Instance?) -> BodyGyro) - & ((className: "BodyPosition", parent: Instance?) -> BodyPosition) - & ((className: "BodyThrust", parent: Instance?) -> BodyThrust) - & ((className: "BodyVelocity", parent: Instance?) -> BodyVelocity) - & ((className: "RocketPropulsion", parent: Instance?) -> RocketPropulsion) - & ((className: "Camera", parent: Instance?) -> Camera) - & ((className: "BodyColors", parent: Instance?) -> BodyColors) - & ((className: "CharacterMesh", parent: Instance?) -> CharacterMesh) - & ((className: "Pants", parent: Instance?) -> Pants) - & ((className: "Shirt", parent: Instance?) -> Shirt) - & ((className: "ShirtGraphic", parent: Instance?) -> ShirtGraphic) - & ((className: "Skin", parent: Instance?) -> Skin) - & ((className: "ClickDetector", parent: Instance?) -> ClickDetector) - & ((className: "DragDetector", parent: Instance?) -> DragDetector) - & ((className: "Configuration", parent: Instance?) -> Configuration) - & ((className: "HumanoidController", parent: Instance?) -> HumanoidController) - & ((className: "SkateboardController", parent: Instance?) -> SkateboardController) - & ((className: "VehicleController", parent: Instance?) -> VehicleController) - & ((className: "CustomEvent", parent: Instance?) -> CustomEvent) - & ((className: "CustomEventReceiver", parent: Instance?) -> CustomEventReceiver) - & ((className: "CylinderMesh", parent: Instance?) -> CylinderMesh) - & ((className: "FileMesh", parent: Instance?) -> FileMesh) - & ((className: "SpecialMesh", parent: Instance?) -> SpecialMesh) - & ((className: "DataStoreOptions", parent: Instance?) -> DataStoreOptions) - & ((className: "DebuggerWatch", parent: Instance?) -> DebuggerWatch) - & ((className: "Dialog", parent: Instance?) -> Dialog) - & ((className: "DialogChoice", parent: Instance?) -> DialogChoice) - & ((className: "Dragger", parent: Instance?) -> Dragger) - & ((className: "Explosion", parent: Instance?) -> Explosion) - & ((className: "Decal", parent: Instance?) -> Decal) - & ((className: "Texture", parent: Instance?) -> Texture) - & ((className: "Hole", parent: Instance?) -> Hole) - & ((className: "MotorFeature", parent: Instance?) -> MotorFeature) - & ((className: "Fire", parent: Instance?) -> Fire) - & ((className: "ForceField", parent: Instance?) -> ForceField) - & ((className: "FunctionalTest", parent: Instance?) -> FunctionalTest) - & ((className: "Frame", parent: Instance?) -> Frame) - & ((className: "ImageButton", parent: Instance?) -> ImageButton) - & ((className: "TextButton", parent: Instance?) -> TextButton) - & ((className: "ImageLabel", parent: Instance?) -> ImageLabel) - & ((className: "TextLabel", parent: Instance?) -> TextLabel) - & ((className: "TextBox", parent: Instance?) -> TextBox) - & ((className: "BillboardGui", parent: Instance?) -> BillboardGui) - & ((className: "ScreenGui", parent: Instance?) -> ScreenGui) - & ((className: "GuiMain", parent: Instance?) -> GuiMain) - & ((className: "SurfaceGui", parent: Instance?) -> SurfaceGui) - & ((className: "FloorWire", parent: Instance?) -> FloorWire) - & ((className: "SelectionBox", parent: Instance?) -> SelectionBox) - & ((className: "ArcHandles", parent: Instance?) -> ArcHandles) - & ((className: "Handles", parent: Instance?) -> Handles) - & ((className: "SurfaceSelection", parent: Instance?) -> SurfaceSelection) - & ((className: "SelectionPartLasso", parent: Instance?) -> SelectionPartLasso) - & ((className: "SelectionPointLasso", parent: Instance?) -> SelectionPointLasso) - & ((className: "Humanoid", parent: Instance?) -> Humanoid) - & ((className: "RotateP", parent: Instance?) -> RotateP) - & ((className: "RotateV", parent: Instance?) -> RotateV) - & ((className: "Glue", parent: Instance?) -> Glue) - & ((className: "ManualGlue", parent: Instance?) -> ManualGlue) - & ((className: "ManualWeld", parent: Instance?) -> ManualWeld) - & ((className: "Motor", parent: Instance?) -> Motor) - & ((className: "Motor6D", parent: Instance?) -> Motor6D) - & ((className: "Rotate", parent: Instance?) -> Rotate) - & ((className: "Snap", parent: Instance?) -> Snap) - & ((className: "VelocityMotor", parent: Instance?) -> VelocityMotor) - & ((className: "Weld", parent: Instance?) -> Weld) - & ((className: "Keyframe", parent: Instance?) -> Keyframe) - & ((className: "PointLight", parent: Instance?) -> PointLight) - & ((className: "SpotLight", parent: Instance?) -> SpotLight) - & ((className: "SurfaceLight", parent: Instance?) -> SurfaceLight) - & ((className: "Script", parent: Instance?) -> Script) - & ((className: "LocalScript", parent: Instance?) -> LocalScript) - & ((className: "ModuleScript", parent: Instance?) -> ModuleScript) - & ((className: "Message", parent: Instance?) -> Message) - & ((className: "Hint", parent: Instance?) -> Hint) - & ((className: "CornerWedgePart", parent: Instance?) -> CornerWedgePart) - & ((className: "Part", parent: Instance?) -> Part) - & ((className: "FlagStand", parent: Instance?) -> FlagStand) - & ((className: "Seat", parent: Instance?) -> Seat) - & ((className: "SkateboardPlatform", parent: Instance?) -> SkateboardPlatform) - & ((className: "SpawnLocation", parent: Instance?) -> SpawnLocation) - & ((className: "WedgePart", parent: Instance?) -> WedgePart) - & ((className: "IntersectOperation", parent: Instance?) -> IntersectOperation) - & ((className: "TrussPart", parent: Instance?) -> TrussPart) - & ((className: "VehicleSeat", parent: Instance?) -> VehicleSeat) - & ((className: "Model", parent: Instance?) -> Model) - & ((className: "HopperBin", parent: Instance?) -> HopperBin) - & ((className: "Tool", parent: Instance?) -> Tool) - & ((className: "Flag", parent: Instance?) -> Flag) - & ((className: "Player", parent: Instance?) -> Player) - & ((className: "Pose", parent: Instance?) -> Pose) - & ((className: "ReflectionMetadata", parent: Instance?) -> ReflectionMetadata) - & ((className: "ReflectionMetadataCallbacks", parent: Instance?) -> ReflectionMetadataCallbacks) - & ((className: "ReflectionMetadataClasses", parent: Instance?) -> ReflectionMetadataClasses) - & ((className: "ReflectionMetadataEvents", parent: Instance?) -> ReflectionMetadataEvents) - & ((className: "ReflectionMetadataFunctions", parent: Instance?) -> ReflectionMetadataFunctions) - & ((className: "ReflectionMetadataClass", parent: Instance?) -> ReflectionMetadataClass) - & ((className: "ReflectionMetadataMember", parent: Instance?) -> ReflectionMetadataMember) - & ((className: "ReflectionMetadataProperties", parent: Instance?) -> ReflectionMetadataProperties) - & ((className: "ReflectionMetadataYieldFunctions", parent: Instance?) -> ReflectionMetadataYieldFunctions) - & ((className: "RemoteEvent", parent: Instance?) -> RemoteEvent) - & ((className: "RemoteFunction", parent: Instance?) -> RemoteFunction) - & ((className: "Sky", parent: Instance?) -> Sky) - & ((className: "Smoke", parent: Instance?) -> Smoke) - & ((className: "Sound", parent: Instance?) -> Sound) - & ((className: "Sparkles", parent: Instance?) -> Sparkles) - & ((className: "StarterGear", parent: Instance?) -> StarterGear) - & ((className: "Team", parent: Instance?) -> Team) - & ((className: "TerrainRegion", parent: Instance?) -> TerrainRegion) - & ((className: "TestService", parent: Instance?) -> TestService) - & ((className: "BinaryStringValue", parent: Instance?) -> BinaryStringValue) - & ((className: "BoolValue", parent: Instance?) -> BoolValue) - & ((className: "BrickColorValue", parent: Instance?) -> BrickColorValue) - & ((className: "CFrameValue", parent: Instance?) -> CFrameValue) - & ((className: "Color3Value", parent: Instance?) -> Color3Value) - & ((className: "DoubleConstrainedValue", parent: Instance?) -> DoubleConstrainedValue) - & ((className: "IntConstrainedValue", parent: Instance?) -> IntConstrainedValue) - & ((className: "IntValue", parent: Instance?) -> IntValue) - & ((className: "NumberValue", parent: Instance?) -> NumberValue) - & ((className: "ObjectValue", parent: Instance?) -> ObjectValue) - & ((className: "RayValue", parent: Instance?) -> RayValue) - & ((className: "StringValue", parent: Instance?) -> StringValue) - & ((className: "Vector3Value", parent: Instance?) -> Vector3Value) - & ((className: string, parent: Instance?) -> Instance), - - Lock: (instance: Instance, player: Player) -> nil, - Unlock: (instance: Instance) -> nil, + new: ((className: string) -> Instance), + Lock: ((instance: Instance, instance2: Instance?) -> boolean), + Unlock: ((instance: Instance) -> ()), } declare Ray: { @@ -4020,27 +3460,22 @@ declare BrickColor: { Gray: (() -> BrickColor), DarkGray: (() -> BrickColor), White: (() -> BrickColor), - Random: (() -> BrickColor), -- no clue which of these is deprecated - random: (() -> BrickColor), -- anyone know what that "unknown" song from the Finobe OST is? not in the bandcamp release, not in the youtube playlist, not in the now-nonexistent youtube deluxe edition, not in the soundcloud with the original album art, the one from 01:01 to 2:32 in the "[Tutorial] How to properly host a server on Finobe!" video by Shenzou - Green: (() -> BrickColor), -- that shit is lost media to me + random: (() -> BrickColor), + Green: (() -> BrickColor), Black: (() -> BrickColor), - palette: ((paletteValue: number --[[0-63]]) -> BrickColor), -- I just looked in my downloads folder to find it and realised I have an abnormal number of Alonso drawings there, turns out it's in my other more different downloads folder at /Libraries/what/Documents/Downloads + palette: ((paletteValue: number) -> BrickColor), new: ((val: number) -> BrickColor) & ((r: number, g: number, b: number) -> BrickColor) & ((color: Color3) -> BrickColor) & ((name: "Alder" | "Artichoke" | "Baby blue" | "Beige" | "Black" | "Black metallic" | "Br. reddish orange" | "Br. yellowish green" | "Br. yellowish orange" | "Brick yellow" | "Bright blue" | "Bright bluish green" | "Bright bluish violet" | "Bright green" | "Bright orange" | "Bright purple" | "Bright red" | "Bright reddish lilac" | "Bright reddish violet" | "Bright violet" | "Bright yellow" | "Bronze" | "Brown" | "Burgundy" | "Burlap" | "Burnt Sienna" | "Buttermilk" | "CGA brown" | "Cadet blue" | "Camo" | "Carnation pink" | "Cashmere" | "Cloudy grey" | "Cocoa" | "Cool yellow" | "Copper" | "Cork" | "Crimson" | "Curry" | "Cyan" | "Daisy orange" | "Dark Curry" | "Dark Royal blue" | "Dark blue" | "Dark green" | "Dark grey" | "Dark grey metallic" | "Dark indigo" | "Dark nougat" | "Dark orange" | "Dark red" | "Dark stone grey" | "Dark taupe" | "Deep blue" | "Deep orange" | "Dirt brown" | "Dove blue" | "Dusty Rose" | "Earth blue" | "Earth green" | "Earth orange" | "Earth yellow" | "Eggplant" | "Electric blue" | "Faded green" | "Fawn brown" | "Fire Yellow" | "Flame reddish orange" | "Flame yellowish orange" | "Flint" | "Fog" | "Forest green" | "Fossil" | "Ghost grey" | "Gold" | "Grey" | "Grime" | "Gun metallic" | "Hot pink" | "Hurricane grey" | "Institutional white" | "Khaki" | "Lapis" | "Laurel green" | "Lavender" | "Lemon metalic" | "Lig. Yellowich orange" | "Lig. yellowish green" | "Light Royal blue" | "Light blue" | "Light bluish green" | "Light bluish violet" | "Light brick yellow" | "Light green (Mint)" | "Light grey" | "Light grey metallic" | "Light lilac" | "Light orange" | "Light orange brown" | "Light pink" | "Light purple" | "Light red" | "Light reddish violet" | "Light stone grey" | "Light yellow" | "Lilac" | "Lily white" | "Lime green" | "Linen" | "Magenta" | "Maroon" | "Mauve" | "Med. bluish green" | "Med. reddish violet" | "Med. yellowish green" | "Med. yellowish orange" | "Medium Royal blue" | "Medium blue" | "Medium bluish violet" | "Medium green" | "Medium lilac" | "Medium orange" | "Medium red" | "Medium stone grey" | "Mid gray" | "Mint" | "Moss" | "Mulberry" | "Navy blue" | "Neon green" | "Neon orange" | "New Yeller" | "Nougat" | "Olive" | "Olivine" | "Oyster" | "Parsley green" | "Pastel Blue" | "Pastel blue-green" | "Pastel brown" | "Pastel green" | "Pastel light blue" | "Pastel orange" | "Pastel violet" | "Pastel yellow" | "Pearl" | "Persimmon" | "Phosph. White" | "Pine Cone" | "Pink" | "Plum" | "Quill grey" | "Really black" | "Really blue" | "Really red" | "Red flip/flop" | "Reddish brown" | "Reddish lilac" | "Royal blue" | "Royal purple" | "Rust" | "Sage green" | "Salmon" | "Sand blue" | "Sand blue metallic" | "Sand green" | "Sand red" | "Sand violet" | "Sand violet metallic" | "Sand yellow" | "Sand yellow metallic" | "Sea green" | "Seashell" | "Shamrock" | "Silver" | "Silver flip/flop" | "Slime green" | "Smoky grey" | "Steel blue" | "Storm blue" | "Sunrise" | "Tawny" | "Teal" | "Terra Cotta" | "Toothpaste" | "Tr. Blue" | "Tr. Bright bluish violet" | "Tr. Brown" | "Tr. Flu. Blue" | "Tr. Flu. Green" | "Tr. Flu. Red" | "Tr. Flu. Reddish orange" | "Tr. Flu. Yellow" | "Tr. Green" | "Tr. Lg blue" | "Tr. Medi. reddish violet" | "Tr. Red" | "Tr. Yellow" | "Transparent" | "Turquoise" | "Warm yellowish orange" | "Wheat" | "White" | "Yellow flip/flop") -> BrickColor), } declare Vector2: { - zero: Vector2, -- is this the identity thing? I can see the sun rising outside, It's nearing 6am, we're gonna be alright - one: Vector2, - xAxis: Vector2, - yAxis: Vector2, new: ((x: number?, y: number?) -> Vector2), } declare Vector2int16: { - new: ((x: number, y: number) -> Vector2int16), -- if you wanna know how this feels, just keep replaying Finobe OST - Battlefields (but only the part from 1:45 onwards) + new: ((x: number?, y: number?) -> Vector2int16), } -declare Color3: { -- i'll play some Shop Demo now because that's goes hard +declare Color3: { new: ((red: number?, green: number?, blue: number?) -> Color3), } @@ -4061,14 +3496,12 @@ declare Region3int16: { } declare UDim2: { - fromScale: ((xScale: number, yScale: number) -> UDim2), - fromOffset: ((xOffset: number, yOffset: number) -> UDim2), -- can't even tell what's on one line and what's line wrapped anymore new: ((x: UDim, y: UDim) -> UDim2) & ((xScale: number?, xOffset: number?, yScale: number?, yOffset: number?) -> UDim2), } declare CFrame: { Angles: ((rx: number, ry: number, rz: number) -> CFrame), - fromOrientation: ((rx: number, ry: number, rz: number) -> CFrame), + fromAxisAngle: ((v: Vector3, r: number) -> CFrame), fromEulerAnglesXYZ: ((rx: number, ry: number, rz: number) -> CFrame), new: (() -> CFrame) & ((pos: Vector3) -> CFrame) & ((pos: Vector3, lookAt: Vector3) -> CFrame) & ((x: number, y: number, z: number) -> CFrame) & ((x: number, y: number, z: number, qX: number, qY: number, qZ: number, qW: number) -> CFrame) & ((x: number, y: number, z: number, R00: number, R01: number, R02: number, R10: number, R11: number, R12: number, R20: number, R21: number, R22: number) -> CFrame), } @@ -4077,12 +3510,8 @@ declare Faces: { new: ((normalIds: any) -> Faces), } -declare Rect: { - new: ((min: Vector2, max: Vector2) -> Rect) & ((minX: number, minY: number, maxX: number, maxY: number) -> Rect), -} - declare Vector3: { - FromNormalId: ((normal: EnumNormalId) -> Vector3), -- uncapitalised names do Not exist here, wow + FromNormalId: ((normal: EnumNormalId) -> Vector3), FromAxis: ((axis: EnumAxis) -> Vector3), new: ((x: number?, y: number?, z: number?) -> Vector3), } @@ -4091,12 +3520,40 @@ declare Vector3int16: { new: ((x: number?, y: number?, z: number?) -> Vector3int16), } + +type Studio = any -- This class is a mess +-- It doesn't exist in the API dump since it must have been redefined in 349 (2018/08/07) (which should never happen) +-- Since Mercury uses several FFlags, the types defined under it use nonexistent enums as well + declare class GlobalSettings extends GenericSettings + Lua: LuaSettings + ["Game Options"]: GameSettings + ["Task Scheduler"]: TaskScheduler + Studio: Studio + Network: NetworkSettings + Physics: PhysicsSettings + Rendering: RenderSettings + Diagnostics: DebugSettings function GetFFlag(self, name: string): boolean function GetFVariable(self, name: string): string function GetFVariables(self, name: string): { [any]: any } -- of course I can't test this, because "An error occured" end +declare class ThumbnailGenerator extends Instance -- Tap in rcc before carrot gets it + function Click(self, format: "PNG" | "OBJ", x: number, y: number, hideSky: boolean, crop: boolean?): string +end -- "Stop looking back, what God has for you, you have not seen before and it's not back there!! #NewCreature #GetOutofYourOwnWay #RCCService" - Josh Brown @JoshLB, sometime in 2016 + +declare game: DataModel +declare workspace: Workspace +declare plugin: Plugin +declare script: BaseScript +declare function loadfile(file: string): any +declare function dofile(file: string): any +declare function settings(): GlobalSettings +declare function UserSettings(): UserSettings +declare function PluginManager(): PluginManager +declare function ypcall(f: (() -> any) | (() -> ()) | ((...any) -> (), (...any) -> ()) -> (), ...: any): (boolean, any) + declare _PLACE_ID: number declare _IS_STUDIO_JOIN: string declare _SERVER_ADDRESS: any @@ -4105,8 +3562,6 @@ declare _CREATOR_ID: number declare _USER_ID: number declare _USER_NAME: any declare _MEMBERSHIP_TYPE: any -declare _CHAR_APPEARANCE: string -declare _PING_URL: string declare _BASE_URL: string declare _THUMBNAIL_KEY: string @@ -4121,17 +3576,9 @@ declare _SERVER_PRESENCE_URL: string declare _SERVER: boolean declare _CLIENT: boolean -declare game: DataModel --- declare Game: DataModel -- removing this because I don't like it -declare workspace: Workspace --- declare Workspace: Workspace -- same with this, just feeling mean today -declare plugin: Plugin -declare script: BaseScript -declare function loadfile(file: string): any -declare function dofile(file: string): any +-- library types -- fusion - -- pubtypes --[[ @@ -4156,7 +3603,6 @@ type Animatable = | CFrame | Color3 | Ray - | Rect | Region3 | Region3int16 | UDim @@ -4288,6 +3734,16 @@ type Children = Instance | StateObject | { [any]: Children } -- A table that defines an instance's properties, handlers and children. type PropertyTable = { [string | SpecialKey]: any } +-- lel +export type FakeTweenInfo = { + Time: number, + EasingStyle: EnumEasingStyle | string, + EasingDirection: EnumEasingDirection | string, + RepeatCount: number, + Reverses: boolean, + DelayTime: number, +} + -- init export type Fusion = { @@ -4325,7 +3781,7 @@ export type Fusion = { ) -> ForValues, Observer: (watchedState: StateObject) -> Observer, - Tween: (goalState: StateObject, tweenInfo: TweenInfo?) -> Tween, + Tween: (goalState: StateObject, tweenInfo: FakeTweenInfo?) -> Tween, -- fix dis sometime Spring: ( goalState: StateObject, speed: CanBeState?, @@ -4419,24 +3875,12 @@ export type Red = { } -- just plain useful - export type InstanceName = "Accoutrement" | "Hat" - | "AdvancedDragger" | "Animation" - | "CurveAnimation" - | "KeyframeSequence" | "AnimationController" | "Animator" - | "AudioDistortion" - | "AudioFader" - | "AudioFlanger" - | "AudioListener" - | "AudioPitchShifter" - | "AudioPlayer" - | "AudioReverb" - | "AudioSearchParams" | "Backpack" | "BindableEvent" | "BindableFunction" @@ -4455,7 +3899,6 @@ export type InstanceName = | "ShirtGraphic" | "Skin" | "ClickDetector" - | "DragDetector" | "Configuration" | "HumanoidController" | "SkateboardController" @@ -4465,7 +3908,6 @@ export type InstanceName = | "CylinderMesh" | "FileMesh" | "SpecialMesh" - | "DataStoreOptions" | "DebuggerWatch" | "Dialog" | "DialogChoice" @@ -4550,7 +3992,6 @@ export type InstanceName = | "Team" | "TerrainRegion" | "TestService" - | "BinaryStringValue" | "BoolValue" | "BrickColorValue" | "CFrameValue" @@ -4565,8 +4006,3 @@ export type InstanceName = | "Vector3Value" declare LoadLibrary: ((libraryName: "RbxFusion") -> Fusion) & ((libraryName: "RbxRed") -> Red) & ((libraryName: string) -> any) - -declare function settings(): GlobalSettings -declare function UserSettings(): UserSettings -declare function PluginManager(): PluginManager -declare function ypcall(f: (() -> any) | (() -> ()) | ((...any) -> (), (...any) -> ()) -> (), ...: any): (boolean, any) diff --git a/luau/39250920.luau b/luau/39250920.luau index 20cbabc..108b693 100644 --- a/luau/39250920.luau +++ b/luau/39250920.luau @@ -6,6 +6,8 @@ local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate +local CoreGui = game:GetService "CoreGui" +local Chat = game:GetService "Chat" local InsertService = game:GetService "InsertService" local RunService = game:GetService "RunService" @@ -42,14 +44,13 @@ local player, chatNotificationGui, messageDialog, timeoutScript, reenableDialogS local dialogMap = {} local dialogConnections = {} -local gui waitForChild(game, "CoreGui") -waitForChild(game.CoreGui, "RobloxGui") -if game.CoreGui.RobloxGui:FindFirstChild "ControlFrame" then - gui = game.CoreGui.RobloxGui.ControlFrame -else - gui = game.CoreGui.RobloxGui -end +waitForChild(CoreGui, "RobloxGui") + +local MercuryGui = CoreGui:FindFirstChild "RobloxGui" :: ScreenGui & { + ControlFrame: Frame, +} +local gui = MercuryGui:FindFirstChild "ControlFrame" or MercuryGui local function currentTone() if currentConversationDialog then @@ -333,7 +334,7 @@ local function selectChoice(choice) --First hide the Gui mainFrame.Visible = false if choice == lastChoice then - game.Chat:Chat( + Chat:Chat( localPlayer.Character, "Goodbye!", getChatColor(currentTone()) @@ -343,7 +344,7 @@ local function selectChoice(choice) else local dialogChoice = choiceMap[choice] - game.Chat:Chat( + Chat:Chat( localPlayer.Character, sanitiseMessage(dialogChoice.UserDialog), getChatColor(currentTone()) @@ -353,7 +354,7 @@ local function selectChoice(choice) player, dialogChoice ) - game.Chat:Chat( + Chat:Chat( currentConversationPartner, sanitiseMessage(dialogChoice.ResponseDialog), getChatColor(currentTone()) @@ -447,8 +448,8 @@ local function initialize(parent) lastChoice.Parent = mainFrame end -local function doDialog(dialog) - local il = Instance.Lock(dialog, player) +local function doDialog(dialog: Dialog) + local il = Instance.Lock(dialog, player) -- does this even do anything in 2013 print("for instance", il) while not il do RunService.Heartbeat:wait() @@ -467,7 +468,7 @@ local function doDialog(dialog) Instance.Unlock(dialog) currentConversationDialog = dialog - game.Chat:Chat( + Chat:Chat( dialog.Parent, dialog.InitialPrompt, getChatColor(dialog.Tone) @@ -534,7 +535,7 @@ local function addDialog(dialog: Dialog) Enabled = not dialog.InUse, Adornee = dialog.Parent, RobloxLocked = true, - Parent = game.CoreGui, + Parent = CoreGui, } chatGui.Image.Button.MouseButton1Click:connect(function() startDialog(dialog) diff --git a/luau/45284430.luau b/luau/45284430.luau index 9d69132..eaefeb9 100644 --- a/luau/45284430.luau +++ b/luau/45284430.luau @@ -2,14 +2,16 @@ -- RbxGui print "[Mercury]: Loaded corescript 45284430" -local News = require "../Modules/New" -local New = News.New -local Hydrate = News.Hydrate - local ContentProvider = game:GetService "ContentProvider" local InsertService = game:GetService "InsertService" local RunService = game:GetService "RunService" +local News = require "../Modules/New" +local New = News.New +local Hydrate = News.Hydrate +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path + local RbxGui = {} local function ScopedConnect( @@ -230,13 +232,13 @@ function RbxGui.CreateStyledMessageDialog(title, message, style, buttons) if style == "error" or style == "Error" then styleImage.Size = UDim2.new(0, 71, 0, 71) - styleImage.Image = "http://banland.xyz/asset?id=42565285" + styleImage.Image = path "asset?id=42565285" elseif style == "notify" or style == "Notify" then styleImage.Size = UDim2.new(0, 71, 0, 71) - styleImage.Image = "http://banland.xyz/asset?id=42604978" + styleImage.Image = path "asset?id=42604978" elseif style == "confirm" or style == "Confirm" then styleImage.Size = UDim2.new(0, 74, 0, 76) - styleImage.Image = "http://banland.xyz/asset?id=42557901" + styleImage.Image = path "asset?id=42557901" else return RbxGui.CreateMessageDialog(title, message, buttons) end @@ -280,7 +282,7 @@ function RbxGui.CreateDropDownMenu( New "ImageLabel" { Name = "Icon", Active = false, - Image = "http://banland.xyz/asset?id=45732894", + Image = path "asset?id=45732894", BackgroundTransparency = 1, Size = UDim2.new(0, 11, 0, 6), Position = UDim2.new(1, -11, 0.5, -2), @@ -944,8 +946,8 @@ function RbxGui.CreateSlider(steps: number, width: number, position) end function RbxGui.CreateTrueScrollingFrame() - local lowY - local highY + local lowY: number? + local highY: number? local dragCon: RBXScriptConnection? local upCon: RBXScriptConnection? @@ -1575,7 +1577,7 @@ function RbxGui.CreateScrollingFrame(orderList: { GuiObject }?, scrollStyle) local scrollStamp = 0 local scrollDrag = New "ImageButton" { - Image = "http://banland.xyz/asset?id=61367186", + Image = path "asset?id=61367186", Size = UDim2.new(1, 0, 0, 16), BackgroundTransparency = 1, Name = "ScrollDrag", @@ -3014,7 +3016,7 @@ function RbxGui.CreateSetPanel( New "ImageLabel" { Name = "CancelImage", BackgroundTransparency = 1, - Image = "http://banland.xyz/asset?id=54135717", + Image = path "asset?id=54135717", Position = UDim2.new(0, -2, 0, -2), Size = UDim2.new(0, 16, 0, 16), ZIndex = 6, @@ -3254,7 +3256,7 @@ function RbxGui.CreateSetPanel( local function createDropDownMenuButton(parent: Frame) local dropDownButton = New "ImageButton" { Name = "DropDownButton", - Image = "http://banland.xyz/asset?id=67581509", + Image = path "asset?id=67581509", BackgroundTransparency = 1, Size = UDim2.new(0, 16, 0, 16), Position = UDim2.new(1, -24, 0, 6), @@ -3767,8 +3769,9 @@ function RbxGui.CreateTerrainMaterialSelector(size, position) toAdd = 66887593 end - materialToImageMap[v] = - { Regular = `http://banland.xyz/asset?id={toAdd}` } + materialToImageMap[v] = { + Regular = path "asset?id=" .. toAdd, + } end local scrollFrame, scrollUp, scrollDown, recalculateScroll = @@ -3879,7 +3882,7 @@ function RbxGui.CreateTerrainMaterialSelector(size, position) end function RbxGui.CreateLoadingFrame(name, size, position) - ContentProvider:Preload "http://banland.xyz/asset?id=35238053" + ContentProvider:Preload(path "asset?id=35238053") local loadingFrame = New "Frame" { Name = "LoadingFrame", @@ -3911,7 +3914,7 @@ function RbxGui.CreateLoadingFrame(name, size, position) local loadingGreenBar = New "ImageLabel" { Name = "LoadingGreenBar", - Image = "http://banland.xyz/asset?id=35238053", + Image = path "asset?id=35238053", Position = UDim2.new(0, 0, 0, 0), Size = UDim2.new(0, 0, 1, 0), Visible = false, diff --git a/luau/46295863.luau b/luau/46295863.luau index fd46b61..e99857e 100644 --- a/luau/46295863.luau +++ b/luau/46295863.luau @@ -2,20 +2,20 @@ -- CoreGui.RobloxGui.CoreScripts/Settings print "[Mercury]: Loaded corescript 46295863" +local GuiService = game:GetService "GuiService" +local Players = game:GetService "Players" + local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate - -local CoreGui = game:GetService "CoreGui" -local GuiService = game:GetService "GuiService" -local Players = game:GetService "Players" +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path local function waitForChild(instance, name) while not instance:FindFirstChild(name) do instance.ChildAdded:wait() end end - local function waitForProperty(instance, property) while not instance[property] do instance.Changed:wait() @@ -23,16 +23,16 @@ local function waitForProperty(instance, property) end -- A Few Script Globals -local mercuryGui = script.Parent :: ScreenGui & { ControlFrame: Frame } -local gui = mercuryGui:FindFirstChild "ControlFrame" and mercuryGui.ControlFrame - or mercuryGui +local MercuryGui = script.Parent :: ScreenGui & { ControlFrame: Frame } +local gui = MercuryGui:FindFirstChild "ControlFrame" and MercuryGui.ControlFrame + or MercuryGui local RbxGui local helpButton, updateCameraDropDownSelection, updateVideoCaptureDropDownSelection local tweenTime = 0.2 -local mouseLockLookScreenUrl = "http://banland.xyz/asset?id=54071825" -local classicLookScreenUrl = "http://banland.xyz/asset?id=45915798" +local mouseLockLookScreenUrl = path "asset?id=54071825" +local classicLookScreenUrl = path "asset?id=45915798" local hasGraphicsSlider = true local GraphicsQualityLevels = 10 -- how many levels we allow on graphics slider @@ -51,7 +51,7 @@ local inStudioMode = UserSettings().GameSettings:InStudioMode() local macClient = false local ok, isMac = pcall(function() - return not game.GuiService.IsWindows + return not GuiService.IsWindows end) macClient = ok and isMac @@ -83,9 +83,9 @@ local function resumeGameFunction(shield) shield.Visible = false for i = 1, #centerDialogs do centerDialogs[i].Visible = false - game.GuiService:RemoveCenterDialog(centerDialogs[i]) + GuiService:RemoveCenterDialog(centerDialogs[i]) end - game.GuiService:RemoveCenterDialog(shield) + GuiService:RemoveCenterDialog(shield) settingsButton.Active = true currentMenuSelection = nil lastMenuSelection = {} @@ -182,7 +182,7 @@ local function goToMenu(container, menuName, moveDirection, size, position) end local function resetLocalCharacter() - local player = game.Players.LocalPlayer + local player = Players.LocalPlayer if player and player.Character then local humanoid = (player.Character:FindFirstChild "Humanoid") :: Humanoid if humanoid then @@ -298,11 +298,11 @@ local function backToGame(buttonClicked, shield, settingsButton2) buttonClicked.Parent.Parent.Parent.Parent.Visible = false shield.Visible = false for i = 1, #centerDialogs do - game.GuiService:RemoveCenterDialog(centerDialogs[i]) + GuiService:RemoveCenterDialog(centerDialogs[i]) centerDialogs[i].Visible = false end centerDialogs = {} - game.GuiService:RemoveCenterDialog(shield) + GuiService:RemoveCenterDialog(shield) settingsButton2.Active = true end @@ -417,19 +417,19 @@ local function createHelpDialog(baseZIndex) { Text = "Move", Function = function() - image.Image = "http://banland.xyz/asset?id=45915811" + image.Image = path "asset?id=45915811" end, }, { Text = "Gear", Function = function() - image.Image = "http://banland.xyz/asset?id=45917596" + image.Image = path "asset?id=45917596" end, }, { Text = "Zoom", Function = function() - image.Image = "http://banland.xyz/asset?id=45915825" + image.Image = path "asset?id=45915825" end, }, }, UDim.new(0, 0), UDim.new(1, 0)) @@ -481,7 +481,7 @@ local function createHelpDialog(baseZIndex) Parent = helpDialog, }).MouseButton1Click:connect(function() shield.Visible = false - game.GuiService:RemoveCenterDialog(shield) + GuiService:RemoveCenterDialog(shield) end) robloxLock(shield) @@ -695,7 +695,7 @@ local function createGameMainMenu(baseZIndex, shield) helpButton.MouseButton1Click:connect(function() table.insert(centerDialogs, helpDialog) - game.GuiService:AddCenterDialog( + GuiService:AddCenterDialog( helpDialog, Enum.CenterDialogType.ModalDialog, --ShowFunction @@ -843,9 +843,9 @@ local function createGameMainMenu(baseZIndex, shield) gameSettingsButton.ZIndex = baseZIndex + 4 gameSettingsButton.Parent = gameMainMenuFrame gameSettingsButton.MouseButton1Click:connect(function() - if game:FindFirstChild "Players" and game.Players.LocalPlayer then + if game:FindFirstChild "Players" and Players.LocalPlayer then local loadingGui = - game.Players.LocalPlayer:FindFirstChild "PlayerLoadingGui" + Players.LocalPlayer:FindFirstChild "PlayerLoadingGui" if loadingGui then loadingGui.Visible = true end @@ -872,7 +872,7 @@ end local mouseLockLabel, syncVideoCaptureSetting -local function createGameSettingsMenu(baseZIndex, _) +local function createGameSettingsMenu(baseZIndex: number) local function fullscreenShortcut() return New "TextLabel" { BackgroundTransparency = 1, @@ -1022,7 +1022,7 @@ local function createGameSettingsMenu(baseZIndex, _) Parent = gameSettingsMenuFrame, } - local graphicsSlider, graphicsLevel = RbxGui.CreateSlider( + local graphicsSlider, graphicsLevel: NumberValue = RbxGui.CreateSlider( GraphicsQualityLevels, 150, UDim2.new(0, 230, 0, 280) @@ -1098,7 +1098,7 @@ local function createGameSettingsMenu(baseZIndex, _) settings().Rendering.QualityLevel = Enum.QualityLevel.Automatic end - local function setGraphicsQualityLevel(newLevel) + local function setGraphicsQualityLevel(newLevel: number) local percentage = newLevel / GraphicsQualityLevels local newSetting = math.floor( (settings().Rendering:GetMaxQualityLevel() - 1) * percentage @@ -1115,19 +1115,16 @@ local function createGameSettingsMenu(baseZIndex, _) settings().Rendering.QualityLevel = newSetting end - local function goToManualGraphics(explicitLevel) + local function goToManualGraphics(explicitLevel: number?) setAutoGraphicsGui(false) - if explicitLevel then - graphicsLevel.Value = explicitLevel - else - graphicsLevel.Value = math.floor( + graphicsLevel.Value = explicitLevel + or math.floor( ( settings().Rendering.AutoFRMLevel / (settings().Rendering:GetMaxQualityLevel() - 1) ) * GraphicsQualityLevels ) - end if explicitLevel == graphicsLevel.Value then -- make sure we are actually in right graphics mode setGraphicsQualityLevel(graphicsLevel.Value) @@ -1279,7 +1276,7 @@ local function createGameSettingsMenu(baseZIndex, _) end autoGraphicsButton.MouseButton1Click:connect(function() - if inStudioMode and not game.Players.LocalPlayer then + if inStudioMode and not Players.LocalPlayer then return elseif not isAutoGraphics then goToAutoGraphics() @@ -1324,13 +1321,13 @@ local function createGameSettingsMenu(baseZIndex, _) end end) - game.Players.PlayerAdded:connect(function(player) - if player == game.Players.LocalPlayer and inStudioMode then + Players.PlayerAdded:connect(function(player) + if player == Players.LocalPlayer and inStudioMode then enableGraphicsWidget() end end) - game.Players.PlayerRemoving:connect(function(player) - if player == game.Players.LocalPlayer and inStudioMode then + Players.PlayerRemoving:connect(function(player) + if player == Players.LocalPlayer and inStudioMode then disableGraphicsWidget() end end) @@ -1354,7 +1351,7 @@ local function createGameSettingsMenu(baseZIndex, _) local wasManualGraphics = ( settings().Rendering.QualityLevel ~= Enum.QualityLevel.Automatic ) - if inStudioMode and not game.Players.LocalPlayer then + if inStudioMode and not Players.LocalPlayer then studioCheckbox.Text = "X" disableGraphicsWidget() elseif inStudioMode then @@ -1510,12 +1507,12 @@ local function createGameSettingsMenu(baseZIndex, _) updateVideoCaptureDropDownSelection(videoNames[1]) elseif UserSettings().GameSettings.VideoUploadPromptBehavior - == Enum.UploadSetting["Ask me first"] + == Enum.UploadSetting.Ask then updateVideoCaptureDropDownSelection(videoNames[2]) else UserSettings().GameSettings.VideoUploadPromptBehavior = - Enum.UploadSetting["Ask me first"] + Enum.UploadSetting.Ask updateVideoCaptureDropDownSelection(videoNames[2]) end end @@ -1535,7 +1532,7 @@ local function createGameSettingsMenu(baseZIndex, _) Parent = gameSettingsMenuFrame, } - mouseLockLabel = CoreGui.RobloxGui:FindFirstChild("MouseLockLabel", true) + mouseLockLabel = MercuryGui:FindFirstChild("MouseLockLabel", true) local enumItems = Enum.ControlMode:GetEnumItems() local enumNames = {} @@ -1662,7 +1659,7 @@ if UserSettings then end) end - CoreGui.RobloxGui.Changed:connect( + MercuryGui.Changed:connect( function(prop) -- We have stopped recording when we resize if prop == "AbsoluteSize" and recordingVideo then recordVideoClick( @@ -1674,24 +1671,24 @@ if UserSettings then ) local function localPlayerChange() - gameMainMenu.ResetButton.Visible = game.Players.LocalPlayer - if game.Players.LocalPlayer then + gameMainMenu.ResetButton.Visible = Players.LocalPlayer + if Players.LocalPlayer then settings().Rendering.EnableFRM = true elseif inStudioMode then settings().Rendering.EnableFRM = false end end - gameMainMenu.ResetButton.Visible = game.Players.LocalPlayer - if game.Players.LocalPlayer ~= nil then - game.Players.LocalPlayer.Changed:connect(function() + gameMainMenu.ResetButton.Visible = Players.LocalPlayer + if Players.LocalPlayer ~= nil then + Players.LocalPlayer.Changed:connect(function() localPlayerChange() end) else delay(0, function() - waitForProperty(game.Players, "LocalPlayer") - gameMainMenu.ResetButton.Visible = game.Players.LocalPlayer - game.Players.LocalPlayer.Changed:connect(function() + waitForProperty(Players, "LocalPlayer") + gameMainMenu.ResetButton.Visible = Players.LocalPlayer + Players.LocalPlayer.Changed:connect(function() localPlayerChange() end) end) @@ -1806,7 +1803,7 @@ if UserSettings then hotkeysConn = GuiService.KeyPressed:connect(leaveResetHotkeys) end) if currentMenuSelection == nil then - game.GuiService:AddCenterDialog( + GuiService:AddCenterDialog( shield, Enum.CenterDialogType.ModalDialog, showFunction, @@ -1815,7 +1812,7 @@ if UserSettings then elseif #lastMenuSelection > 0 then if #centerDialogs > 0 then for i = 1, #centerDialogs do - game.GuiService:RemoveCenterDialog(centerDialogs[i]) + GuiService:RemoveCenterDialog(centerDialogs[i]) centerDialogs[i].Visible = false end centerDialogs = {} @@ -1872,7 +1869,7 @@ if UserSettings then robloxLock(shield) settingsButton.MouseButton1Click:connect(function() - game.GuiService:AddCenterDialog( + GuiService:AddCenterDialog( shield, Enum.CenterDialogType.ModalDialog, --showFunction @@ -2091,7 +2088,7 @@ local function createSaveDialogs() -8 ), BackgroundTransparency = 1, - Image = "http://banland.xyz/asset?id=45880710", + Image = path "asset?id=45880710", Parent = spinnerFrame, } ) @@ -2110,13 +2107,11 @@ local function createSaveDialogs() local pos = 0 while pos < 8 do - if pos == spinPos or pos == ((spinPos + 1) % 8) then - spinnerIcons[pos + 1].Image = - "http://banland.xyz/asset?id=45880668" - else - spinnerIcons[pos + 1].Image = - "http://banland.xyz/asset?id=45880710" - end + spinnerIcons[pos + 1].Image = ( + pos == spinPos or pos == ((spinPos + 1) % 8) + ) + and path "asset?id=45880668" + or path "asset?id=45880710" pos += 1 end @@ -2171,7 +2166,7 @@ local function createSaveDialogs() errorDialogMessageBox.Visible = false spinnerDialog.Visible = false shield.Visible = false - game.GuiService:RemoveCenterDialog(shield) + GuiService:RemoveCenterDialog(shield) end robloxLock(shield) @@ -2184,8 +2179,8 @@ local function createReportAbuseDialog() waitForChild(game, "NetworkClient") waitForChild(game, "Players") - waitForProperty(game.Players, "LocalPlayer") - local localPlayer = game.Players.LocalPlayer + waitForProperty(Players, "LocalPlayer") + local localPlayer = Players.LocalPlayer local reportAbuseButton waitForChild(gui, "UserSettingsShield") @@ -2448,7 +2443,7 @@ local function createReportAbuseDialog() if submitReportButton.Active then if abuse and abusingPlayer then frame.Visible = false - game.Players:ReportAbuse( + Players:ReportAbuse( abusingPlayer, abuse, shortDescriptionBox.Text @@ -2499,7 +2494,7 @@ local function createReportAbuseDialog() normalMessageBox.Visible = false shield.Visible = false reportAbuseButton.Active = true - game.GuiService:RemoveCenterDialog(shield) + GuiService:RemoveCenterDialog(shield) end cancelButton.MouseButton1Click:connect(closeAndResetDialog) @@ -2507,7 +2502,7 @@ local function createReportAbuseDialog() reportAbuseButton.MouseButton1Click:connect(function() createPlayersDropDown().Parent = reportAbuseFrame table.insert(centerDialogs, shield) - game.GuiService:AddCenterDialog( + GuiService:AddCenterDialog( shield, Enum.CenterDialogType.ModalDialog, --ShowFunction @@ -2539,7 +2534,7 @@ if isSaveDialogSupported then function game.RequestShutdown() table.insert(centerDialogs, saveDialogs) - game.GuiService:AddCenterDialog( + GuiService:AddCenterDialog( saveDialogs, Enum.CenterDialogType.QuitDialog, --ShowFunction diff --git a/luau/48488235.luau b/luau/48488235.luau index 14b507d..c3bf70f 100644 --- a/luau/48488235.luau +++ b/luau/48488235.luau @@ -2,12 +2,21 @@ -- CoreGui.RobloxGui.CoreScripts/PlayerListScript print "[Mercury]: Loaded corescript 48488235" +local ContentProvider = game:GetService "ContentProvider" +local GuiService = game:GetService "GuiService" +local PersonalServerService = + game:GetService "PersonalServerService" :: PersonalServerService +local Players = game:GetService "Players" local RunService = game:GetService "RunService" +local StarterGui = game:GetService "StarterGui" +local Teams = game:GetService "Teams" local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate local log = require "../Modules/Logger" +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path -------------------- -- Super Util @@ -16,9 +25,7 @@ local log = require "../Modules/Logger" local ADMINS = { taskmanager = 1, heliodex = 1, - multako = "http://banland.xyz/asset?id=6923328292", mercury = 1, - pizzaboxer = "http://banland.xyz/asset?id=6917566633", } local Images = { @@ -75,7 +82,7 @@ end local function getMembershipTypeIcon(membershipType, playerName) if ADMINS[string.lower(playerName)] ~= nil then if ADMINS[string.lower(playerName)] == 1 then - return "http://banland.xyz/asset?id=6923330951" + return path "asset?id=6923330951" end return ADMINS[string.lower(playerName)] elseif membershipType == Enum.MembershipType.None then @@ -86,9 +93,8 @@ local function getMembershipTypeIcon(membershipType, playerName) return "rbxasset://textures/ui/TinyTbcIcon.png" elseif membershipType == Enum.MembershipType.OutrageousBuildersClub then return "rbxasset://textures/ui/TinyObcIcon.png" - else - error("Unknown membershipType " .. membershipType) end + error("Unknown membershipType " .. membershipType) end local function getFriendStatusIcon(friendStatus) @@ -98,25 +104,15 @@ local function getFriendStatusIcon(friendStatus) then return "" elseif friendStatus == Enum.FriendStatus.Friend then - return "http://banland.xyz/asset?id=99749771" + return path "asset?id=99749771" elseif friendStatus == Enum.FriendStatus.FriendRequestSent then - return "http://banland.xyz/asset?id=99776888" + return path "asset?id=99776888" elseif friendStatus == Enum.FriendStatus.FriendRequestReceived then - return "http://banland.xyz/asset?id=99776838" - else - error("Unknown FriendStatus " .. friendStatus) + return path "asset?id=99776838" end + error("Unknown FriendStatus " .. friendStatus) end ---------------------------- --- Workspace Objects ---------------------------- - --- might want to move all this to an init function, wait for localplayer elsewhere -local ContentProvider = game:GetService "ContentProvider" -local PersonalServerService = game:GetService "PersonalServerService" -local Players = game:GetService "Players" - -- make sure this doesn't run on the server(it will if you dont do this) while not Players.LocalPlayer do Players.Changed:wait() @@ -156,7 +152,7 @@ local HeaderFrame = New "Frame" { Position = UDim2.new(0, 0, 0, 0), Size = UDim2.new(1, 0, 0.07, 0), Parent = MainFrame, - MakeBackgroundGuiObj "http://banland.xyz/asset?id=94692054", + MakeBackgroundGuiObj(path "asset?id=94692054"), } local HeaderFrameHeight = HeaderFrame.Size.Y.Scale local MaximizeButton = New "ImageButton" { @@ -213,7 +209,7 @@ local BottomFrame = New "Frame" { Position = UDim2.new(0, 0, 0.07, 0), Size = UDim2.new(1, 0, 0.03, 0), Parent = BottomShiftFrame, - MakeBackgroundGuiObj "http://banland.xyz/asset?id=94754966", + MakeBackgroundGuiObj(path "asset?id=94754966"), } local ExtendButton = New "ImageButton" { Name = "bigbutton", @@ -228,7 +224,7 @@ local ExtendTab = New "ImageButton" { Name = "extendTab", Active = true, BackgroundTransparency = 1, - Image = "http://banland.xyz/asset?id=94692731", + Image = path "asset?id=94692731", Position = UDim2.new(0.608, 0, 0.3, 0), Size = UDim2.new(0.3, 0, 0.7, 0), Parent = BottomFrame, @@ -386,7 +382,7 @@ local MiddleBGTemplate = New "Frame" { BackgroundTransparency = 1, Position = UDim2.new(100, 0, 0.07, 0), Size = UDim2.new(0.5, 0, 0.025, 0), --UDim2.new(1, 0, .03, 0), - MakeBackgroundGuiObj "http://banland.xyz/asset?id=94692025", + MakeBackgroundGuiObj(path "asset?id=94692025"), } -- REPORT ABUSE OBJECTS @@ -417,7 +413,7 @@ local AbuseSettingsFrame = New "Frame" { Size = UDim2.new(1, 0, 1, 0), Active = true, BackgroundTransparency = 1, - MakeBackgroundGuiObj "http://banland.xyz/asset?id=96488767", -- 96480351", + MakeBackgroundGuiObj(path "asset?id=96488767"), -- 96480351", New "TextLabel" { Name = "Title", Text = "Report Abuse", @@ -496,7 +492,7 @@ local SubmitReportButton = New "ImageButton" { Position = UDim2.new(0.5, -200, 1, -80), Size = UDim2.new(0, 150, 0, 50), AutoButtonColor = false, - Image = "http://banland.xyz/asset?id=96502438", -- 96501119', + Image = path "asset?id=96502438", -- 96501119', Parent = AbuseSettingsFrame, } @@ -506,7 +502,7 @@ local CancelReportButton = New "ImageButton" { Position = UDim2.new(0.5, 50, 1, -80), Size = UDim2.new(0, 150, 0, 50), AutoButtonColor = true, - Image = "http://banland.xyz/asset?id=96500683", + Image = path "asset?id=96500683", Parent = AbuseSettingsFrame, } @@ -542,7 +538,7 @@ local CalmingAbuseBox = New "Frame" { BackgroundTransparency = 1, Position = UDim2.new(0.25, 0, 0.300000012, 0), Size = UDim2.new(0.5, 0, 0.370000005, 0), - MakeBackgroundGuiObj "http://banland.xyz/asset?id=96506233", + MakeBackgroundGuiObj(path "asset?id=96506233"), New "TextLabel" { Name = "Header", Position = UDim2.new(0, 10, 0.05, 0), @@ -575,7 +571,7 @@ local CalmingAbuseBox = New "Frame" { Position = UDim2.new(0.5, -75, 1, -80), Size = UDim2.new(0, 150, 0, 50), AutoButtonColor = true, - Image = "http://banland.xyz/asset?id=96507959", + Image = path "asset?id=96507959", }, } local NormalAbuseBox = New "Frame" { @@ -583,7 +579,7 @@ local NormalAbuseBox = New "Frame" { BackgroundTransparency = 1, Position = UDim2.new(0.25, 0, 0.300000012, 0), Size = UDim2.new(0.5, 0, 0.370000005, 0), - MakeBackgroundGuiObj "http://banland.xyz/asset?id=96506233", + MakeBackgroundGuiObj(path "asset?id=96506233"), New "TextLabel" { Name = "Header", Position = UDim2.new(0, 10, 0.05, 0), @@ -616,7 +612,7 @@ local NormalAbuseBox = New "Frame" { Position = UDim2.new(0.5, -75, 1, -80), Size = UDim2.new(0, 150, 0, 50), AutoButtonColor = true, - Image = "http://banland.xyz/asset?id=96507959", + Image = path "asset?id=96507959", }, } @@ -653,7 +649,7 @@ local RbxGui = assert(LoadLibrary "RbxGui") local DefaultEntriesOnScreen = 8 for _, i in pairs(Images) do - ContentProvider:Preload("http://banland.xyz/asset?id=" .. i) + ContentProvider:Preload(path "asset?id=" .. i) end -- ordered array of 'score data', each entry has: @@ -893,7 +889,7 @@ end player player to change rank of nrank new integer rank to give player --]] -local function SetPrivilegeRank(player, nrank: number) +local function SetPrivilegeRank(player: Player, nrank: number) while player.PersonalServerRank < nrank do PersonalServerService:Promote(player) end @@ -914,25 +910,20 @@ local function HighlightMyRank( MemberButton, AdminButton ) - BanPlayerButton.Image = "http://banland.xyz/asset?id=" - .. Images.LightPopupMid - VisitorButton.Image = "http://banland.xyz/asset?id=" .. Images.DarkPopupMid - MemberButton.Image = "http://banland.xyz/asset?id=" .. Images.LightPopupMid - AdminButton.Image = "http://banland.xyz/asset?id=" .. Images.DarkPopupBottom + BanPlayerButton.Image = path "asset?id=" .. Images.LightPopupMid + VisitorButton.Image = path "asset?id=" .. Images.DarkPopupMid + MemberButton.Image = path "asset?id=" .. Images.LightPopupMid + AdminButton.Image = path "asset?id=" .. Images.DarkPopupBottom local rank = player.PersonalServerRank if rank <= PrivilegeLevel.Banned then - BanPlayerButton.Image = - `http://banland.xyz/asset?id={Images.LightBluePopupMid}` + BanPlayerButton.Image = path "asset?id=" .. Images.LightBluePopupMid elseif rank <= PrivilegeLevel.Visitor then - VisitorButton.Image = - `http://banland.xyz/asset?id={Images.DarkBluePopupMid}` + VisitorButton.Image = path "asset?id=" .. Images.DarkBluePopupMid elseif rank <= PrivilegeLevel.Member then - MemberButton.Image = - `http://banland.xyz/asset?id={Images.LightBluePopupMid}` + MemberButton.Image = path "asset?id=" .. Images.LightBluePopupMid elseif rank <= PrivilegeLevel.Admin then - AdminButton.Image = - `http://banland.xyz/asset?id={Images.DarkBluePopupBottom}` + AdminButton.Image = path "asset?id=" .. Images.DarkBluePopupBottom end end @@ -971,7 +962,7 @@ end local function CloseAbuseDialog() AbuseName = nil SubmitReportButton.Active = false - SubmitReportButton.Image = "http://banland.xyz/asset?id=96502438" -- 96501119", + SubmitReportButton.Image = path "asset?id=96502438" -- 96501119", AbuseDescriptionBox:Destroy() CalmingAbuseBox.Parent = nil NormalAbuseBox.Parent = nil @@ -986,7 +977,7 @@ local function OnSubmitAbuse() if SubmitReportButton.Active then if AbuseName and SelectedPlayer then AbuseSettingsFrame.Visible = false - game.Players:ReportAbuse( + Players:ReportAbuse( SelectedPlayer, AbuseName, AbuseDescriptionBox.Text @@ -1053,7 +1044,7 @@ local function InitReportAbuse() AbuseName = abuseText if AbuseName and SelectedPlayer then SubmitReportButton.Active = true - SubmitReportButton.Image = "http://banland.xyz/asset?id=96501119" + SubmitReportButton.Image = path "asset?id=96501119" end end @@ -1082,11 +1073,11 @@ end @Return: enum of friend status --]] local function GetFriendStatus(player: Player) - if player == game.Players.LocalPlayer then + if player == Players.LocalPlayer then return Enum.FriendStatus.NotFriend end local ok, result = pcall(function() - return game.Players.LocalPlayer:GetFriendStatus(player) + return Players.LocalPlayer:GetFriendStatus(player) end) if ok then return result @@ -1352,17 +1343,13 @@ local function UpdateMaximize() BASE_TWEEN * 1.2, true ) - HeaderFrame.Background.Image = "http://banland.xyz/asset?id=" - .. Images.LargeHeader - BottomFrame.Background.Image = "http://banland.xyz/asset?id=" - .. Images.LargeBottom + HeaderFrame.Background.Image = path "asset?id=" .. Images.LargeHeader + BottomFrame.Background.Image = path "asset?id=" .. Images.LargeBottom for index, i in ipairs(MiddleFrameBackgrounds) do if (index % 2) ~= 1 then - i.Background.Image = "http://banland.xyz/asset?id=" - .. Images.LargeDark + i.Background.Image = path "asset?id=" .. Images.LargeDark else - i.Background.Image = "http://banland.xyz/asset?id=" - .. Images.LargeLight + i.Background.Image = path "asset?id=" .. Images.LargeLight end end for _, i in ipairs(MiddleFrames) do @@ -1422,17 +1409,13 @@ local function UpdateMaximize() BASE_TWEEN * 1.2, true ) - HeaderFrame.Background.Image = "http://banland.xyz/asset?id=" - .. Images.NormalHeader - BottomFrame.Background.Image = "http://banland.xyz/asset?id=" - .. Images.NormalBottom + HeaderFrame.Background.Image = path "asset?id=" .. Images.NormalHeader + BottomFrame.Background.Image = path "asset?id=" .. Images.NormalBottom for index, i in ipairs(MiddleFrameBackgrounds) do if index % 2 ~= 1 then - i.Background.Image = "http://banland.xyz/asset?id=" - .. Images.midDark + i.Background.Image = path "asset?id=" .. Images.midDark else - i.Background.Image = "http://banland.xyz/asset?id=" - .. Images.midLight + i.Background.Image = path "asset?id=" .. Images.midLight end end for _, i in ipairs(MiddleFrames) do @@ -1474,6 +1457,12 @@ local function UpdateMaximize() end end +type ValueBase = { + Value: any, + ConstrainedValue: number, + IsA: (self: ValueBase, name: string) -> boolean, +} + local function GetScoreValue(score: ValueBase): number if score:IsA "DoubleConstrainedValue" or score:IsA "IntConstrainedValue" @@ -1601,17 +1590,21 @@ local function AddTeamScores(team) UpdateMinimize() end +type SortableTeam = { + TeamScore: number, + ID: number, + MyPlayers: { any }, +} + --[[ uses lua's table.sort to sort the teams --]] -local function TeamSortFunc(a, b) +local function TeamSortFunc(a: SortableTeam, b: SortableTeam) if a.TeamScore == b.TeamScore then return a.ID < b.ID - end - if not a.TeamScore then + elseif not a.TeamScore then return false - end - if not b.TeamScore then + elseif not b.TeamScore then return true end return a.TeamScore < b.TeamScore @@ -1896,7 +1889,7 @@ function UpdateMinimize() true ) FocusFrame.Size = UDim2.new(1, 0, HeaderFrameHeight, 0) - ExtendTab.Image = "http://banland.xyz/asset?id=94692731" + ExtendTab.Image = path "asset?id=94692731" else if not IsMaximized.Value then MainFrame:TweenSizeAndPosition( @@ -1921,7 +1914,7 @@ function UpdateMinimize() ) BottomFrame.Position = UDim2.new(0, 0, bottomPositon, 0) FocusFrame.Size = UDim2.new(1, 0, bottomPositon + HeaderFrameHeight, 0) - ExtendTab.Image = "http://banland.xyz/asset?id=94825585" + ExtendTab.Image = path "asset?id=94825585" end end @@ -2066,7 +2059,7 @@ local function StatAdded(nchild, playerEntry) end --returns whether any of the existing players has this stat -local function DoesStatExist(statName, exception) +local function DoesStatExist(statName, exception: Player) for _, playerf in pairs(PlayerFrames) do if playerf.Player ~= exception @@ -2216,14 +2209,14 @@ local function MakePopupButton(nparent, ntext, index, last: boolean?) Parent = nparent, } if index == 0 then - tobj.Image = "http://banland.xyz/asset?id=97108784" + tobj.Image = path "asset?id=97108784" elseif last then tobj.Image = index % 2 == 1 - and "http://banland.xyz/asset?id=" .. Images.LightPopupBottom - or "http://banland.xyz/asset?id=" .. Images.DarkPopupBottom + and path "asset?id=" .. Images.LightPopupBottom + or path "asset?id=" .. Images.DarkPopupBottom else - tobj.Image = index % 2 == 1 and "http://banland.xyz/asset?id=97112126" - or "http://banland.xyz/asset?id=97109338" + tobj.Image = index % 2 == 1 and path "asset?id=97112126" + or path "asset?id=97109338" end return tobj end @@ -2555,7 +2548,7 @@ local function AddMiddleBGFrame() UDim2.new(0.5, 0, (#MiddleFrameBackgrounds * nBGFrame.Size.Y.Scale), 0) local function applyImage(id: string) - nBGFrame.Background.Image = "http://banland.xyz/asset?id=" .. id + nBGFrame.Background.Image = path "asset?id=" .. id end if (#MiddleFrameBackgrounds + 1) % 2 ~= 1 then @@ -2800,7 +2793,7 @@ local function SetPlayerToTeam(entry) end end -- if player was set to an invalid team, then set it back to neutral - if not setToTeam and #(game.Teams:GetTeams()) > 0 then + if not setToTeam and #Teams:GetTeams() > 0 then log(`{entry.Player.Name} could not find team`) entry.MyTeam = nil if not NeutralTeam then @@ -2827,7 +2820,7 @@ local function PlayerChanged(entry, property) PlayerChangedLock = true if property == "Neutral" then -- if player changing to neutral - if entry.Player.Neutral and #(game.Teams:GetTeams()) > 0 then + if entry.Player.Neutral and #(Teams:GetTeams()) > 0 then log(entry.Player.Name .. " setting to neutral") FindRemovePlayerFromTeam(entry) entry.MyTeam = nil @@ -2838,7 +2831,7 @@ local function PlayerChanged(entry, property) log(entry.Player.Name .. " adding to neutral team") AddPlayerToTeam(NeutralTeam, entry) end - elseif #(game.Teams:GetTeams()) > 0 then -- else player switching to a team, or a weird edgecase + elseif #(Teams:GetTeams()) > 0 then -- else player switching to a team, or a weird edgecase log(entry.Player.Name .. " has been set non-neutral") SetPlayerToTeam(entry) end @@ -3276,46 +3269,47 @@ end --[[ code for attaching tab key to maximizing player list --]] -game.GuiService:AddKey "\t" +GuiService:AddKey "\t" local LastTabTime = time() -game.GuiService.KeyPressed:connect(function(key) +GuiService.KeyPressed:connect(function(key) if key == "\t" then log "caught tab key" local modalCheck, isModal = pcall(function() - return game.GuiService.IsModalDialog + return GuiService.IsModalDialog end) - if modalCheck == false or (modalCheck and isModal == false) then - if time() - LastTabTime > 0.4 then - LastTabTime = time() - if IsTabified.Value then - if not IsMaximized.Value then - ScreenGui:TweenPosition( - UDim2.new(0, 0, 0, 0), - "Out", - "Linear", - BASE_TWEEN * 1.2, - true - ) - IsMaximized.Value = true - else - ScreenGui:TweenPosition( - UDim2.new( - NormalBounds.X.Scale, - NormalBounds.X.Offset - 10, - 0, - 0 - ), - "Out", - "Linear", - BASE_TWEEN * 1.2, - true - ) - IsMaximized.Value = false - IsMinimized.Value = true - end + if + (modalCheck == false or (modalCheck and isModal == false)) + and time() - LastTabTime > 0.4 + then + LastTabTime = time() + if IsTabified.Value then + if not IsMaximized.Value then + ScreenGui:TweenPosition( + UDim2.new(0, 0, 0, 0), + "Out", + "Linear", + BASE_TWEEN * 1.2, + true + ) + IsMaximized.Value = true else - ToggleMaximize() + ScreenGui:TweenPosition( + UDim2.new( + NormalBounds.X.Scale, + NormalBounds.X.Offset - 10, + 0, + 0 + ), + "Out", + "Linear", + BASE_TWEEN * 1.2, + true + ) + IsMaximized.Value = false + IsMinimized.Value = true end + else + ToggleMaximize() end end end @@ -3337,16 +3331,16 @@ end pcall(function() coreGuiChanged( Enum.CoreGuiType.PlayerList, - game.StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.PlayerList) + StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.PlayerList) ) - game.StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged) + StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged) end) while not game:GetService "Teams" do RunService.Heartbeat:wait() log "Waiting For Teams" end -for _, i in pairs(game.Teams:GetTeams()) do +for _, i in pairs(Teams:GetTeams()) do TeamAdded(i) end for _, i in pairs(Players:GetPlayers()) do @@ -3385,8 +3379,8 @@ end -- Hookups and initialization ---------------------------- -game.Teams.ChildAdded:connect(TeamsChildAdded) -game.Teams.ChildRemoved:connect(TeamsChildRemoved) +Teams.ChildAdded:connect(TeamsChildAdded) +Teams.ChildRemoved:connect(TeamsChildRemoved) Players.ChildAdded:connect(PlayersChildAdded) InitReportAbuse() diff --git a/luau/48488398.luau b/luau/48488398.luau index ba6cc67..ab37932 100644 --- a/luau/48488398.luau +++ b/luau/48488398.luau @@ -1,26 +1,45 @@ +--!strict -- CoreGui.RobloxGui.CoreScripts/NotificationScript print "[Mercury]: Loaded corescript 48488398" local GuiService = game:GetService "GuiService" +local Players = game:GetService "Players" local TeleportService = game:GetService "TeleportService" -local function waitForProperty(instance, property) +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path + +local function waitForProperty(instance: Instance, property: string) while not instance[property] do instance.Changed:wait() end end -local function waitForChild(instance, name) +local function waitForChild(instance: Instance, name: string) while not instance:FindFirstChild(name) do instance.ChildAdded:wait() end end -waitForProperty(game.Players, "LocalPlayer") -waitForChild(script.Parent, "Popup") -waitForChild(script.Parent.Popup, "AcceptButton") -script.Parent.Popup.AcceptButton.Modal = true +type Popup = Frame & { + AcceptButton: TextButton, + OKButton: TextButton, + DeclineButton: TextButton, + PopupText: TextLabel, + PopupImage: ImageLabel, +} -local localPlayer = game.Players.LocalPlayer +local gui = script.Parent :: ScreenGui + +local function getPopup() + return gui:FindFirstChild "Popup" :: Popup +end + +waitForProperty(Players, "LocalPlayer") +waitForChild(gui, "Popup") +waitForChild(getPopup(), "AcceptButton") +getPopup().AcceptButton.Modal = true + +local localPlayer = Players.LocalPlayer local teleportUI local friendRequestBlacklist = {} @@ -28,31 +47,33 @@ local friendRequestBlacklist = {} local teleportEnabled = true local function makePopupInvisible() - if script.Parent.Popup then - script.Parent.Popup.Visible = false + if getPopup() then + getPopup().Visible = false end end local function showOneButton() - local popup = script.Parent:FindFirstChild "Popup" - if popup then - popup.OKButton.Visible = true - popup.DeclineButton.Visible = false - popup.AcceptButton.Visible = false + local popup = gui:FindFirstChild "Popup" :: Popup + if not popup then + return end + popup.OKButton.Visible = true + popup.DeclineButton.Visible = false + popup.AcceptButton.Visible = false end local function showTwoButtons() - local popup = script.Parent:FindFirstChild "Popup" - if popup then - popup.OKButton.Visible = false - popup.DeclineButton.Visible = true - popup.AcceptButton.Visible = true + local popup = gui:FindFirstChild "Popup" :: Popup + if not popup then + return end + popup.OKButton.Visible = false + popup.DeclineButton.Visible = true + popup.AcceptButton.Visible = true end local function makeFriend(fromPlayer, toPlayer) - local popup = script.Parent:FindFirstChild "Popup" + local popup = gui:FindFirstChild "Popup" :: Popup if popup == nil -- there is no popup! or popup.Visible -- currently popping something, abort! @@ -63,7 +84,7 @@ local function makeFriend(fromPlayer, toPlayer) popup.PopupText.Text = `Accept Friend Request from {fromPlayer.Name}?` popup.PopupImage.Image = - `http://banland.xyz/thumbs/avatar.ashx?userId={fromPlayer.userId}&x=352&y=352` + path(`thumbs/avatar.ashx?userId={fromPlayer.userId}&x=352&y=352`) showTwoButtons() popup.Visible = true @@ -120,7 +141,9 @@ local function makeFriend(fromPlayer, toPlayer) end) end -game.Players.FriendRequestEvent:connect(function(fromPlayer, toPlayer, event) +Players.FriendRequestEvent:connect(function(fromPlr, toPlr, event) + local toPlayer = toPlr :: Player + local fromPlayer = fromPlr :: Player -- if this doesn't involve me, then do nothing if fromPlayer ~= localPlayer and toPlayer ~= localPlayer then return @@ -129,7 +152,7 @@ game.Players.FriendRequestEvent:connect(function(fromPlayer, toPlayer, event) GuiService:SendNotification( "You are Friends", `With {toPlayer.Name}!`, - `http://banland.xyz/thumbs/avatar.ashx?userId={toPlayer.userId}&x=48&y=48`, + path(`thumbs/avatar.ashx?userId={toPlayer.userId}&x=48&y=48`), 5, function() end ) @@ -142,7 +165,7 @@ game.Players.FriendRequestEvent:connect(function(fromPlayer, toPlayer, event) GuiService:SendNotification( "Friend Request", `From {fromPlayer.Name}`, - `http://banland.xyz/thumbs/avatar.ashx?userId={fromPlayer.userId}&x=48&y=48`, + path(`thumbs/avatar.ashx?userId={fromPlayer.userId}&x=48&y=48`), 8, function() makeFriend(fromPlayer, toPlayer) @@ -152,7 +175,7 @@ game.Players.FriendRequestEvent:connect(function(fromPlayer, toPlayer, event) GuiService:SendNotification( "You are Friends", `With {fromPlayer.Name}!`, - `http://banland.xyz/thumbs/avatar.ashx?userId={fromPlayer.userId}&x=48&y=48`, + path(`thumbs/avatar.ashx?userId={fromPlayer.userId}&x=48&y=48`), 5, function() end ) @@ -162,7 +185,7 @@ end) local function showTeleportUI(message, timer) if teleportUI ~= nil then - teleportUI:Remove() + teleportUI:Destroy() end waitForChild(localPlayer, "PlayerGui") teleportUI = Instance.new "Message" @@ -170,7 +193,7 @@ local function showTeleportUI(message, timer) teleportUI.Parent = localPlayer.PlayerGui if timer > 0 then wait(timer) - teleportUI:Remove() + teleportUI:Destroy() end end @@ -195,7 +218,7 @@ if teleportEnabled then localPlayer.OnTeleport:connect(onTeleport) function TeleportService.ErrorCallback(message) - local popup = script.Parent:FindFirstChild "Popup" + local popup = gui:FindFirstChild "Popup" :: Popup showOneButton() popup.PopupText.Text = message local clickCon @@ -204,9 +227,7 @@ if teleportEnabled then if clickCon then clickCon:disconnect() end - game.GuiService:RemoveCenterDialog( - script.Parent:FindFirstChild "Popup" - ) + GuiService:RemoveCenterDialog(gui:FindFirstChild "Popup" :: Popup) popup:TweenSize( UDim2.new(0, 0, 0, 0), Enum.EasingDirection.Out, @@ -216,13 +237,13 @@ if teleportEnabled then makePopupInvisible() ) end) - game.GuiService:AddCenterDialog( - script.Parent:FindFirstChild "Popup", + GuiService:AddCenterDialog( + gui:FindFirstChild "Popup" :: Popup, Enum.CenterDialogType.QuitDialog, --ShowFunction function() showOneButton() - script.Parent:FindFirstChild("Popup").Visible = true + gui:FindFirstChild("Popup").Visible = true popup:TweenSize( UDim2.new(0, 330, 0, 350), Enum.EasingDirection.Out, @@ -245,7 +266,7 @@ if teleportEnabled then ) end function TeleportService.ConfirmationCallback(message, placeId, spawnName) - local popup = script.Parent:FindFirstChild "Popup" + local popup = getPopup() popup.PopupText.Text = message popup.PopupImage.Image = "" @@ -258,9 +279,7 @@ if teleportEnabled then if noCon then noCon:disconnect() end - game.GuiService:RemoveCenterDialog( - script.Parent:FindFirstChild "Popup" - ) + GuiService:RemoveCenterDialog(getPopup()) popup:TweenSize( UDim2.new(0, 0, 0, 0), Enum.EasingDirection.Out, @@ -284,9 +303,7 @@ if teleportEnabled then if clickCon then clickCon:disconnect() end - game.GuiService:RemoveCenterDialog( - script.Parent:FindFirstChild "Popup" - ) + GuiService:RemoveCenterDialog(getPopup()) popup:TweenSize( UDim2.new(0, 0, 0, 0), Enum.EasingDirection.Out, @@ -296,13 +313,13 @@ if teleportEnabled then makePopupInvisible() ) end) - game.GuiService:AddCenterDialog( - script.Parent:FindFirstChild "Popup", + GuiService:AddCenterDialog( + getPopup(), Enum.CenterDialogType.QuitDialog, --ShowFunction function() showOneButton() - script.Parent:FindFirstChild("Popup").Visible = true + getPopup().Visible = true popup:TweenSize( UDim2.new(0, 330, 0, 350), Enum.EasingDirection.Out, @@ -334,15 +351,15 @@ if teleportEnabled then end) local centerDialogSuccess = pcall(function() - game.GuiService:AddCenterDialog( - script.Parent:FindFirstChild "Popup", + GuiService:AddCenterDialog( + gui:FindFirstChild "Popup", Enum.CenterDialogType.QuitDialog, --ShowFunction function() showTwoButtons() popup.AcceptButton.Text = "Leave" popup.DeclineButton.Text = "Stay" - script.Parent:FindFirstChild("Popup").Visible = true + gui:FindFirstChild("Popup").Visible = true popup:TweenSize( UDim2.new(0, 330, 0, 350), Enum.EasingDirection.Out, @@ -366,7 +383,7 @@ if teleportEnabled then end) if centerDialogSuccess == false then - script.Parent:FindFirstChild("Popup").Visible = true + gui:FindFirstChild("Popup").Visible = true popup.AcceptButton.Text = "Leave" popup.DeclineButton.Text = "Stay" popup:TweenSize( diff --git a/luau/48488451.luau b/luau/48488451.luau index 010e110..4e2f20b 100644 --- a/luau/48488451.luau +++ b/luau/48488451.luau @@ -1,9 +1,12 @@ +--!strict -- CoreGui.RobloxGui.CoreScripts/PopupScript print "[Mercury]: Loaded corescript 48488451" local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path -- build our gui @@ -25,7 +28,7 @@ local popupFrame = New "Frame" { Name = "Backing", BackgroundTransparency = 1, Size = UDim2.new(1, 0, 1, 0), - Image = "http://banland.xyz/asset?id=47574181", + Image = path "asset?id=47574181", ZIndex = 2, }, }, @@ -74,4 +77,4 @@ Hydrate(acceptButton:Clone()) { Parent = popupFrame, } -script:remove() +script:Destroy() diff --git a/luau/53878047.luau b/luau/53878047.luau index feb7cda..c34e7e5 100644 --- a/luau/53878047.luau +++ b/luau/53878047.luau @@ -1,29 +1,33 @@ +--!strict -- CoreGui.RobloxGui.CoreScripts/BackpackScripts/BackpackBuild print "[Mercury]: Loaded corescript 53878047" +local Players = game:GetService "Players" + local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path -- This script creates almost all gui elements found in the backpack (warning: there are a lot!) -- TODO: automate this process -local gui = script.Parent +local gui = script.Parent :: ScreenGui & { ControlFrame: Frame } -- A couple of necessary functions -local function waitForChild(instance, name) +local function waitForChild(instance: Instance, name: string) while not instance:FindFirstChild(name) do instance.ChildAdded:wait() end end -local function waitForProperty(instance, property) +local function waitForProperty(instance: Instance, property: string) while not instance[property] do instance.Changed:wait() end end -waitForChild(game, "Players") -waitForProperty(game.Players, "LocalPlayer") +waitForProperty(Players, "LocalPlayer") -- Components @@ -73,7 +77,7 @@ local CurrentLoadout = New "Frame" { New "ImageLabel" { Name = "Background", Size = UDim2.new(1.2, 0, 1.2, 0), - Image = "http://banland.xyz/asset?id=96536002", + Image = path "asset?id=96536002", BackgroundTransparency = 1, Position = UDim2.new(-0.1, 0, -0.1, 0), ZIndex = 0.0, @@ -81,7 +85,7 @@ local CurrentLoadout = New "Frame" { New "ImageLabel" { Size = UDim2.new(1, 0, 0.025, 1), Position = UDim2.new(0, 0, 0, 0), - Image = "http://banland.xyz/asset?id=97662207", + Image = path "asset?id=97662207", BackgroundTransparency = 1, }, }, @@ -101,13 +105,13 @@ local CurrentLoadout = New "Frame" { New "ImageLabel" { Name = "Background", BackgroundTransparency = 1, - Image = "http://banland.xyz/asset?id=97613075", + Image = path "asset?id=97613075", Size = UDim2.new(1, 0, 1, 0), }, -- New "ImageLabel" { -- Name = "Highlight", -- BackgroundTransparency = 1, - -- Image = "http://banland.xyz/asset?id=97643886", + -- Image = path "asset?id=97643886", -- Size = UDim2.new(1, 0, 1, 0), -- Visible = false, -- } @@ -184,7 +188,7 @@ New "ImageButton" { Visible = false, Name = "BackpackButton", BackgroundTransparency = 1, - Image = "http://banland.xyz/asset?id=97617958", + Image = path "asset?id=97617958", Position = UDim2.new(0.5, -60, 1, -108), Size = UDim2.new(0, 120, 0, 18), Parent = gui.ControlFrame, @@ -271,7 +275,7 @@ New "Frame" { New "ImageLabel" { RobloxLocked = true, Name = "XImage", - Image = "http://banland.xyz/asset?id=75547445", + Image = path "asset?id=75547445", BackgroundTransparency = 1, Position = UDim2.new(-0.25, -1, -0.25, -1), Size = UDim2.new(1.5, 2, 1.5, 2), @@ -483,7 +487,7 @@ New "Frame" { New "ImageLabel" { Name = "Background", BackgroundTransparency = 1, - Image = "http://banland.xyz/asset?id=97613075", + Image = path "asset?id=97613075", Size = UDim2.new(1, 0, 1, 0), }, New "ObjectValue" { diff --git a/luau/53878057.luau b/luau/53878057.luau index 716af5c..4b47afc 100644 --- a/luau/53878057.luau +++ b/luau/53878057.luau @@ -3,7 +3,9 @@ print "[Mercury]: Loaded corescript 53878057" local CoreGui = game:GetService "CoreGui" local GuiService = game:GetService "GuiService" +local Players = game:GetService "Players" local RunService = game:GetService "RunService" +local StarterGui = game:GetService "StarterGui" local UserInputService = game:GetService "UserInputService" -- A couple of necessary functions @@ -23,15 +25,15 @@ local currentLoadout = script.Parent local StaticTabName = "gear" local backpackEnabled = true -local mercuryGui = CoreGui:FindFirstChild "RobloxGui" -assert(mercuryGui) +local MercuryGui = CoreGui:FindFirstChild "RobloxGui" +assert(MercuryGui) -local controlFrame = waitForChild(mercuryGui, "ControlFrame") +local controlFrame = waitForChild(MercuryGui, "ControlFrame") local backpackButton = waitForChild(controlFrame, "BackpackButton") -local backpack = waitForChild(mercuryGui, "Backpack") -waitForChild(mercuryGui, "CurrentLoadout") -waitForChild(mercuryGui.CurrentLoadout, "TempSlot") -waitForChild(mercuryGui.CurrentLoadout.TempSlot, "SlotNumber") +local backpack = waitForChild(MercuryGui, "Backpack") +waitForChild(MercuryGui, "CurrentLoadout") +waitForChild(MercuryGui.CurrentLoadout, "TempSlot") +waitForChild(MercuryGui.CurrentLoadout.TempSlot, "SlotNumber") waitForChild(currentLoadout, "Background") local clBackground = currentLoadout.Background @@ -59,9 +61,8 @@ local function setHealthBarVisible(pGui, visible) end --- Begin Locals -waitForChild(game, "Players") -waitForProperty(game.Players, "LocalPlayer") -local player = game.Players.LocalPlayer +waitForProperty(Players, "LocalPlayer") +local player = Players.LocalPlayer waitForChild(player, "PlayerGui") Spawn(function() @@ -149,7 +150,7 @@ local function unregisterNumberKeys() end local function characterInWorkspace() - local localPlayer = game.Players.LocalPlayer + local localPlayer = Players.LocalPlayer return localPlayer and localPlayer.Character and localPlayer.Character ~= nil @@ -168,10 +169,10 @@ local function removeGear(gear) if gearSlots[emptySlot].GearReference.Value then if gearSlots[emptySlot].GearReference.Value.Parent - == game.Players.LocalPlayer.Character + == Players.LocalPlayer.Character then -- if we currently have this equipped, unequip it gearSlots[emptySlot].GearReference.Value.Parent = - game.Players.LocalPlayer.Backpack + Players.LocalPlayer.Backpack end if @@ -635,7 +636,7 @@ local function unequipAllItems(dontEquipThis) gearSlots[i].GearReference.Value:Disable() elseif gearSlots[i].GearReference.Value:IsA "Tool" then gearSlots[i].GearReference.Value.Parent = - game.Players.LocalPlayer.Backpack + Players.LocalPlayer.Backpack end gearSlots[i].Selected = false end @@ -885,7 +886,7 @@ local function addingPlayerChild( childChangeCon:disconnect() end removeFromInventory(child) - elseif newParent == game.Players.LocalPlayer.Backpack then + elseif newParent == Players.LocalPlayer.Backpack then normaliseButton(gearClone) end end) @@ -1070,7 +1071,7 @@ local function coreGuiChanged(coreGuiType, enabled) coreGuiType == Enum.CoreGuiType.Health or coreGuiType == Enum.CoreGuiType.All then - setHealthBarVisible(game.Players.LocalPlayer.PlayerGui, enabled) + setHealthBarVisible(Players.LocalPlayer.PlayerGui, enabled) end end -- End Functions @@ -1081,13 +1082,13 @@ registerNumberKeys() pcall(function() coreGuiChanged( Enum.CoreGuiType.Backpack, - game.StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.Backpack) + StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.Backpack) ) coreGuiChanged( Enum.CoreGuiType.Health, - game.StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.Health) + StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.Health) ) - game.StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged) + StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged) end) RunService.Heartbeat:wait() -- let stuff initialize incase this is first heartbeat... @@ -1147,8 +1148,8 @@ player.CharacterRemoving:connect(function() end) player.CharacterAdded:connect(function() - waitForProperty(game.Players, "LocalPlayer") - player = game.Players.LocalPlayer -- make sure we are still looking at the correct character + waitForProperty(Players, "LocalPlayer") + player = Players.LocalPlayer -- make sure we are still looking at the correct character waitForChild(player, "Backpack") delay(1, function() diff --git a/luau/60595411.luau b/luau/60595411.luau index 118419a..ec6e323 100644 --- a/luau/60595411.luau +++ b/luau/60595411.luau @@ -1,3 +1,4 @@ +--!strict -- RbxUtility print "[Mercury]: Loaded corescript 60595411" @@ -5,7 +6,7 @@ local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate -local Terrain = game:GetService "Terrain" +local Terrain = workspace.Terrain local RbxUtility = {} @@ -30,7 +31,7 @@ end -- sets cell x, y, z to default material if parameter is provided, if not sets cell x, y, z to be whatever material it previously w -- returns true if made a wedge, false if the cell remains a block function RbxUtility.MakeWedge(x, y, z, _) - return Terrain:AutoWedgeCell(x, y, z) + return Terrain:AutowedgeCell(x, y, z) end function RbxUtility.SelectTerrainRegion( @@ -80,7 +81,15 @@ function RbxUtility.SelectTerrainRegion( local currentKeepAliveTag -- a tag that determines whether adorns should be destroyed local aliveCounter = 0 -- helper for currentKeepAliveTag local lastRegion -- used to stop updates that do nothing - local adornments = {} -- contains all adornments + local adornments: { + [Vector3int16]: { + SelectionPart: BasePart, + SelectionBox: SelectionBox, + KeepAlive: number, + }, + SelectionPart: BasePart?, + SelectionBox: SelectionBox?, + } = {} -- contains all adornments local reusableAdorns = {} local selectionPart = New "Part" { @@ -146,7 +155,7 @@ function RbxUtility.SelectTerrainRegion( end -- finds full cells in region and adorns each cell with a box, with the argument color - local function adornFullCellsInRegion(region, newColour) + local function adornFullCellsInRegion(region: Region3, newColour: BrickColor) local regionBegin = region.CFrame.p - (region.Size / 2) + Vector3.new(2, 2, 2) @@ -158,9 +167,9 @@ function RbxUtility.SelectTerrainRegion( local cellPosEnd = WorldToCellPreferSolid(terrain, regionEnd) currentKeepAliveTag = incrementAliveCounter() - for y = cellPosBegin.y, cellPosEnd.y do - for z = cellPosBegin.z, cellPosEnd.z do - for x = cellPosBegin.x, cellPosEnd.x do + for y = cellPosBegin.Y, cellPosEnd.Y do + for z = cellPosBegin.Z, cellPosEnd.Z do + for x = cellPosBegin.X, cellPosEnd.X do local cellMaterial = GetCell(terrain, x, y, z) if cellMaterial ~= emptyMaterial then @@ -222,7 +231,7 @@ function RbxUtility.SelectTerrainRegion( end else -- use individual cell adorns to represent the area selected adornFullCellsInRegion(regionToSelect, colour) - function updateSelection(newRegion, newColour) + function updateSelection(newRegion: Region3, newColour) if newRegion and newRegion ~= lastRegion then lastRegion = newRegion adornFullCellsInRegion(newRegion, newColour) @@ -433,9 +442,18 @@ Note: It is also perfectly legal to save a reference to the function returned by local part = partCreatingFunction() ]] ---the Create function need to be created as a functor, not a function, in order to support the Create.E syntax, so it ---will be created in several steps rather than as a single function declaration. -local function Create_PrivImpl(objectType: string) +local Create_PrivImpl + +-- create the functor: +RbxUtility.Create = setmetatable({}, { + __call = function(_, ...) + return Create_PrivImpl(...) + end, +}) + +-- the Create function need to be created as a functor, not a function, in order to support the Create.E syntax, so it +-- will be created in several steps rather than as a single function declaration. +function Create_PrivImpl(objectType: string) if type(objectType) ~= "string" then error("Argument of Create must be a string", 2) end @@ -518,12 +536,7 @@ local function Create_PrivImpl(objectType: string) end end ---now, create the functor: -RbxUtility.Create = setmetatable({}, { - __call = function(_, ...) - return Create_PrivImpl(...) - end, -}) + --and create the "Event.E" syntax stub. Really it's just a stub to construct a table which our Create --function can recognize as special. diff --git a/luau/60595695.luau b/luau/60595695.luau index f292771..8bda5af 100644 --- a/luau/60595695.luau +++ b/luau/60595695.luau @@ -1,3 +1,4 @@ +--!strict -- Script Context./Libraries/LibraryRegistration/LibraryRegist print "[Mercury]: Loaded corescript 60595695" @@ -17,18 +18,19 @@ for _ = 1, 4 do RunService.Heartbeat:wait() end -if ScriptContext then - for name, id in pairs { - Fusion = 10000001, - Red = 10000002, - Load = 10000003, - Gui = 45284430, - Utility = 60595411, - Stamper = 73157242, - } do - ScriptContext:RegisterLibrary("Libraries/Rbx" .. name, tostring(id)) - end - ScriptContext:LibraryRegistrationComplete() -else +if not ScriptContext then print "[Mercury]: Failed to find ScriptContext, libraries did not load" + return end + +for name, id in pairs { + Fusion = 10000001, + Red = 10000002, + Load = 10000003, + Gui = 45284430, + Utility = 60595411, + Stamper = 73157242, +} do + ScriptContext:RegisterLibrary("Libraries/Rbx" .. name, tostring(id)) +end +ScriptContext:LibraryRegistrationComplete() diff --git a/luau/73157242.luau b/luau/73157242.luau index 77b86f2..c7c7e61 100644 --- a/luau/73157242.luau +++ b/luau/73157242.luau @@ -3,10 +3,15 @@ print "[Mercury]: Loaded corescript 73157242" local ChangeHistoryService = game:GetService "ChangeHistoryService" local InsertService = game:GetService "InsertService" +local JointsService = game:GetService "JointsService" +local Lighting = game:GetService "Lighting" +local Players = game:GetService "Players" local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path local RbxStamper = {} @@ -436,9 +441,7 @@ local function isBlocker(part: Instance) -- returns whether or not we want to ca or part:FindFirstChild "RobloxModel" then return true - elseif - (part:IsA "Part" and not part.CanCollide) or (part == game.Lighting) - then + elseif (part:IsA "Part" and not part.CanCollide) or (part == Lighting) then return false end return isBlocker(part.Parent) @@ -844,7 +847,7 @@ local function setupFakeTerrainPart(cellMat, cellType, cellOrient) if cellType == 3 then New "SpecialMesh" { MeshType = "FileMesh", - MeshId = "http://banland.xyz/asset?id=66832495", + MeshId = path "asset?id=66832495", Scale = Vector3.new(2, 2, 2), Parent = newTerrainPiece, } @@ -1116,8 +1119,8 @@ local function DoHighScalabilityRegionSelect( -- make player able to see this ish local gui - if game.Players.LocalPlayer then - gui = game.Players.LocalPlayer:FindFirstChild "PlayerGui" + if Players.LocalPlayer then + gui = Players.LocalPlayer:FindFirstChild "PlayerGui" if gui and gui:IsA "PlayerGui" @@ -1148,10 +1151,10 @@ local function flashRedBox(stampData: { local gui = game.CoreGui if game:FindFirstChild "Players" - and game.Players.LocalPlayer - and game.Players.LocalPlayer:FindFirstChild "PlayerGui" + and Players.LocalPlayer + and Players.LocalPlayer:FindFirstChild "PlayerGui" then - gui = game.Players.LocalPlayer.PlayerGui + gui = Players.LocalPlayer.PlayerGui end if not stampData.ErrorBox then return @@ -1872,7 +1875,7 @@ function RbxStamper.SetupStamperDragger( if modelInfo then hitFace = modelTargetSurface( modelInfo.Parent, - workspace.CurrentCamera.CoordinateFrame.p, + (workspace.CurrentCamera :: Camera).CoordinateFrame.p, mouse.Hit.p ) end @@ -1882,7 +1885,7 @@ function RbxStamper.SetupStamperDragger( if hitFace == tonumber(bf) then -- return before we hit the JointsService code below! unstampableSurface = true - game.JointsService:ClearJoinAfterMoveJoints() -- clear the JointsService cache + JointsService:ClearJoinAfterMoveJoints() -- clear the JointsService cache return end end @@ -1891,14 +1894,14 @@ function RbxStamper.SetupStamperDragger( hitFace = modelTargetSurface( stampData.CurrentParts, mouse.Hit.p, - workspace.CurrentCamera.CoordinateFrame.p + (workspace.CurrentCamera :: Camera).CoordinateFrame.p ) -- are we stamping WITH an unstampable surface? for bf in string.gmatch(myBreakingFaces, "[^,]+") do if hitFace == tonumber(bf) then unstampableSurface = true - game.JointsService:ClearJoinAfterMoveJoints() -- clear the JointsService cache + JointsService:ClearJoinAfterMoveJoints() -- clear the JointsService cache return end end @@ -1910,7 +1913,7 @@ function RbxStamper.SetupStamperDragger( -- to show joints during the mouse move unstampableSurface = false - game.JointsService:SetJoinAfterMoveInstance(stampData.CurrentParts) + JointsService:SetJoinAfterMoveInstance(stampData.CurrentParts) -- most common mouse inactive error occurs here, so check mouse active one more time in a pcall local ok = pcall(function() @@ -1919,7 +1922,7 @@ function RbxStamper.SetupStamperDragger( and not mouse.Target.Parent:FindFirstChild "RobloxModel" end) if not ok then - game.JointsService:ClearJoinAfterMoveJoints() + JointsService:ClearJoinAfterMoveJoints() mouse = nil error "Error: RbxStamper.DoStamperMouseMove Mouse is nil on second check" return @@ -1930,11 +1933,11 @@ function RbxStamper.SetupStamperDragger( and mouse.Target and mouse.Target.Parent:FindFirstChild "RobloxModel" == nil then - game.JointsService:SetJoinAfterMoveTarget(mouse.Target) + JointsService:SetJoinAfterMoveTarget(mouse.Target) else - game.JointsService:SetJoinAfterMoveTarget(nil) + JointsService:SetJoinAfterMoveTarget(nil) end - game.JointsService:ShowPermissibleJoints() + JointsService:ShowPermissibleJoints() -- here we allow for a line of high-scalability parts if @@ -2214,7 +2217,7 @@ function RbxStamper.SetupStamperDragger( end -- to show joints during the mouse move - game.JointsService:SetJoinAfterMoveInstance(stampData.CurrentParts) + JointsService:SetJoinAfterMoveInstance(stampData.CurrentParts) return clone, parts end @@ -2377,11 +2380,11 @@ function RbxStamper.SetupStamperDragger( -- something will be stamped! so set the "StampedSomething" toggle to true if game:FindFirstChild "Players" - and game.Players.LocalPlayer - and game.Players.LocalPlayer.Character + and Players.LocalPlayer + and Players.LocalPlayer.Character then local stampTracker = - game.Players.LocalPlayer.Character:FindFirstChild "StampTracker" + Players.LocalPlayer.Character:FindFirstChild "StampTracker" if stampTracker and not stampTracker.Value then stampTracker.Value = true end @@ -2534,8 +2537,8 @@ function RbxStamper.SetupStamperDragger( end local function getPlayer() - if game:FindFirstChild "Players" and game.Players.LocalPlayer then - return game.Players.LocalPlayer + if game:FindFirstChild "Players" and Players.LocalPlayer then + return Players.LocalPlayer end return nil end @@ -2575,9 +2578,9 @@ function RbxStamper.SetupStamperDragger( if playerNameTag and game:FindFirstChild "Players" - and game.Players.LocalPlayer + and Players.LocalPlayer then - tempPlayerValue = game.Players.LocalPlayer + tempPlayerValue = Players.LocalPlayer if tempPlayerValue then playerNameTag.Value = tempPlayerValue.Name end @@ -2611,7 +2614,7 @@ function RbxStamper.SetupStamperDragger( -- make sure all the joints are activated before restoring anchor states -- if not createJoints then - game.JointsService:CreateJoinAfterMoveJoints() + JointsService:CreateJoinAfterMoveJoints() -- end -- Restore the original properties for all parts being stamped @@ -2702,7 +2705,7 @@ function RbxStamper.SetupStamperDragger( resetHighScalabilityLine() - game.JointsService:ClearJoinAfterMoveJoints() + JointsService:ClearJoinAfterMoveJoints() end local function prepareUnjoinableSurfaces(modelCFrame, parts, whichSurface) @@ -2815,11 +2818,11 @@ function RbxStamper.SetupStamperDragger( mouseTarget and mouseTarget.Parent:FindFirstChild "RobloxModel" == nil then - game.JointsService:SetJoinAfterMoveTarget(mouseTarget) + JointsService:SetJoinAfterMoveTarget(mouseTarget) else - game.JointsService:SetJoinAfterMoveTarget(nil) + JointsService:SetJoinAfterMoveTarget(nil) end - game.JointsService:ShowPermissibleJoints() + JointsService:ShowPermissibleJoints() for _, object in pairs(stampData.DisabledScripts) do if object.Name == "GhostRemovalScript" then @@ -2905,6 +2908,7 @@ function RbxStamper.SetupStamperDragger( return nil end resetStamperState(newStampModel) + return -- bruh end function control.ReloadModel() -- will automatically set stamper to get a new model of current model and start stamping with new model @@ -2945,7 +2949,7 @@ function RbxStamper.SetupStamperDragger( keyCon:disconnect() end - game.JointsService:ClearJoinAfterMoveJoints() + JointsService:ClearJoinAfterMoveJoints() if adorn then adorn:Destroy() diff --git a/luau/89449008.luau b/luau/89449008.luau index efe01e9..d6b13b0 100644 --- a/luau/89449008.luau +++ b/luau/89449008.luau @@ -1,6 +1,8 @@ -- CoreGui.RobloxGui.Backpack.CoreScripts/BackpackScripts/Back (1?) print "[Mercury]: Loaded corescript 89449008" +local Players = game:GetService "Players" +local StarterGui = game:GetService "StarterGui" local UserInputService = game:GetService "UserInputService" local News = require "../Modules/New" @@ -30,8 +32,8 @@ local function IsTouchDevice() end waitForChild(game, "Players") -waitForProperty(game.Players, "LocalPlayer") -local player = game.Players.LocalPlayer +waitForProperty(Players, "LocalPlayer") +local player = Players.LocalPlayer local RbxGui, _ = LoadLibrary "RbxGui" if not RbxGui then @@ -69,10 +71,10 @@ local currentLoadout = waitForChild(backpack.Parent, "CurrentLoadout") local grid = waitForChild(backpack.Gear, "GearGrid") local gearButton = waitForChild(grid, "GearButton") -local swapSlot = waitForChild(script.Parent, "SwapSlot") +local swapSlot = waitForChild(backpack, "SwapSlot") local backpackManager = - waitForChild(script.Parent, "CoreScripts/BackpackScripts/BackpackManager") + waitForChild(backpack, "CoreScripts/BackpackScripts/BackpackManager") local backpackOpenEvent = waitForChild(backpackManager, "BackpackOpenEvent") local backpackCloseEvent = waitForChild(backpackManager, "BackpackCloseEvent") local tabClickedEvent = waitForChild(backpackManager, "TabClickedEvent") @@ -741,14 +743,14 @@ local function setupCharacterConnections() if backpackAddCon then backpackAddCon:disconnect() end - backpackAddCon = game.Players.LocalPlayer.Backpack.ChildAdded:connect( + backpackAddCon = Players.LocalPlayer.Backpack.ChildAdded:connect( function(child) addToGrid(child) end ) -- make sure we get all the children - local backpackChildren = game.Players.LocalPlayer.Backpack:GetChildren() + local backpackChildren = Players.LocalPlayer.Backpack:GetChildren() for i = 1, #backpackChildren do addToGrid(backpackChildren[i]) end @@ -756,7 +758,7 @@ local function setupCharacterConnections() if characterChildAddedCon then characterChildAddedCon:disconnect() end - characterChildAddedCon = game.Players.LocalPlayer.Character.ChildAdded:connect( + characterChildAddedCon = Players.LocalPlayer.Character.ChildAdded:connect( function(child) addToGrid(child) updateGridActive() @@ -766,7 +768,7 @@ local function setupCharacterConnections() if characterChildRemovedCon then characterChildRemovedCon:disconnect() end - characterChildRemovedCon = game.Players.LocalPlayer.Character.ChildRemoved:connect( + characterChildRemovedCon = Players.LocalPlayer.Character.ChildRemoved:connect( function(_) updateGridActive() end @@ -934,7 +936,7 @@ player.ChildAdded:connect(function(child) if backpackAddCon then backpackAddCon:disconnect() end - backpackAddCon = game.Players.LocalPlayer.Backpack.ChildAdded:connect( + backpackAddCon = Players.LocalPlayer.Backpack.ChildAdded:connect( function(child2) addToGrid(child2) end @@ -967,9 +969,9 @@ end pcall(function() coreGuiChanged( Enum.CoreGuiType.Backpack, - game.StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.Backpack) + StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.Backpack) ) - game.StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged) + StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged) end) resize() @@ -985,11 +987,11 @@ if not backpack.Visible then end -- make sure that inventory is listening to gear reparenting -if characterChildAddedCon == nil and game.Players.LocalPlayer.Character then +if characterChildAddedCon == nil and Players.LocalPlayer.Character then setupCharacterConnections() end if not backpackAddCon then - backpackAddCon = game.Players.LocalPlayer.Backpack.ChildAdded:connect( + backpackAddCon = Players.LocalPlayer.Backpack.ChildAdded:connect( function(child) addToGrid(child) end diff --git a/luau/89449093.luau b/luau/89449093.luau index f57c280..a140b27 100644 --- a/luau/89449093.luau +++ b/luau/89449093.luau @@ -1,20 +1,28 @@ +--!strict -- CoreGui.RobloxGui.Backpack.CoreScripts/BackpackScripts/Back (2?) print "[Mercury]: Loaded corescript 89449093" +local CoreGui = game:GetService "CoreGui" +local GuiService = game:GetService "GuiService" +local Players = game:GetService "Players" +local StarterGui = game:GetService "StarterGui" + local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate - -local GuiService = game:GetService "GuiService" +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path -- basic functions -local function waitForChild(instance, name) - while not instance:FindFirstChild(name) do +local function waitForChild(instance: Instance, name: string) + local child = instance:FindFirstChild(name) + while not child do instance.ChildAdded:wait() + child = instance:FindFirstChild(name) end - return instance:FindFirstChild(name) + return child :: Instance end -local function waitForProperty(instance, property) +local function waitForProperty(instance: Instance, property: string) while not instance[property] do instance.Changed:wait() end @@ -22,12 +30,12 @@ end -- don't do anything if we are in an empty game waitForChild(game, "Players") -if #game.Players:GetChildren() < 1 then - game.Players.ChildAdded:wait() +if #Players:GetChildren() < 1 then + Players.ChildAdded:wait() end -- make sure everything is loaded in before we do anything -- get our local player -waitForProperty(game.Players, "LocalPlayer") +waitForProperty(Players, "LocalPlayer") ------------------------ Locals ------------------------------ local backpack = script.Parent :: GuiObject @@ -53,8 +61,8 @@ local searchBox = waitForChild(backpack.SearchFrame.SearchBoxFrame, "SearchBox") local searchButton = waitForChild(backpack.SearchFrame, "SearchButton") local resetButton = waitForChild(backpack.SearchFrame, "ResetButton") -local mercuryGui = waitForChild(game.CoreGui, "RobloxGui") -local currentLoadout = waitForChild(mercuryGui, "CurrentLoadout") +local MercuryGui = waitForChild(CoreGui, "RobloxGui") +local currentLoadout = waitForChild(MercuryGui, "CurrentLoadout") local loadoutBackground = waitForChild(currentLoadout, "Background") local canToggle = true @@ -111,15 +119,15 @@ local function initHumanoidDiedConnections() if humanoidDiedCon then humanoidDiedCon:disconnect() end - waitForProperty(game.Players.LocalPlayer, "Character") - local localPlayer = game.Players.LocalPlayer + waitForProperty(Players.LocalPlayer, "Character") + local localPlayer = Players.LocalPlayer waitForChild(localPlayer.Character, "Humanoid") humanoidDiedCon = localPlayer.Character.Humanoid.Died:connect(deactivateBackpack) end local function showBackpack() - game.GuiService:AddCenterDialog( + GuiService:AddCenterDialog( backpack, Enum.CenterDialogType.PlayerInitiatedDialog, function() @@ -152,7 +160,7 @@ local function showBackpack() backpackOpenEvent:Fire(currentTab) canToggle = true readyForNextEvent = true - backpackButton.Image = "http://banland.xyz/asset?id=97644093" + backpackButton.Image = path "asset?id=97644093" backpackButton.Position = UDim2.new(0.5, -60, 1, -backpackSize.Y.Offset - 103) end) @@ -184,13 +192,13 @@ local function hideBackpack() guiTweenSpeed, true, function() - game.GuiService:RemoveCenterDialog(backpack) + GuiService:RemoveCenterDialog(backpack) backpack.Visible = false backpackButton.Selected = false end ) delay(guiTweenSpeed, function() - game.GuiService:RemoveCenterDialog(backpack) + GuiService:RemoveCenterDialog(backpack) backpack.Visible = false backpackButton.Selected = false readyForNextEvent = true @@ -201,8 +209,8 @@ end local function toggleBackpack() if not ( - game.Players.LocalPlayer - and game.Players.LocalPlayer.Character + Players.LocalPlayer + and Players.LocalPlayer.Character and canToggle and readyForNextEvent ) @@ -216,7 +224,7 @@ local function toggleBackpack() if backpackIsOpen then Hydrate(loadoutBackground) { - Image = "http://banland.xyz/asset?id=97623721", + Image = path "asset?id=97623721", Position = UDim2.new(-0.03, 0, -0.17, 0), Size = UDim2.new(1.05, 0, 1.25, 0), ZIndex = 2.0, @@ -228,9 +236,9 @@ local function toggleBackpack() backpackButton.Position = UDim2.new(0.5, -60, 1, -44) loadoutBackground.Visible = false backpackButton.Selected = false - backpackButton.Image = "http://banland.xyz/asset?id=97617958" + backpackButton.Image = path "asset?id=97617958" Hydrate(loadoutBackground) { - Image = "http://banland.xyz/asset?id=96536002", + Image = path "asset?id=96536002", Position = UDim2.new(-0.1, 0, -0.1, 0), Size = UDim2.new(1.2, 0, 1.2, 0), } @@ -353,9 +361,9 @@ publicFunction("BackpackReady", backpackReady) pcall(function() coreGuiChanged( Enum.CoreGuiType.Backpack, - game.StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.Backpack) + StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType.Backpack) ) - game.StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged) + StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged) end) inventoryButton.MouseButton1Click:connect(newTabClicked) @@ -399,11 +407,11 @@ backpackButton.MouseButton1Click:connect(function() toggleBackpack() end) -if game.Players.LocalPlayer.Character then +if Players.LocalPlayer.Character then activateBackpack() end -game.Players.LocalPlayer.CharacterAdded:connect(activateBackpack) +Players.LocalPlayer.CharacterAdded:connect(activateBackpack) -- search functions searchBox.FocusLost:connect(function(enterPressed) diff --git a/luau/97188756.luau b/luau/97188756.luau index 4130b3b..731ff78 100644 --- a/luau/97188756.luau +++ b/luau/97188756.luau @@ -2,10 +2,16 @@ -- CoreGui.RobloxGui.CoreScripts/ChatScript print "[Mercury]: Loaded corescript 97188756" +local CoreGui = game:GetService "CoreGui" +local GuiService = game:GetService "GuiService" +local Players = game:GetService "Players" local RunService = game:GetService "RunService" + local SafeChat = require "../Modules/Safechat.yml" -- THANK YOU DARKLUA local New = require("../Modules/New").New +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path local forceChatGUI = false @@ -17,21 +23,16 @@ local function WaitForChild(parent: Instance, childName) return parent[childName] end -while not game.Players.LocalPlayer do +while not Players.LocalPlayer do RunService.Heartbeat:wait() end -local Player = game.Players.LocalPlayer +local Player = Players.LocalPlayer while not Player.Character do RunService.Heartbeat:wait() end local Camera = workspace.CurrentCamera --- Services -local CoreGui = game:GetService "CoreGui" -local Players = game:GetService "Players" -local GuiService = game:GetService "GuiService" - -- Lua Enums local Enums = {} local EnumName = {} -- used as unique key for enum name @@ -667,7 +668,7 @@ function Chat:CreateGui() New "ImageLabel" { Name = "Background", - Image = "http://banland.xyz/asset?id=97120937", --96551212'; + Image = path "asset?id=97120937", -- 96551212 Size = UDim2.new(1.3, 0, 1.64, 0), Position = UDim2.new(0, 0, 0, 0), BackgroundTransparency = 1, diff --git a/luau/host.luau b/luau/host.luau index d096233..1a7de26 100644 --- a/luau/host.luau +++ b/luau/host.luau @@ -5,7 +5,8 @@ local InsertService = game:GetService "InsertService" local BadgeService = game:GetService "BadgeService" local ScriptContext = game:GetService "ScriptContext" local RunService = game:GetService "RunService" -local ScriptInformationProvider = game:GetService "ScriptInformationProvider" +local ScriptInformationProvider = + game:GetService "ScriptInformationProvider" :: ScriptInformationProvider local ChangeHistoryService = game:GetService "ChangeHistoryService" local ContentProvider = game:GetService "ContentProvider" local Players = game:GetService "Players" @@ -14,36 +15,25 @@ local Visit = game:GetService "Visit" -- establish this peer as the Server local NetworkServer = game:GetService "NetworkServer" --- StartGame -- - RunService:Run() --- REQUIRES: StartGanmeSharedArgs.txt --- REQUIRES: MonitorGameStatus.txt - local url = _BASE_URL -----------------------------------"CUSTOM" SHARED CODE---------------------------------- -pcall(function() - settings().Network.UseInstancePacketCache = true -end) -pcall(function() - settings().Network.UsePhysicsPacketCache = true -end) ---pcall(function() settings()["Task Scheduler"].PriorityMethod = Enum.PriorityMethod.FIFO end) -pcall(function() - settings()["Task Scheduler"].PriorityMethod = - Enum.PriorityMethod.AccumulatedError -end) +settings().Network.UseInstancePacketCache = true +settings().Network.UsePhysicsPacketCache = true +-- pcall(function() +-- settings()["Task Scheduler"].PriorityMethod = Enum.PriorityMethod.FIFO +-- end) +settings()["Task Scheduler"].PriorityMethod = + Enum.PriorityMethod.AccumulatedError --settings().Network.PhysicsSend = 1 -- 1==RoundRobin settings().Network.PhysicsSend = Enum.PhysicsSendMethod.ErrorComputation2 settings().Network.ExperimentalPhysicsEnabled = true settings().Network.WaitingForCharacterLogRate = 100 -pcall(function() - settings().Diagnostics:LegacyScriptMode() -end) +settings().Diagnostics:LegacyScriptMode() -----------------------------------START GAME SHARED SCRIPT------------------------------ @@ -68,14 +58,14 @@ if url ~= nil then BadgeService:SetIsBadgeLegalUrl "" InsertService:SetBaseSetsUrl( - `{url}/Game/Tools/InsertAsset.ashx?nsets=10&type=base` + url .. "/Game/Tools/InsertAsset.ashx?nsets=10&type=base" ) InsertService:SetUserSetsUrl( - `{url}/Game/Tools/InsertAsset.ashx?nsets=20&type=user&userid=%d` + url .. "/Game/Tools/InsertAsset.ashx?nsets=20&type=user&userid=%d" ) - InsertService:SetCollectionUrl(`{url}/Game/Tools/InsertAsset.ashx?sid=%d`) - InsertService:SetAssetUrl(`{url}/asset?id=%d`) - InsertService:SetAssetVersionUrl(`{url}/Asset/?assetversionid=%d`) + InsertService:SetCollectionUrl(url .. "/Game/Tools/InsertAsset.ashx?sid=%d") + InsertService:SetAssetUrl(url .. "/asset?id=%d") + InsertService:SetAssetVersionUrl(url .. "/Asset/?assetversionid=%d") end pcall(function() @@ -101,23 +91,13 @@ end -- Now start the connection NetworkServer:Start(_SERVER_PORT) - Visit:SetPing(_SERVER_PRESENCE_URL, 30) - --- if timeout then --- ScriptContext:SetTimeout(timeout) --- end ScriptContext.ScriptsDisabled = false --- delay(1, function() --- loadfile(`{url}/analytics/GamePerfMonitor.ashx`)(game.JobId, placeId) --- end) - -- yimy stuff -local reset = ";mc" -game.Players.PlayerAdded:connect(function(player) +Players.PlayerAdded:connect(function(player) player.Chatted:connect(function(msg) - if msg == reset and player.Character then + if msg == ";mc" and player.Character then player.Character.Humanoid.Health = 0 end end) diff --git a/luau/join.luau b/luau/join.luau index 529694d..537e01e 100644 --- a/luau/join.luau +++ b/luau/join.luau @@ -8,7 +8,11 @@ local Players = game:GetService "Players" local Client = game:GetService "NetworkClient" local Visit = game:GetService "Visit" -local player, connectionFailed +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path + +local player: Player +local connectionFailed: RBXScriptConnection pcall(function() game:SetPlaceId(_PLACE_ID, false) @@ -41,14 +45,16 @@ print "! Joining game '_PLACE_ID' place _PLACE_ID at _SERVER_ADDRESS" ChangeHistoryService:SetEnabled(false) ContentProvider:SetThreadPool(16) -InsertService:SetBaseSetsUrl "http://banland.xyz/game/tools/insertasset?nsets=10&type=base" -InsertService:SetUserSetsUrl "http://banland.xyz/game/tools/insertasset?nsets=20&type=user&userid=%d" -InsertService:SetCollectionUrl "http://banland.xyz/game/tools/insertasset?sid=%d" -InsertService:SetAssetUrl "http://banland.xyz/asset?id=%d" -InsertService:SetAssetVersionUrl "http://banland.xyz/asset?assetversionid=%d" +InsertService:SetBaseSetsUrl(path "game/tools/insertasset?nsets=10&type=base") +InsertService:SetUserSetsUrl( + path "game/tools/insertasset?nsets=20&type=user&userid=%d" +) +InsertService:SetCollectionUrl(path "game/tools/insertasset?sid=%d") +InsertService:SetAssetUrl(path "asset?id=%d") +InsertService:SetAssetVersionUrl(path "asset?assetversionid=%d") pcall(function() - game:SetCreatorID(_CREATOR_ID, Enum.CreatorType.User) + game:SetCreatorId(_CREATOR_ID, Enum.CreatorType.User) end) -- Bubble chat. This is all-encapsulated to allow us to turn it off with a config setting @@ -56,12 +62,6 @@ pcall(function() Players:SetChatStyle(Enum.ChatStyle.ClassicAndBubble) end) -pcall(function() - if settings().Network.MtuOverride == 0 then - settings().Network.MtuOverride = 1400 - end -end) - -- functions --------------------------------------- local loadingState = 0 local function setLoadingMessage(message: string) @@ -95,16 +95,15 @@ end -- called when the client connection closes local function onDisconnection(_, lostConnection) - if lostConnection then - setMessage "You have lost the connection to the game" - else - setMessage "This game has shut down" - end + setMessage( + lostConnection and "You have lost the connection to the game" + or "This game has shut down" + ) end local function requestCharacter(replicator) -- prepare code for when the Character appears - local connection + local connection: RBXScriptConnection connection = player.Changed:connect(function(property) if property == "Character" then loadingState += 1 @@ -127,11 +126,12 @@ local function requestCharacter(replicator) end -- called when the client connection is established -local function onConnectionAccepted(_, replicator) +local function onConnectionAccepted(_, rep: Instance) + local replicator = rep :: NetworkReplicator local waitingForMarker = true local ok, err = pcall(function() - Visit:SetPing(_PING_URL, 30) + Visit:SetPing("_PING_URL", 30) loadingState += 1 game:SetMessageBrickCount() @@ -139,7 +139,7 @@ local function onConnectionAccepted(_, replicator) replicator.Disconnection:connect(onDisconnection) -- Wait for a marker to return before creating the Player - local marker = replicator:SendMarker() + local marker = replicator:SendMarker() :: NetworkMarker marker.Received:connect(function() waitingForMarker = false @@ -161,8 +161,8 @@ local function onConnectionAccepted(_, replicator) end -- called when the client connection fails -local function onConnectionFailed(_, err) - setMessage(`Failed to connect to the place. (ID={err})`) +local function onConnectionFailed(_, code: number, reason: string) + setMessage(`Failed to connect to the place. (ID {code}, {reason})`) end -- called when the client connection is rejected @@ -185,9 +185,7 @@ end -- main ------------------------------------------------------------ -pcall(function() - settings().Diagnostics:LegacyScriptMode() -end) +settings().Diagnostics:LegacyScriptMode() local ok, err = pcall(function() game:SetRemoteBuildMode(true) @@ -197,28 +195,19 @@ local ok, err = pcall(function() connectionFailed = Client.ConnectionFailed:connect(onConnectionFailed) Client.Ticket = "" - local playerConnectSuccess - playerConnectSuccess, player = pcall(function() - return Client:PlayerConnect( - _USER_ID, - "_SERVER_ADDRESS", - _SERVER_PORT, - 0, - threadSleepTime - ) - end) - if not playerConnectSuccess then - -- Old player connection scheme - player = Players:CreateLocalPlayer(_USER_ID) - Client:Connect("_SERVER_ADDRESS", _SERVER_PORT, 0, threadSleepTime) - end - + player = Client:PlayerConnect( + _USER_ID, + "_SERVER_ADDRESS", + _SERVER_PORT, + 0, + threadSleepTime + ) :: Player player:SetSuperSafeChat(false) pcall(function() player:SetUnder13(false) end) pcall(function() - player:SetMembershipType(Enum.MembershipType._MEMBERSHIP_TYPE) + player:SetMembershipType(_MEMBERSHIP_TYPE) end) pcall(function() player:SetAccountAge(1) @@ -228,7 +217,7 @@ local ok, err = pcall(function() pcall(function() player.Name = [========[_USER_NAME]========] end) - player.CharacterAppearance = _CHAR_APPEARANCE + player.CharacterAppearance = "_CHAR_APPEARANCE" Visit:SetUploadUrl "" end) @@ -240,6 +229,6 @@ pcall(function() game:SetScreenshotInfo "" end) pcall(function() - game:SetVideoInfo 'GamesMercury, video, free game, online virtual world' + game:SetVideoInfo 'GamesMercury, video, free game, online virtual world' end) -- use single quotes here because the video info string may have unescaped double quotes diff --git a/luau/renderAvatar.luau b/luau/renderAvatar.luau index 63330ef..cf7cfb7 100644 --- a/luau/renderAvatar.luau +++ b/luau/renderAvatar.luau @@ -1,7 +1,8 @@ --!strict -- Render script for R6 avatars -local ThumbnailGenerator = game:GetService "ThumbnailGenerator" +local ThumbnailGenerator = + game:GetService "ThumbnailGenerator" :: ThumbnailGenerator local RenderModule = require "../Modules/Render" local SetupAvatar = require "../Modules/Render/SetupAvatar" local Render = RenderModule(_BASE_URL, _PING_URL, _THUMBNAIL_KEY) -- avoid ambiguous syntax after compilation @@ -23,7 +24,7 @@ player.Character.Torso["Right Shoulder"].CurrentAngle = 0 -- Headshot Camera local CameraAngle = player.Character.Head.CFrame local CameraPosition = CameraAngle - + CFrame.Angles(0, math.pi, 0).lookVector.unit * 2.75 + + CFrame.Angles(0, math.pi, 0).lookVector.Unit * 2.75 workspace.CurrentCamera = New "Camera" { Name = "ThumbnailCamera", diff --git a/luau/studio.luau b/luau/studio.luau index a35a78d..ec24521 100644 --- a/luau/studio.luau +++ b/luau/studio.luau @@ -2,28 +2,42 @@ print "[Mercury]: Loaded Studio corescript" local InsertService = game:GetService "InsertService" -local ScriptInformationProvider = game:GetService "ScriptInformationProvider" +local ScriptInformationProvider = + game:GetService "ScriptInformationProvider" :: ScriptInformationProvider local ScriptContext = game:GetService "ScriptContext" +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path + pcall(function() - InsertService:SetFreeModelUrl "http://banland.xyz/game/tools/insertasset?type=fm&q=%s&pg=%d&rs=%d" + InsertService:SetFreeModelUrl( + path "game/tools/insertasset?type=fm&q=%s&pg=%d&rs=%d" + ) end) pcall(function() - InsertService:SetFreeDecalUrl "http://banland.xyz/game/tools/insertasset?type=fd&q=%s&pg=%d&rs=%d" + InsertService:SetFreeDecalUrl( + path "game/tools/insertasset?type=fd&q=%s&pg=%d&rs=%d" + ) end) -ScriptInformationProvider:SetAssetUrl "http://banland.xyz/asset/" -InsertService:SetBaseSetsUrl "http://banland.xyz/game/tools/insertasset?nsets=10&type=base" -InsertService:SetUserSetsUrl "http://banland.xyz/game/tools/insertasset?nsets=20&type=user&userid=%d" -InsertService:SetCollectionUrl "http://banland.xyz/game/tools/insertasset?sid=%d" -InsertService:SetAssetUrl "http://banland.xyz/asset?id=%d" -InsertService:SetAssetVersionUrl "http://banland.xyz/asset/?assetversionid=%d" +ScriptInformationProvider:SetAssetUrl(path "asset/") +InsertService:SetBaseSetsUrl(path "game/tools/insertasset?nsets=10&type=base") +InsertService:SetUserSetsUrl( + path "game/tools/insertasset?nsets=20&type=user&userid=%d" +) +InsertService:SetCollectionUrl(path "game/tools/insertasset?sid=%d") +InsertService:SetAssetUrl(path "asset?id=%d") +InsertService:SetAssetVersionUrl(path "asset/?assetversionid=%d") InsertService:SetTrustLevel(0) -if not pcall(function() - ScriptContext:AddStarterScript(37801172) -end) then +if + not pcall(function() + print "Adding starter script (1)" + ScriptContext:AddStarterScript(37801172) + end) +then pcall(function() + print "Adding starter script (2)" ScriptContext:AddCoreScript(37801172, ScriptContext, "StarterScript") end) end diff --git a/luau/visit.luau b/luau/visit.luau index e2582e9..187b12b 100644 --- a/luau/visit.luau +++ b/luau/visit.luau @@ -4,12 +4,16 @@ local ChangeHistoryService = game:GetService "ChangeHistoryService" local InsertService = game:GetService "InsertService" local Players = game:GetService "Players" local RunService = game:GetService "RunService" -local ScriptInformationProvider = game:GetService "ScriptInformationProvider" -local SocialService = game:GetService "SocialService" +local ScriptInformationProvider = + game:GetService "ScriptInformationProvider" :: ScriptInformationProvider +local SocialService = game:GetService "SocialService" :: SocialService local ContentProvider = game:GetService "ContentProvider" local GamePassService = game:GetService "GamePassService" local Visit = game:GetService "Visit" +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path + local player -- Prepended to Edit.lua and Visit.lua and Studio.lua and PlaySolo.lua-- @@ -23,43 +27,61 @@ local message = Instance.new "Message" message.Parent = workspace message.archivable = false -ScriptInformationProvider:SetAssetUrl "http://banland.xyz/Asset/" +ScriptInformationProvider:SetAssetUrl(path "Asset/") ContentProvider:SetThreadPool(16) pcall(function() - InsertService:SetFreeModelUrl "http://banland.xyz/game/tools/insertasset?type=fm&q=%s&pg=%d&rs=%d" + InsertService:SetFreeModelUrl( + path "game/tools/insertasset?type=fm&q=%s&pg=%d&rs=%d" + ) end) -- Used for free model search (insert tool) pcall(function() - InsertService:SetFreeDecalUrl "http://banland.xyz/game/tools/insertasset?type=fd&q=%s&pg=%d&rs=%d" + InsertService:SetFreeDecalUrl( + path "game/tools/insertasset?type=fd&q=%s&pg=%d&rs=%d" + ) end) -- Used for free decal search (insert tool) settings().Diagnostics:LegacyScriptMode() -InsertService:SetBaseSetsUrl "http://banland.xyz/game/tools/insertasset?nsets=10&type=base" -InsertService:SetUserSetsUrl "http://banland.xyz/game/tools/insertasset?nsets=20&type=user&userid=%d" -InsertService:SetCollectionUrl "http://banland.xyz/game/tools/insertasset?sid=%d" -InsertService:SetAssetUrl "http://banland.xyz/asset?id=%d" -InsertService:SetAssetVersionUrl "http://banland.xyz/Asset/?assetversionid=%d" +InsertService:SetBaseSetsUrl(path "game/tools/insertasset?nsets=10&type=base") +InsertService:SetUserSetsUrl( + path "game/tools/insertasset?nsets=20&type=user&userid=%d" +) +InsertService:SetCollectionUrl(path "game/tools/insertasset?sid=%d") +InsertService:SetAssetUrl(path "asset?id=%d") +InsertService:SetAssetVersionUrl(path "Asset/?assetversionid=%d") pcall(function() - SocialService:SetFriendUrl "http://banland.xyz/Game/LuaWebService/HandleSocialRequest.ashx?method=IsFriendsWith&playerid=%d&userid=%d" + SocialService:SetFriendUrl( + path "Game/LuaWebService/HandleSocialRequest.ashx?method=IsFriendsWith&playerid=%d&userid=%d" + ) end) pcall(function() - SocialService:SetBestFriendUrl "http://banland.xyz/Game/LuaWebService/HandleSocialRequest.ashx?method=IsBestFriendsWith&playerid=%d&userid=%d" + SocialService:SetBestFriendUrl( + path "Game/LuaWebService/HandleSocialRequest.ashx?method=IsBestFriendsWith&playerid=%d&userid=%d" + ) end) pcall(function() - SocialService:SetGroupUrl "http://banland.xyz/Game/LuaWebService/HandleSocialRequest.ashx?method=IsInGroup&playerid=%d&groupid=%d" + SocialService:SetGroupUrl( + path "Game/LuaWebService/HandleSocialRequest.ashx?method=IsInGroup&playerid=%d&groupid=%d" + ) end) pcall(function() - SocialService:SetGroupRankUrl "http://banland.xyz/Game/LuaWebService/HandleSocialRequest.ashx?method=GetGroupRank&playerid=%d&groupid=%d" + SocialService:SetGroupRankUrl( + path "Game/LuaWebService/HandleSocialRequest.ashx?method=GetGroupRank&playerid=%d&groupid=%d" + ) end) pcall(function() - SocialService:SetGroupRoleUrl "http://banland.xyz/Game/LuaWebService/HandleSocialRequest.ashx?method=GetGroupRole&playerid=%d&groupid=%d" + SocialService:SetGroupRoleUrl( + path "Game/LuaWebService/HandleSocialRequest.ashx?method=GetGroupRole&playerid=%d&groupid=%d" + ) end) pcall(function() - GamePassService:SetPlayerHasPassUrl "http://banland.xyz/Game/GamePass/GamePassHandler.ashx?Action=HasPass&UserID=%d&PassID=%d" + GamePassService:SetPlayerHasPassUrl( + path "Game/GamePass/GamePassHandler.ashx?Action=HasPass&UserID=%d&PassID=%d" + ) end) pcall(function() - game:SetCreatorID(0, Enum.CreatorType.User) + game:SetCreatorId(0, Enum.CreatorType.User) end) pcall(function() @@ -79,7 +101,9 @@ end) ChangeHistoryService:SetEnabled(false) pcall(function() - Players:SetBuildUserPermissionsUrl "http://banland.xyz/Game/BuildActionPermissionCheck.ashx?assetId=0&userId=%d&isSolo=true" + Players:SetBuildUserPermissionsUrl( + path "Game/BuildActionPermissionCheck.ashx?assetId=0&userId=%d&isSolo=true" + ) end) workspace:SetPhysicsThrottleEnabled(true) @@ -101,7 +125,7 @@ local ok, err = pcall(function() player.CharacterAppearance = "" local propExists, canAutoLoadChar = false, false propExists = pcall(function() - canAutoLoadChar = game.Players.CharacterAutoLoads + canAutoLoadChar = Players.CharacterAutoLoads end) if (propExists and canAutoLoadChar) or not propExists then diff --git a/terrain plugins/00 - terrain.luau b/terrain plugins/00 - terrain.luau index 8a04273..00ac835 100644 --- a/terrain plugins/00 - terrain.luau +++ b/terrain plugins/00 - terrain.luau @@ -20,10 +20,13 @@ local on = false local On, Off -local plugin = PluginManager():CreatePlugin() -local toolbar = plugin:CreateToolbar "Terrain" -local toolbarbutton = - toolbar:CreateButton("Generator", "Terrain Generator", "terrain.png") +local plugin = PluginManager():CreatePlugin() :: Plugin +local toolbar = plugin:CreateToolbar "Terrain" :: Toolbar +local toolbarbutton = toolbar:CreateButton( + "Generator", + "Terrain Generator", + "terrain.png" +) :: Button toolbarbutton.Click:connect(function() if on then Off() @@ -51,8 +54,8 @@ function TerrainOptions.Create() setmetatable(options, TerrainOptions) -- Offset to create terrain at. - options.xpos = 0 - options.zpos = 0 + options.Xpos = 0 + options.Zpos = 0 -- X width options.width = 512 @@ -110,7 +113,7 @@ end -- -- Return: -- Value is a new terrain options set with the old terrain options data. -function TerrainOptions:Clone(_) +function TerrainOptions:Clone() return CopyTable(self) end @@ -236,9 +239,9 @@ function Highlighter.Create(_, ID, color) highlighter.width = 0 highlighter.length = 0 - highlighter.x = 0 - highlighter.y = 0 - highlighter.z = 0 + highlighter.X = 0 + highlighter.Y = 0 + highlighter.Z = 0 -- Create the part that the highlighter will be attached to. highlighter.selectionPart = New "Part" { @@ -282,24 +285,24 @@ function Highlighter:UpdatePosition(cellPos: Vector3) local regionToSelect - self.x = cellPos.x - self.y = cellPos.y - self.z = cellPos.z + self.X = cellPos.X + self.Y = cellPos.Y + self.Z = cellPos.Z local width, length, height = self.width :: number, self.length :: number, self.height :: number local lowVec = CellCenterToWorld( c, - cellPos.x - width / 2, - cellPos.y - 1, - cellPos.z - length / 2 + cellPos.X - width / 2, + cellPos.Y - 1, + cellPos.Z - length / 2 ) local highVec = CellCenterToWorld( c, - cellPos.x + width / 2, - cellPos.y + height, - cellPos.z + length / 2 + cellPos.X + width / 2, + cellPos.Y + height, + cellPos.Z + length / 2 ) regionToSelect = Region3.new(lowVec, highVec) @@ -320,7 +323,7 @@ function Highlighter:UpdateDimensions( self.length = length self.width = width self.height = height - self:UpdatePosition(Vector3.new(self.x, self.y, self.z)) + self:UpdatePosition(Vector3.new(self.X, self.Y, self.Z)) end -- Create a standardized slider. @@ -397,7 +400,7 @@ local function LoadProgressBar(text) cancelValues.bindForCancel.Event:connect(function(_) cancelValues.cancelActions = true -- Set the flag that everything should stop. - coroutine.yield() + coroutine.Yield() end) end @@ -428,13 +431,13 @@ local _, offsetXSliderPosition = CreateStandardSlider( UDim2.new(0, 10, 0.5, -2), 128, function(offsetXSliderPosition2) - terrainOptions.xpos = (offsetXSliderPosition2.Value - 1) * 4 - 252 - offsetXLabel.Text = "X-Offset: " .. terrainOptions.xpos + terrainOptions.Xpos = (offsetXSliderPosition2.Value - 1) * 4 - 252 + offsetXLabel.Text = "X-Offset: " .. terrainOptions.Xpos end, nil, terrainFrame ) -offsetXSliderPosition.Value = (terrainOptions.xpos + 252) / 4 + 1 +offsetXSliderPosition.Value = (terrainOptions.Xpos + 252) / 4 + 1 -- Slider for controlling the z offset to generate terrain at. local offsetZLabel = CreateStandardLabel( @@ -450,13 +453,13 @@ local _, offsetZSliderPosition = CreateStandardSlider( UDim2.new(0, 10, 0.5, -2), 128, function(offsetZSliderPosition2) - terrainOptions.zpos = (offsetZSliderPosition2.Value - 1) * 4 - 252 - offsetZLabel.Text = "Z-Offset: " .. terrainOptions.zpos + terrainOptions.Zpos = (offsetZSliderPosition2.Value - 1) * 4 - 252 + offsetZLabel.Text = "Z-Offset: " .. terrainOptions.Zpos end, nil, terrainFrame ) -offsetZSliderPosition.Value = (terrainOptions.zpos + 252) / 4 + 1 +offsetZSliderPosition.Value = (terrainOptions.Zpos + 252) / 4 + 1 ----------------------- --FUNCTION DEFINITIONS- @@ -479,7 +482,7 @@ end -- makes a heightmap for a layer of mountains (width x depth) -- with a width frequency wf and depthfrequency df (width should be divisible by wf, depth should be divisible by df) (for unsquished results, width/wf = depth/df) -- with a range of amplitudes between 0 and a -local function mountLayer(width, depth, wf, df, a) +local function mountLayer(width: number, depth: number, wf, df, a: number) local heightmap = {} for i = 0, width - 1 do heightmap[i] = {} @@ -570,8 +573,14 @@ end -- Set the camera to look at the terrain from a distance so that all terrain will be in view. -- centerX, centerZ - Center coordinate of land. This doesn't take into account clipping. -- length, width - Land dimensions. -local function SetCamera(centerX, centerZ, length, width, height) - local currCamera = workspace.CurrentCamera +local function SetCamera( + centerX: number, + centerZ: number, + length: number, + width: number, + height: number +) + local currCamera = workspace.CurrentCamera :: Camera local cameraPos = Vector3.new(0, 400, 1600) local cameraFocus = Vector3.new(0, height * 4, 0) @@ -625,15 +634,15 @@ local function GenerateTerrain() --Generate Terrain -- offset terrain additionally by whatever the smallest cell is - --xpos2 = generateOptions.xpos + workspace.Terrain.MaxExtents.Min.X - --zpos2 = generateOptions.zpos + workspace.Terrain.MaxExtents.Min.Z - local xpos2 = generateOptions.xpos - generateOptions.width / 2 - local zpos2 = generateOptions.zpos - generateOptions.length / 2 + --xpos2 = generateOptions.Xpos + workspace.Terrain.MaxExtents.Min.X + --zpos2 = generateOptions.Zpos + workspace.Terrain.MaxExtents.Min.Z + local xpos2 = generateOptions.Xpos - generateOptions.width / 2 + local zpos2 = generateOptions.Zpos - generateOptions.length / 2 -- Reposition to get a good view. SetCamera( - generateOptions.xpos, - generateOptions.zpos, + generateOptions.Xpos, + generateOptions.Zpos, generateOptions.length, generateOptions.width, math.max(generateOptions.baseHeight, generateOptions.a / 2) diff --git a/terrain plugins/01 - builder.luau b/terrain plugins/01 - builder.luau index ee69a37..7e1665d 100644 --- a/terrain plugins/01 - builder.luau +++ b/terrain plugins/01 - builder.luau @@ -1,3 +1,4 @@ +--!strict while not game do wait() end @@ -17,11 +18,11 @@ local on = false local On, Off -local plugin = PluginManager():CreatePlugin() +local plugin = PluginManager():CreatePlugin() :: Plugin local mouse = plugin:GetMouse() -local toolbar = plugin:CreateToolbar "Terrain" -local toolbarbutton = toolbar:CreateButton("Builder", "Builder", "builder.png") +local toolbar = plugin:CreateToolbar "Terrain" :: Toolbar +local toolbarbutton = toolbar:CreateButton("Builder", "Builder", "builder.png") :: Button toolbarbutton.Click:connect(function() if on then Off() @@ -126,7 +127,7 @@ function MouseHighlighter.Create(mouseUse) -- success - Value is true if there was a plane intersection, false if not. -- cellPos - Value is the terrain cell intersection point if there is one, vectorPos if there isn't. function PlaneIntersection(vectorPos) - local currCamera = workspace.CurrentCamera + local currCamera = workspace.CurrentCamera :: Camera local startPos = Vector3.new( currCamera.CoordinateFrame.p.X, currCamera.CoordinateFrame.p.Y, @@ -153,7 +154,7 @@ function MouseHighlighter.Create(mouseUse) -- Update where the highlighter is displayed. -- position - Where to display the highlighter, in world space. - function UpdatePosition(position) + function UpdatePosition(position: Vector3) if not position then return end @@ -162,7 +163,7 @@ function MouseHighlighter.Create(mouseUse) -- Change this gui to be the one you want to use. highlighter.selectionBox.Parent = CoreGui - local vectorPos = Vector3.new(position.x, position.y, position.z) + local vectorPos = Vector3.new(position.X, position.Y, position.Z) local cellPos = WorldToCellPreferEmpty(c, vectorPos) local solidCell = WorldToCellPreferSolid(c, vectorPos) local success = false @@ -179,9 +180,9 @@ function MouseHighlighter.Create(mouseUse) local regionToSelect - local lowVec = CellCenterToWorld(c, cellPos.x, cellPos.y - 1, cellPos.z) + local lowVec = CellCenterToWorld(c, cellPos.X, cellPos.Y - 1, cellPos.Z) local highVec = - CellCenterToWorld(c, cellPos.x, cellPos.y + 1, cellPos.z) + CellCenterToWorld(c, cellPos.X, cellPos.Y + 1, cellPos.Z) regionToSelect = Region3.new(lowVec, highVec) highlighter.selectionPart.Size = regionToSelect.Size @@ -192,12 +193,12 @@ function MouseHighlighter.Create(mouseUse) if nil == highlighter.lastUsedPoint then highlighter.lastUsedPoint = WorldToCellPreferEmpty( c, - Vector3.new(mouseH.Hit.x, mouseH.Hit.y, mouseH.Hit.z) + Vector3.new(mouseH.Hit.X, mouseH.Hit.Y, mouseH.Hit.Z) ) else cellPos = WorldToCellPreferEmpty( c, - Vector3.new(mouseH.Hit.x, mouseH.Hit.y, mouseH.Hit.z) + Vector3.new(mouseH.Hit.X, mouseH.Hit.Y, mouseH.Hit.Z) ) end end @@ -286,18 +287,18 @@ local function onClicked() local cellPos = WorldToCellPreferEmpty( c, - Vector3.new(mouse.Hit.x, mouse.Hit.y, mouse.Hit.z) + Vector3.new(mouse.Hit.X, mouse.Hit.Y, mouse.Hit.Z) ) - local x = cellPos.x - local y = cellPos.y - local z = cellPos.z + local x = cellPos.X + local y = cellPos.Y + local z = cellPos.Z local solidCellPos = WorldToCellPreferSolid( c, - Vector3.new(mouse.Hit.x, mouse.Hit.y, mouse.Hit.z) + Vector3.new(mouse.Hit.X, mouse.Hit.Y, mouse.Hit.Z) ) - local celMat = GetCell(c, solidCellPos.x, solidCellPos.y, solidCellPos.z) + local celMat = GetCell(c, solidCellPos.X, solidCellPos.Y, solidCellPos.Z) local success = false if celMat.Value > 0 then @@ -312,15 +313,15 @@ local function onClicked() end success, cellPos = PlaneIntersection( - Vector3.new(mouse.Hit.x, mouse.Hit.y, mouse.Hit.z) + Vector3.new(mouse.Hit.X, mouse.Hit.Y, mouse.Hit.Z) ) if not success then cellPos = solidCellPos end - x = cellPos.x - y = cellPos.y - z = cellPos.z + x = cellPos.X + y = cellPos.Y + z = cellPos.Z end if selectionProps.isWater and 17 == selectionProps.terrainMaterial then diff --git a/terrain plugins/02 - remover.luau b/terrain plugins/02 - remover.luau index 76de0f1..8d39c57 100644 --- a/terrain plugins/02 - remover.luau +++ b/terrain plugins/02 - remover.luau @@ -1,3 +1,4 @@ +--!strict while not game do wait() end @@ -20,12 +21,12 @@ local On, Off --------------- --PLUGIN SETUP- --------------- -local plugin = PluginManager():CreatePlugin() +local plugin = PluginManager():CreatePlugin() :: Plugin local mouse = plugin:GetMouse() -local toolbar = plugin:CreateToolbar "Terrain" +local toolbar = plugin:CreateToolbar "Terrain" :: Toolbar local toolbarbutton = - toolbar:CreateButton("Remover", "Remover", "destroyer.png") + toolbar:CreateButton("Remover", "Remover", "destroyer.png") :: Button toolbarbutton.Click:connect(function() if on then Off() @@ -102,14 +103,14 @@ function MouseHighlighter.Create(mouseUse) -- Change this gui to be the one you want to use. highlighter.selectionBox.Parent = CoreGui - local vectorPos = Vector3.new(position.x, position.y, position.z) + local vectorPos = Vector3.new(position.X, position.Y, position.Z) local cellPos = WorldToCellPreferSolid(c, vectorPos) local regionToSelect - local lowVec = CellCenterToWorld(c, cellPos.x, cellPos.y - 1, cellPos.z) + local lowVec = CellCenterToWorld(c, cellPos.X, cellPos.Y - 1, cellPos.Z) local highVec = - CellCenterToWorld(c, cellPos.x, cellPos.y + 1, cellPos.z) + CellCenterToWorld(c, cellPos.X, cellPos.Y + 1, cellPos.Z) regionToSelect = Region3.new(lowVec, highVec) highlighter.selectionPart.Size = regionToSelect.Size @@ -121,12 +122,12 @@ function MouseHighlighter.Create(mouseUse) elseif not highlighter.lastUsedPoint then highlighter.lastUsedPoint = WorldToCellPreferSolid( c, - Vector3.new(mouse2.Hit.x, mouse2.Hit.y, mouse2.Hit.z) + Vector3.new(mouse2.Hit.X, mouse2.Hit.Y, mouse2.Hit.Z) ) else cellPos = WorldToCellPreferSolid( c, - Vector3.new(mouse2.Hit.x, mouse2.Hit.y, mouse2.Hit.z) + Vector3.new(mouse2.Hit.X, mouse2.Hit.Y, mouse2.Hit.Z) ) -- holdChange = cellPos - highlighter.lastUsedPoint -- ? @@ -240,11 +241,11 @@ local function onClicked() end local cellPos = WorldToCellPreferSolid( c, - Vector3.new(mouse.Hit.x, mouse.Hit.y, mouse.Hit.z) + Vector3.new(mouse.Hit.X, mouse.Hit.Y, mouse.Hit.Z) ) - local x = cellPos.x - local y = cellPos.y - local z = cellPos.z + local x = cellPos.X + local y = cellPos.Y + local z = cellPos.Z SetCell(c, x, y, z, 0, 0, 0) diff --git a/terrain plugins/03 - elevation.luau b/terrain plugins/03 - elevation.luau index 616c5cd..b7a423c 100644 --- a/terrain plugins/03 - elevation.luau +++ b/terrain plugins/03 - elevation.luau @@ -17,15 +17,15 @@ local on = false local On, Off -local plugin = PluginManager():CreatePlugin() +local plugin = PluginManager():CreatePlugin() :: Plugin local mouse = plugin:GetMouse() -local toolbar = plugin:CreateToolbar "Terrain" +local toolbar = plugin:CreateToolbar "Terrain" :: Toolbar local toolbarbutton = toolbar:CreateButton( "Elevation Adjuster", "Elevation Adjuster", "elevation.png" -) +) :: Button toolbarbutton.Click:connect(function() if on then Off() @@ -121,7 +121,7 @@ function MouseHighlighter.Create(mouseUse) -- Update where the highlighter is displayed. -- position - Where to display the highlighter, in world space. - local function UpdatePosition(position) + local function UpdatePosition(position: Vector3) if not position then return end @@ -130,7 +130,7 @@ function MouseHighlighter.Create(mouseUse) -- Change this gui to be the one you want to use. highlighter.selectionBox.Parent = CoreGui - local vectorPos = Vector3.new(position.x, position.y, position.z) + local vectorPos = Vector3.new(position.X, position.Y, position.Z) local cellPos = WorldToCellPreferEmpty(c, vectorPos) local solidCell = WorldToCellPreferSolid(c, vectorPos) local success = false diff --git a/terrain plugins/04 - brush.luau b/terrain plugins/04 - brush.luau index 1f03b0a..02702c1 100644 --- a/terrain plugins/04 - brush.luau +++ b/terrain plugins/04 - brush.luau @@ -16,10 +16,11 @@ local on = false local On, Off -local this = PluginManager():CreatePlugin() +local this = PluginManager():CreatePlugin() :: Plugin -local toolbar = this:CreateToolbar "Terrain" -local toolbarbutton = toolbar:CreateButton("Brush", "Brush", "brush.png") +local toolbar = this:CreateToolbar "Terrain" :: Toolbar +local toolbarbutton = + toolbar:CreateButton("Brush", "Brush", "brush.png") :: Button toolbarbutton.Click:connect(function() if on then Off() @@ -292,9 +293,9 @@ function doFillCells(position, mouseDrag, needsCellPos) local timeBetweenFills = tick() - lastCellFillTime local totalDragPixels = math.abs(mouseDrag.x) + math.abs(mouseDrag.y) local editDistance = ( - workspace.CurrentCamera.CoordinateFrame.p + (workspace.CurrentCamera :: Camera).CoordinateFrame.p - Vector3.new(position.x, position.y, position.z) - ).magnitude + ).Magnitude if timeBetweenFills <= 0.05 then if editDistance * totalDragPixels < 450 then diff --git a/terrain plugins/06 - craters.luau b/terrain plugins/06 - craters.luau index 4984d06..401fccb 100644 --- a/terrain plugins/06 - craters.luau +++ b/terrain plugins/06 - craters.luau @@ -14,11 +14,11 @@ local on = false local On, Off -local this = PluginManager():CreatePlugin() +local this = PluginManager():CreatePlugin() :: Plugin local mouse = this:GetMouse() -local toolbar = this:CreateToolbar "Terrain" -local toolbarbutton = toolbar:CreateButton("Crater", "Crater", "craters.png") +local toolbar = this:CreateToolbar "Terrain" :: Toolbar +local toolbarbutton = toolbar:CreateButton("Crater", "Crater", "craters.png") :: Button toolbarbutton.Click:connect(function() if on then Off() diff --git a/terrain plugins/08 - roads.luau b/terrain plugins/08 - roads.luau index 7e8d298..43b712e 100644 --- a/terrain plugins/08 - roads.luau +++ b/terrain plugins/08 - roads.luau @@ -13,10 +13,10 @@ local on = false local On, Off -local this = PluginManager():CreatePlugin() +local this = PluginManager():CreatePlugin() :: Plugin local mouse = this:GetMouse() -local toolbar = this:CreateToolbar "Terrain" -local toolbarbutton = toolbar:CreateButton("Roads", "Roads", "roads.png") +local toolbar = this:CreateToolbar "Terrain" :: Toolbar +local toolbarbutton = toolbar:CreateButton("Roads", "Roads", "roads.png") :: Button toolbarbutton.Click:connect(function() if on then Off() diff --git a/terrain plugins/09 - materialpaint.luau b/terrain plugins/09 - materialpaint.luau index 7ade732..227c618 100644 --- a/terrain plugins/09 - materialpaint.luau +++ b/terrain plugins/09 - materialpaint.luau @@ -1,3 +1,4 @@ +--!strict while not game do wait() end @@ -18,7 +19,7 @@ local on = false local On, Off local mouseDown, mouseUp, mouseMove -local this = PluginManager():CreatePlugin() +local this = PluginManager():CreatePlugin() :: Plugin local mouse = this:GetMouse() mouse.Button1Down:connect(function() mouseDown(mouse) @@ -30,12 +31,12 @@ mouse.Move:connect(function() mouseMove(mouse) end) -local toolbar = this:CreateToolbar "Terrain" +local toolbar = this:CreateToolbar "Terrain" :: Toolbar local toolbarbutton = toolbar:CreateButton( "Material Brush", "Material Brush", "materialBrush.png" -) +) :: Button toolbarbutton.Click:connect(function() if on then Off() @@ -50,13 +51,13 @@ workspace:WaitForChild "Terrain" ----------------------------- --LOCAL FUNCTION DEFINITIONS- ----------------------------- -local c = workspace.Terrain -local SetCell = c.SetCell -local SetWaterCell = c.SetWaterCell +local Terrain = workspace.Terrain +local SetCell = Terrain.SetCell +local SetWaterCell = Terrain.SetWaterCell -- local GetWaterCell = c.GetWaterCell -local GetCell = c.GetCell -local WorldToCellPreferSolid = c.WorldToCellPreferSolid -local CellCenterToWorld = c.CellCenterToWorld +local GetCell = Terrain.GetCell +local WorldToCellPreferSolid = Terrain.WorldToCellPreferSolid +local CellCenterToWorld = Terrain.CellCenterToWorld local waterMaterial = 17 local brushTypes = { "Circular", "Square" } @@ -92,7 +93,7 @@ function paintWaterfall(setCells) end for i = 1, #setCells do SetWaterCell( - c, + Terrain, setCells[i].xPos, setCells[i].yPos, setCells[i].zPos, @@ -106,7 +107,7 @@ end local function getSquareCell(x: number, y: number, z: number) -- local tempCellPos = Vector3.new(x, y, z) - local oldMaterial, oldType, oldOrientation = GetCell(c, x, y, z) + local oldMaterial, oldType, oldOrientation = GetCell(Terrain, x, y, z) if oldMaterial.Value <= 0 then return nil end @@ -119,15 +120,15 @@ local function getSquareCell(x: number, y: number, z: number) } end -local function getSquare(cellPos) +local function getSquare(cellPos: Vector3) local setCells = {} - local finalX = cellPos.x + radius - 1 - local finalZ = cellPos.z + radius - 1 - local finalY = cellPos.y + radius - 1 + local finalX = cellPos.X + radius - 1 + local finalY = cellPos.Y + radius - 1 + local finalZ = cellPos.Z + radius - 1 - for x = cellPos.x - radius + 1, finalX do - for z = cellPos.z - radius + 1, finalZ do - for y = cellPos.y - radius + 1, finalY do + for x = cellPos.X - radius + 1, finalX do + for y = cellPos.Y - radius + 1, finalY do + for z = cellPos.Z - radius + 1, finalZ do table.insert(setCells, getSquareCell(x, y, z)) end end @@ -149,7 +150,7 @@ local function getCircularCell( if distSq >= radiusSquared then return nil end - local oldMaterial, oldType, oldOrientation = GetCell(c, x, y, z) + local oldMaterial, oldType, oldOrientation = GetCell(Terrain, x, y, z) if oldMaterial.Value <= 0 then return nil end @@ -162,15 +163,16 @@ local function getCircularCell( } end -local function getCircular(cellPos) +local function getCircular(cellPos: Vector3) local setCells = {} - local finalX = cellPos.x + radius - local finalZ = cellPos.z + radius - local finalY = cellPos.y + radius + -- whoever originally wrote these ordered (X, Z, Y) is a psychopath - Heliodex + local finalX = cellPos.X + radius + local finalY = cellPos.Y + radius + local finalZ = cellPos.Z + radius - for x = cellPos.x - radius, finalX do - for z = cellPos.z - radius, finalZ do - for y = cellPos.y - radius, finalY do + for x = cellPos.X - radius, finalX do + for y = cellPos.Y - radius, finalY do + for z = cellPos.Z - radius, finalZ do table.insert( setCells, getCircularCell(x, y, z, cellPos, radius * radius) @@ -182,8 +184,8 @@ local function getCircular(cellPos) return setCells end -local function getAffectedCells(startPos) - if startPos and c then +local function getAffectedCells(startPos: Vector3) + if startPos and Terrain then if brushType == "Circular" then return getCircular(startPos) elseif brushType == "Square" then @@ -194,13 +196,13 @@ local function getAffectedCells(startPos) return {} end -local function directionIsDown(fromCell, toCell) +local function directionIsDown(fromCell: Vector3, toCell: Vector3) if not toCell then return false end if toCell and fromCell then - local direction = (toCell - fromCell).unit + local direction = (toCell - fromCell).Unit local absX, absY, absZ = math.abs(direction.X), math.abs(direction.Y), math.abs(direction.Z) if absY > absX and absY > absZ then @@ -294,7 +296,7 @@ local function setWaterDirection(mouseCellPos, setCells) then if overallDirection.x > 0 then SetWaterCell( - c, + Terrain, setCells[1].xPos, setCells[1].yPos, setCells[1].zPos, @@ -303,7 +305,7 @@ local function setWaterDirection(mouseCellPos, setCells) ) else SetWaterCell( - c, + Terrain, setCells[1].xPos, setCells[1].yPos, setCells[1].zPos, @@ -317,7 +319,7 @@ local function setWaterDirection(mouseCellPos, setCells) then if overallDirection.z > 0 then SetWaterCell( - c, + Terrain, setCells[1].xPos, setCells[1].yPos, setCells[1].zPos, @@ -326,7 +328,7 @@ local function setWaterDirection(mouseCellPos, setCells) ) else SetWaterCell( - c, + Terrain, setCells[1].xPos, setCells[1].yPos, setCells[1].zPos, @@ -340,7 +342,7 @@ local function setWaterDirection(mouseCellPos, setCells) then if overallDirection.y > 0 then SetWaterCell( - c, + Terrain, setCells[1].xPos, setCells[1].yPos, setCells[1].zPos, @@ -349,7 +351,7 @@ local function setWaterDirection(mouseCellPos, setCells) ) else SetWaterCell( - c, + Terrain, setCells[1].xPos, setCells[1].yPos, setCells[1].zPos, @@ -364,7 +366,7 @@ local function setWaterDirection(mouseCellPos, setCells) for i = 1, #setCells do if setCells[i].xPos == initX then SetWaterCell( - c, + Terrain, setCells[i].xPos, setCells[i].yPos, setCells[i].zPos, @@ -373,7 +375,7 @@ local function setWaterDirection(mouseCellPos, setCells) ) elseif setCells[i].xPos == endX then SetWaterCell( - c, + Terrain, setCells[i].xPos, setCells[i].yPos, setCells[i].zPos, @@ -383,7 +385,7 @@ local function setWaterDirection(mouseCellPos, setCells) else if setCells[i].zPos < zMiddle then SetWaterCell( - c, + Terrain, setCells[i].xPos, setCells[i].yPos, setCells[i].zPos, @@ -392,7 +394,7 @@ local function setWaterDirection(mouseCellPos, setCells) ) elseif setCells[i].zPos > zMiddle then SetWaterCell( - c, + Terrain, setCells[i].xPos, setCells[i].yPos, setCells[i].zPos, @@ -402,7 +404,7 @@ local function setWaterDirection(mouseCellPos, setCells) else if setCells[i].xPos < xMiddle then SetWaterCell( - c, + Terrain, setCells[i].xPos, setCells[i].yPos, setCells[i].zPos, @@ -411,7 +413,7 @@ local function setWaterDirection(mouseCellPos, setCells) ) elseif setCells[i].xPos > xMiddle then SetWaterCell( - c, + Terrain, setCells[i].xPos, setCells[i].yPos, setCells[i].zPos, @@ -439,7 +441,7 @@ local function paintWith( end for i = 1, #setCells do SetCell( - c, + Terrain, setCells[i].xPos, setCells[i].yPos, setCells[i].zPos, @@ -453,7 +455,7 @@ local function paintWith( end local function paint(startPos) - if not (startPos and c) then + if not (startPos and Terrain) then return end @@ -474,14 +476,14 @@ local function paint(startPos) end local function calculateRegion(mouseR) - local cellPos = WorldToCellPreferSolid(c, mouseR.Hit.p) + local cellPos = WorldToCellPreferSolid(Terrain, mouseR.Hit.p) local lowVec = Vector3.new(cellPos.x - radius, cellPos.y - radius, cellPos.z - radius) local highVec = Vector3.new(cellPos.x + radius, cellPos.y + radius, cellPos.z + radius) - lowVec = CellCenterToWorld(c, lowVec.x, lowVec.y, lowVec.z) - highVec = CellCenterToWorld(c, highVec.x, highVec.y, highVec.z) + lowVec = CellCenterToWorld(Terrain, lowVec.x, lowVec.y, lowVec.z) + highVec = CellCenterToWorld(Terrain, highVec.x, highVec.y, highVec.z) return Region3.new( lowVec + Vector3.new(2, 2, 2), @@ -494,7 +496,7 @@ local function createSelection(mouseS, massSelection) calculateRegion(mouseS), BrickColor.new "Lime green", massSelection, - game.CoreGui + CoreGui ) end @@ -517,7 +519,7 @@ local function setPositionDirectionality() else for i = 1, #cellsToSet do SetWaterCell( - c, + Terrain, cellsToSet[i].xPos, cellsToSet[i].yPos, cellsToSet[i].zPos, @@ -561,7 +563,7 @@ local function setPositionDirectionality() for i = 1, #cellsToSet do SetWaterCell( - c, + Terrain, cellsToSet[i].xPos, cellsToSet[i].yPos, cellsToSet[i].zPos, @@ -581,7 +583,7 @@ function mouseDown(mouseD) return end - local newCell = WorldToCellPreferSolid(c, mouseD.Hit.p) + local newCell = WorldToCellPreferSolid(Terrain, mouseD.Hit.p) if not newCell then return elseif @@ -607,7 +609,12 @@ function mouseUp(_) lastCell = nil end -local function moveTowardsGoal(direction: string, currPos, goalPos, currCell) +local function moveTowardsGoal( + direction: string, + currPos: number, + goalPos: number, + currCell: Vector3 +) if currPos == goalPos then return currCell end @@ -670,18 +677,18 @@ function mouseMove(mouseM) if not on then return elseif mouseM.Target == workspace.Terrain then - if lastCell == WorldToCellPreferSolid(c, mouseM.Hit.p) then + if lastCell == WorldToCellPreferSolid(Terrain, mouseM.Hit.p) then return end updateSelection(mouseM) - local newCell = WorldToCellPreferSolid(c, mouseM.Hit.p) + local newCell = WorldToCellPreferSolid(Terrain, mouseM.Hit.p) if not dragging then return end -- local painting = true paint(newCell) - if lastCell and newCell and (lastCell - newCell).magnitude > 1 then + if lastCell and newCell and (lastCell - newCell).Magnitude > 1 then paintBetweenPoints(lastCell, newCell) end lastLastCell = lastCell @@ -693,7 +700,7 @@ function mouseMove(mouseM) end function On() - if not c then + if not Terrain then return end this:Activate(true) diff --git a/terrain plugins/10 - stamper.luau b/terrain plugins/10 - stamper.luau index 269182b..ebffe17 100644 --- a/terrain plugins/10 - stamper.luau +++ b/terrain plugins/10 - stamper.luau @@ -1,3 +1,4 @@ +--!strict while not game do wait() end @@ -16,17 +17,17 @@ local on = false local On, Off -local this = PluginManager():CreatePlugin() +local this = PluginManager():CreatePlugin() :: Plugin this.Deactivation:connect(function() Off() end) -local toolbar = this:CreateToolbar "Terrain" +local toolbar = this:CreateToolbar "Terrain" :: Toolbar local toolbarbutton = toolbar:CreateButton( "Stamper", "Part Stamper - Toggle List (Shift + F)", "stamp.png" -) +) :: Button toolbarbutton.Click:connect(function() if on then Off() diff --git a/terrain plugins/11 - floodfill.luau b/terrain plugins/11 - floodfill.luau index a414043..0b6dba6 100644 --- a/terrain plugins/11 - floodfill.luau +++ b/terrain plugins/11 - floodfill.luau @@ -1,3 +1,4 @@ +--!strict while not game do wait() end @@ -11,6 +12,8 @@ local CreateStandardLabel = require "../Modules/Terrain/CreateStandardLabel" local News = require "../Modules/New" local New = News.New local Hydrate = News.Hydrate +local BaseUrl = require "../Modules/BaseUrl" +local path = BaseUrl.path --------------- --PLUGIN SETUP- @@ -21,7 +24,7 @@ local on = false local On, Off local mouseDown, mouseUp -local this = PluginManager():CreatePlugin() +local this = PluginManager():CreatePlugin() :: Plugin local mouse = this:GetMouse() mouse.Button1Down:connect(function() mouseDown(mouse) @@ -30,9 +33,9 @@ mouse.Button1Up:connect(function() mouseUp(mouse) end) -local toolbar = this:CreateToolbar "Terrain" +local toolbar = this:CreateToolbar "Terrain" :: Toolbar local toolbarbutton = - toolbar:CreateButton("Flood Fill", "Flood Fill", "floodFill.png") + toolbar:CreateButton("Flood Fill", "Flood Fill", "floodFill.png") :: Button toolbarbutton.Click:connect(function() if on then Off() @@ -47,12 +50,12 @@ workspace:WaitForChild "Terrain" ----------------------------- --LOCAL FUNCTION DEFINITIONS- ----------------------------- -local c = workspace.Terrain +local Terrain = workspace.Terrain -- local WorldToCellPreferSolid = c.WorldToCellPreferSolid -local WorldToCellPreferEmpty = c.WorldToCellPreferEmpty -local CellCenterToWorld = c.CellCenterToWorld -local GetCell = c.GetCell -local SetCell = c.SetCell +local WorldToCellPreferEmpty = Terrain.WorldToCellPreferEmpty +local CellCenterToWorld = Terrain.CellCenterToWorld +local GetCell = Terrain.GetCell +local SetCell = Terrain.SetCell -- local maxYExtents = c.MaxExtents.Max.Y local emptyMaterial = Enum.CellMaterial.Empty @@ -78,7 +81,7 @@ local currentMaterial = 1 -- load our libraries local RbxGui = LoadLibrary "RbxGui" -- local RbxUtil = LoadLibrary "RbxUtility" -ContentProvider:Preload "http://banland.xyz/asset?id=82741829" +ContentProvider:Preload(path "asset?id=82741829") ------------------------- OBJECT DEFINITIONS --------------------- @@ -168,7 +171,7 @@ function MouseHighlighter.Create(mouseUse) BackgroundTransparency = 1, Size = UDim2.new(1, 0, 1, 0), Position = UDim2.new(-0.35, 0, -0.5, 0), - Image = "http://banland.xyz/asset?id=82741829", + Image = path "asset?id=82741829", Parent = billboardGui, } @@ -245,47 +248,48 @@ function MouseHighlighter.Create(mouseUse) end local vectorPos = Vector3.new(position.x, position.y, position.z) - local cellPos = WorldToCellPreferEmpty(c, vectorPos) + local cellPos = WorldToCellPreferEmpty(Terrain, vectorPos) local regionToSelect - local cellMaterial = GetCell(c, cellPos.x, cellPos.y, cellPos.z) + local cellMaterial = GetCell(Terrain, cellPos.x, cellPos.y, cellPos.z) local y = cellPos.y -- only select empty cells while cellMaterial ~= emptyMaterial do - y = y + 1 - cellMaterial = GetCell(c, cellPos.x, y, cellPos.z) + y += 1 + cellMaterial = GetCell(Terrain, cellPos.x, y, cellPos.z) end cellPos = Vector3.new(cellPos.x, y, cellPos.z) - local lowVec = CellCenterToWorld(c, cellPos.x, cellPos.y - 1, cellPos.z) + local lowVec = + CellCenterToWorld(Terrain, cellPos.x, cellPos.y - 1, cellPos.z) local highVec = - CellCenterToWorld(c, cellPos.x, cellPos.y + 1, cellPos.z) + CellCenterToWorld(Terrain, cellPos.x, cellPos.y + 1, cellPos.z) regionToSelect = Region3.new(lowVec, highVec) highlighter.selectionPart.CFrame = regionToSelect.CFrame - if nil ~= highlighter.OnClicked and highlighter.mouseDown then - if nil == highlighter.lastUsedPoint then - highlighter.lastUsedPoint = WorldToCellPreferEmpty( - c, - Vector3.new(mouseH.Hit.x, mouseH.Hit.y, mouseH.Hit.z) - ) - else - cellPos = WorldToCellPreferEmpty( - c, - Vector3.new(mouseH.Hit.x, mouseH.Hit.y, mouseH.Hit.z) - ) + if not (highlighter.OnClicked and highlighter.mouseDown) then + return + end + if nil == highlighter.lastUsedPoint then + highlighter.lastUsedPoint = WorldToCellPreferEmpty( + Terrain, + Vector3.new(mouseH.Hit.x, mouseH.Hit.y, mouseH.Hit.z) + ) + else + cellPos = WorldToCellPreferEmpty( + Terrain, + Vector3.new(mouseH.Hit.x, mouseH.Hit.y, mouseH.Hit.z) + ) - -- holdChange = cellPos - highlighter.lastUsedPoint + -- holdChange = cellPos - highlighter.lastUsedPoint - -- Require terrain. - if 0 == GetCell(c, cellPos.X, cellPos.Y, cellPos.Z).Value then - return - else - highlighter.lastUsedPoint = cellPos - end + -- Require terrain. + if 0 == GetCell(Terrain, cellPos.X, cellPos.Y, cellPos.Z).Value then + return end + highlighter.lastUsedPoint = cellPos end end @@ -305,8 +309,7 @@ function MouseHighlighter:SetMaterial(newMaterial) end function MouseHighlighter:GetPosition() - local position = self.selectionPart.CFrame.p - return WorldToCellPreferEmpty(c, position) + return WorldToCellPreferEmpty(Terrain, self.selectionPart.CFrame.p) end -- Hide the highlighter. @@ -421,19 +424,16 @@ end -- Clear the popup, free up assets. function ConfirmationPopup:Clear() - if nil ~= self.confirmButton then + if self.confirmButton then self.confirmButton.Parent = nil end - - if nil ~= self.declineButton then + if self.declineButton then self.declineButton.Parent = nil end - - if nil ~= self.confirmationFrame then + if self.confirmationFrame then self.confirmationFrame.Parent = nil end - - if nil ~= self.confirmLabel then + if self.confirmLabel then self.confirmLabel.Parent = nil end @@ -499,7 +499,7 @@ local function LoadProgressBar(text) -8 ), BackgroundTransparency = 1, - Image = "http://banland.xyz/asset?id=45880710", + Image = path "asset?id=45880710", Parent = spinnerFrame, } @@ -514,15 +514,13 @@ local function LoadProgressBar(text) local pos = 0 while pos < 8 do - if pos == spinPos or pos == ((spinPos + 1) % 8) then - spinnerIcons[pos + 1].Image = - "http://banland.xyz/asset?id=45880668" - else - spinnerIcons[pos + 1].Image = - "http://banland.xyz/asset?id=45880710" - end + spinnerIcons[pos + 1].Image = ( + pos == spinPos or pos == ((spinPos + 1) % 8) + ) + and path "asset?id=45880668" + or path "asset?id=45880710" - pos = pos + 1 + pos += 1 end spinPos = (spinPos + 1) % 8 wait(0.2) @@ -603,8 +601,7 @@ function mouseUp(_) end local function getMaterial(x, y, z) - local material = GetCell(c, x, y, z) - return material + return GetCell(Terrain, x, y, z) end local function doBreadthFill(x, y, z) @@ -680,15 +677,15 @@ function breadthFill(x, y, z) end local function cellInTerrain(x, y, z) - if x < c.MaxExtents.Min.X or x >= c.MaxExtents.Max.X then + if x < Terrain.MaxExtents.Min.X or x >= Terrain.MaxExtents.Max.X then return false end - if y < c.MaxExtents.Min.Y or y >= c.MaxExtents.Max.Y then + if y < Terrain.MaxExtents.Min.Y or y >= Terrain.MaxExtents.Max.Y then return false end - if z < c.MaxExtents.Min.Z or z >= c.MaxExtents.Max.Z then + if z < Terrain.MaxExtents.Min.Z or z >= Terrain.MaxExtents.Max.Z then return false end @@ -698,7 +695,7 @@ end function breadthFillHelper(x, y, z, yDepthChecks) -- first, lets try and fill this cell if cellInTerrain(x, y, z) and getMaterial(x, y, z) == emptyMaterial then - SetCell(c, x, y, z, currentMaterial, 0, 0) + SetCell(Terrain, x, y, z, currentMaterial, 0, 0) end local cellsToFill = {} @@ -735,7 +732,7 @@ function breadthFillHelper(x, y, z, yDepthChecks) for i = 1, #cellsToFill do SetCell( - c, + Terrain, cellsToFill[i].xPos, cellsToFill[i].yPos, cellsToFill[i].zPos, @@ -753,7 +750,7 @@ function breadthFillHelper(x, y, z, yDepthChecks) end On = function() - if not c then + if not Terrain then return elseif this then this:Activate(true)