@@ -2,9 +2,9 @@
|
||||
Changes the background color while the animation is running
|
||||
|
||||
#### Parameters:
|
||||
1. `table` multiple color numbers - example: {colors.red, colors.yellow, colors.green}
|
||||
2. `number` duration in seconds
|
||||
3. `number` time - time when this part should begin (offset to when the animation starts - default 0)
|
||||
1. `number` duration in seconds
|
||||
2. `number` time - time when this part should begin (offset to when the animation starts - default 0)
|
||||
3. `...` multiple color numbers - example: colors.red, colors.yellow, colors.green
|
||||
|
||||
#### Returns:
|
||||
1. `animation` Animation in use
|
||||
|
||||
@@ -3,8 +3,10 @@ Changes the text while animation is running
|
||||
|
||||
#### Parameters:
|
||||
1. `table` multiple text strings - example: {"i", "am", "groot"}
|
||||
2. `number` duration in seconds
|
||||
3. `number` time - time when this part should begin (offset to when the animation starts - default 0)
|
||||
1. `number` duration in seconds
|
||||
2. `number` time - time when this part should begin (offset to when the animation starts - default 0)
|
||||
3. `...` multiple text strings - example: "i", "am", "groot"
|
||||
|
||||
|
||||
#### Returns:
|
||||
1. `animation` Animation in use
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
Changes the text color while the animation is running
|
||||
|
||||
#### Parameters:
|
||||
1. `table` multiple color numbers - example: {colors.red, colors.yellow, colors.green}
|
||||
2. `number` duration in seconds
|
||||
3. `number` time - time when this part should begin (offset to when the animation starts - default 0)
|
||||
1. `number` duration in seconds
|
||||
2. `number` time - time when this part should begin (offset to when the animation starts - default 0)
|
||||
1. `...` multiple color numbers - example: colors.red, colors.yellow, colors.green
|
||||
|
||||
#### Returns:
|
||||
1. `animation` Animation in use
|
||||
|
||||
@@ -10,6 +10,7 @@ some special functionality to create very advanced programs.
|
||||
|[setBarTextAlign](objects/Frame/setBarTextAlign.md)|Sets the top bars text align - deprecated
|
||||
|[showBar](objects/Frame/showBar.md)|Shows the top bar - deprecated
|
||||
|[setMonitor](objects/Frame/setMonitor.md)|Sets the frame to be a monitor frame (only for base frames)
|
||||
|[setMonitorScale](objects/Frame/setMonitorScale.md)|Sets the monitor scale (same as monitor.setTextScale)
|
||||
|[setMirror](objects/Frame/setMirror.md)|Sets the frame to mirror onto a monitor (only for base frames)
|
||||
|[getObject](objects/Frame/getObject.md)|Returns the object by its name (or id)
|
||||
|[removeObject](objects/Frame/removeObject.md)|Removes the object by its name (or id)
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
## setMonitor
|
||||
Sets this frame as a monitor frame
|
||||
You can set base frames as monitor frames, don't try to use setMonitor on sub frames
|
||||
|
||||
#### Parameters:
|
||||
1. `string` The monitor name ("right", "left",... "monitor_1", "monitor_2",...)
|
||||
1. `string|table` The monitor name ("right", "left",... "monitor_1", "monitor_2",...) OR a table to create multi-monitors (see example)
|
||||
2. `number` optional - a number between 0.5 to 5 which sets the monitor scale
|
||||
|
||||
#### Returns:
|
||||
1. `frame` The frame being used
|
||||
@@ -12,8 +13,29 @@ Sets this frame as a monitor frame
|
||||
```lua
|
||||
local mainFrame = basalt.createFrame()
|
||||
local monitorFrame = basalt.createFrame():setMonitor("right")
|
||||
monitorFrame:setBar("Monitor 1"):showBar()
|
||||
monitorFrame:addLabel():setText("Hellooo!")
|
||||
```
|
||||
```xml
|
||||
<frame monitor="right"></frame>
|
||||
```
|
||||
|
||||
* Here is a example on how to create mutlimonitors. You always have to start on the top left of your screen and go to the bottom right, which means in this example
|
||||
monitor_1 is always your most top left monitor while monitor_6 is your most bottom right monitor.
|
||||
|
||||
Table structure:
|
||||
local monitors = {
|
||||
[y1] = {x1,x2,x3},
|
||||
[y2] = {x1,x2,x3}
|
||||
...
|
||||
}
|
||||
|
||||
```lua
|
||||
local monitors = {
|
||||
{"monitor_1", "monitor_2", "monitor_3"},
|
||||
{"monitor_4", "monitor_5", "monitor_6"}
|
||||
}
|
||||
|
||||
local mainFrame = basalt.createFrame()
|
||||
local monitorFrame = basalt.createFrame():setMonitor(monitors)
|
||||
monitorFrame:addLabel():setText("Hellooo!")
|
||||
```
|
||||
15
docs/objects/Frame/setMonitorScale.md
Normal file
15
docs/objects/Frame/setMonitorScale.md
Normal file
@@ -0,0 +1,15 @@
|
||||
## setMonitorScale
|
||||
Changes the scale on the the monitor which the frame is attached to
|
||||
|
||||
#### Parameters:
|
||||
1. `number` A number from 0.5 to 5
|
||||
|
||||
#### Returns:
|
||||
1. `frame` The frame being used
|
||||
|
||||
#### Usage:
|
||||
* Creates a new base frame, sets the frame as a monitor frame and changes the monitor scale
|
||||
```lua
|
||||
local myFrame = basalt.createFrame()setMonitor("left"):setMonitorScale(2)
|
||||
myFrame:addLabel("Monitor scale is bigger")
|
||||
```
|
||||
@@ -29,8 +29,8 @@ local anim = main:addAnimation()
|
||||
:setObject(sub)
|
||||
:move(2,4,1.5)
|
||||
:setObject(button)
|
||||
:move(2,9,1,1.5):
|
||||
setObject(button2)
|
||||
:move(2,9,1,1.5)
|
||||
:setObject(button2)
|
||||
:move(sub:getWidth()-12,9,1,1.5)
|
||||
:play()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user