Skip to content

Commit

Permalink
doc revisions
Browse files Browse the repository at this point in the history
  • Loading branch information
James committed Sep 23, 2023
1 parent dfa9834 commit d6c60e0
Show file tree
Hide file tree
Showing 14 changed files with 2,489 additions and 58 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2023 Canary Projects
Copyright (c) 2023 Canary Development

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
4 changes: 2 additions & 2 deletions docs/api/controllers/signal/signalcontroller.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,11 @@ The function to call when data is recieved

### Wait <Badge type="warning" text="yields" />

Yields the current thread until another script fires the signal controller. Returns a promise.
Yields the current thread until another script fires the signal controller.

#### Returns

* **{any}**
* **[Array](/api/engine/types#array)\<any\>**

---

Expand Down
4 changes: 2 additions & 2 deletions docs/api/engine/dependencies/enginedebugger.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ This type contains every roblox user data and generic type.

A list of cached stack traces for the current environment.

* [**Dictionary\<CallStack\>**](/api/engine/types#dictionary)
* **[Dictionary](/api/engine/types#dictionary)<[CallStack](#callstack)>**

---

### CachedDebugCalls

A list of cached debug calls for the current environment.

* [**Array\<string | {string}\>**](/api/engine/types#array)
* **[Array]((/api/engine/types#array))\<string | [Array](/api/engine/types#array)<string\>**

## Functions

Expand Down
12 changes: 6 additions & 6 deletions docs/api/engine/framework/canaryengineclient.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,23 +8,23 @@ CanaryEngine's client-sided interface.

A simple reference to the [Players.LocalPlayer](https://create.roblox.com/docs/reference/engine/classes/Players#LocalPlayer)

* [**Player**](https://create.roblox.com/docs/reference/engine/classes/Player)
* **[Player](https://create.roblox.com/docs/reference/engine/classes/Player)**

---

### PlayerGui <Badge type="tip" text="read only" />

A simple reference to the [Player.PlayerGui](https://create.roblox.com/docs/reference/engine/classes/Player#PlayerGui)

* [**PlayerGui**](https://create.roblox.com/docs/reference/engine/classes/PlayerGui)
* **[PlayerGui](https://create.roblox.com/docs/reference/engine/classes/PlayerGui)**

---

### PlayerBackpack <Badge type="tip" text="read only" />

A simple reference to the [Player.Backpack](https://create.roblox.com/docs/reference/engine/classes/Player#Backpack)

* [**Backpack**](https://create.roblox.com/docs/reference/engine/classes/Backpack)
* **[Backpack](https://create.roblox.com/docs/reference/engine/classes/Backpack)**

## Functions

Expand All @@ -39,14 +39,14 @@ The name of the controller

#### Returns

* [**ClientNetworkController\<any\>**](/api/engine/types#clientnetworkcontroller)
* **[ClientNetworkController](/api/controllers/network/client)**

---

### GetPlayerCharacter
### GetPlayerCharacter <Badge type="warning" text="yields" />

Gets the players current character model; if it doesn't exist the thread will yield until it does.

#### Returns

* [**Character**](/api/engine/types#character)
* **[Character](/api/engine/types#character)**
2 changes: 1 addition & 1 deletion docs/api/engine/framework/canaryengineserver.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ The name of the controller

#### Returns

* [**ServerNetworkController\<any\>**](/api/engine/types#servernetworkcontroller)
* **[ServerNetworkController](/api/controllers/network/server)**
26 changes: 2 additions & 24 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ keywords: [roblox, game, framework, changelog, updates]

## 4.0.0



### Added

* Adds `Red`, revamped the networking system once again and for the last time
Expand All @@ -19,11 +17,13 @@ keywords: [roblox, game, framework, changelog, updates]

### Improvements

* Improves EasyProfile ([#3](https://github.com/canary-development/CanaryEngine/pull/3), [koxx12](https://github.com/koxx12-dev))
* Renames `CanaryEngineFramework` instance to `Framework`
* Renames `CanaryEngine` module to `Init`
* Fixed TS support, back on roblox-ts!
* Small bug fixes
* QOL fixes
* Most yielding functions now make usage of Futures

### Removed

Expand Down Expand Up @@ -53,14 +53,10 @@ Nothing!

## 3.2.5



No information available, mainly small bug fixes.

## 3.2.4



### Added

* `AnonymousSignals` ([#2](https://github.com/canary-development/CanaryEngine/pull/2), [koxx12](https://github.com/koxx12-dev))
Expand All @@ -81,8 +77,6 @@ Nothing!

## 3.1.4



### Added

* Native `roblox-ts` support
Expand All @@ -101,8 +95,6 @@ Nothing!

## 3.0.1



### Added

* Nothing!
Expand All @@ -118,8 +110,6 @@ Nothing!

## 3.0.0



### Added

* Add `CanaryEngine.RuntimeCreatedSignals`
Expand Down Expand Up @@ -155,8 +145,6 @@ Nothing!

## 2.2.1



### Added

* Add Once + Disconnect to `NetworkSignals`
Expand All @@ -173,8 +161,6 @@ Nothing!

## 2.2.0



### Added

* Add 'Statistics Library'
Expand All @@ -192,8 +178,6 @@ Nothing!

## 2.1.0



### Added

* Add Vendor folder under new packages
Expand All @@ -213,8 +197,6 @@ Nothing!

## 2.0.0



### Added

* Added option to install default packages in the plugin
Expand All @@ -236,8 +218,6 @@ Nothing!

## 1.2.0



### Added

* Added install and uninstall to plugin
Expand All @@ -256,6 +236,4 @@ Nothing!

## 1.1.0



* Public release! 🥳
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,14 @@ local SignalControllerObject = { }
@within SignalControllerObject
]=]

SignalController.__index = SignalController
SignalController.__index = SignalControllerObject

-- // Variables

local EngineVendor = script.Parent.Parent.Parent.Parent
local EngineLibraries = EngineVendor.Libraries

local Signal = require(EngineLibraries.RedbloxUtils.Signal)
local Future = require(EngineLibraries.RedbloxUtils.Future)
local Sanitize = require(script.Parent.Parent.Sanitize)

-- // Functions
Expand All @@ -55,7 +54,7 @@ local Sanitize = require(script.Parent.Parent.Sanitize)
@return SignalControllerObject
]=]
function SignalController.NewController(name: string)
local self = setmetatable({ }, SignalController)
local self = setmetatable({ }, SignalControllerObject)

self._Signal = Signal()
self.Name = name
Expand Down Expand Up @@ -98,17 +97,25 @@ end
@param func (data: {any}) -> () -- The function to call when data is recieved
@return ControllerConnection
]=]
function SignalControllerObject:Once(func: (data: {any}?) -> ())
local Disconnect

Disconnect = self._Signal:Connect(function(data)
Disconnect()
func(data)
end)

return Disconnect
end

--[=[
Yields the current thread until another script fires the signal controller.
@yields
@return {any}
]=]
function SignalControllerObject:Await(): Future.Future
return Future.new(function()
return self._Signal:Wait()
end)
function SignalControllerObject:Wait(): {any}?
return self._Signal:Wait()
end

--[=[
Expand Down
Loading

0 comments on commit d6c60e0

Please sign in to comment.