-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added more features
- Loading branch information
Showing
5 changed files
with
412 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,31 @@ | ||
# Drop-down List | ||
|
||
just dropdown list | ||
|
||
## usage: | ||
``` | ||
local dropdownList = require(dropdownList) | ||
function a() | ||
return "Amogus" | ||
end | ||
local List = dropdownList.DropdownList:new( | ||
{ -- List of Elemets | ||
dropdownList.Element("One", a), -- Second arg is function (you can don't add) | ||
dropdownList.Element("Two"), | ||
dropdownList.Element("Three"), | ||
dropdownList.Element("UwU"), | ||
}, | ||
Frame, -- Frame that will be | ||
3, -- Rows, default 3 | ||
"Dropdown List" -- Name of List | ||
) | ||
List:Handler() | ||
List:Update(function(newVal:number) | ||
print(newVal) | ||
end) | ||
``` | ||
# Drop-down List | ||
|
||
just dropdown list | ||
|
||
## usage: | ||
``` | ||
local dropdownList = require(dropdownList) | ||
function a() | ||
return "Amogus" | ||
end | ||
local List = dropdownList.DropdownList:new( | ||
{ -- List of Elemets | ||
dropdownList.Element("One", a), -- Second arg is function (you can don't add) | ||
dropdownList.Element("Two"), | ||
dropdownList.Element("Three"), | ||
dropdownList.Element("UwU"), | ||
}, | ||
Frame, -- Frame that will be | ||
3, -- Rows, default 4 | ||
"Dropdown List" -- Name of List | ||
) | ||
List:Handler() | ||
List:Update(function(newVal:number) | ||
print(newVal) | ||
end) | ||
``` | ||
Example of use in ReplicatedStorage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# This file lists tools managed by Aftman, a cross-platform toolchain manager. | ||
# For more information, see https://github.com/LPGhatguy/aftman | ||
|
||
# To add a new tool, add an entry to this table. | ||
[tools] | ||
rojo = "rojo-rbx/rojo@7.4.1" | ||
# rojo = "rojo-rbx/rojo@6.2.0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
{ | ||
"name": "Drop-Down-List", | ||
"tree": { | ||
"$className": "DataModel", | ||
|
||
"ReplicatedStorage": { | ||
"Shared": { | ||
"$path": "src/shared" | ||
} | ||
}, | ||
|
||
"ServerScriptService": { | ||
"Server": { | ||
"$path": "src/server" | ||
} | ||
}, | ||
|
||
"StarterPlayer": { | ||
"StarterPlayerScripts": { | ||
"Client": { | ||
"$path": "src/client" | ||
} | ||
} | ||
}, | ||
|
||
"Workspace": { | ||
"$properties": { | ||
"FilteringEnabled": true | ||
}, | ||
"Baseplate": { | ||
"$className": "Part", | ||
"$properties": { | ||
"Anchored": true, | ||
"Color": [ | ||
0.38823, | ||
0.37254, | ||
0.38823 | ||
], | ||
"Locked": true, | ||
"Position": [ | ||
0, | ||
-10, | ||
0 | ||
], | ||
"Size": [ | ||
512, | ||
20, | ||
512 | ||
] | ||
} | ||
} | ||
}, | ||
"Lighting": { | ||
"$properties": { | ||
"Ambient": [ | ||
0, | ||
0, | ||
0 | ||
], | ||
"Brightness": 2, | ||
"GlobalShadows": true, | ||
"Outlines": false, | ||
"Technology": "Future" | ||
} | ||
}, | ||
"SoundService": { | ||
"$properties": { | ||
"RespectFilteringEnabled": true | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
local ReplicatedStorage = game:GetService("ReplicatedStorage") | ||
local playerGui = game:GetService('Players').LocalPlayer:WaitForChild('PlayerGui') | ||
|
||
|
||
local Frame = Instance.new("Frame") | ||
Frame.Parent = playerGui | ||
|
||
|
||
|
||
|
||
|
||
local DropdownList = requre(ReplicatedStorage.DropdownList) | ||
|
||
function a() | ||
--if you want cou can do this something | ||
return "Amogus" | ||
end | ||
|
||
local List = DropdownList.DropdownList:new( | ||
{ -- List of Elemets | ||
DropdownList.Element("One", a), -- Second arg is function (you can don't add) | ||
DropdownList.Element("Two"), | ||
DropdownList.Element("Three"), | ||
DropdownList.Element("UwU"), | ||
}, | ||
Frame, -- Frame that will be | ||
3, -- Rows, default 3 | ||
"Dropdown List", -- Name of List | ||
1 -- Speed of animation | ||
) | ||
|
||
List:Handler() | ||
|
||
List:Update(function(newVal:number) | ||
print(newVal) -- See to console | ||
end) |
Oops, something went wrong.