generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Drop Down with a Scrolling Bar?

Previous Thread :: Next Thread 
Lukekneenew is not online. Lukekneenew
Joined: 20 Oct 2009
Total Posts: 746
29 Jul 2013 09:34 PM
How would I make a drop down menu with a scrolling bar on the side? There is a scrolling frame function in RbxGui, but I don't get how you would use it. Can someone help?
Report Abuse
ZachBloxx is not online. ZachBloxx
Joined: 26 Jun 2013
Total Posts: 2833
29 Jul 2013 09:40 PM
-- Copied straight off the Roblox Wiki:
http://wiki.roblox.com/index.php/RbxGui


function waitForChild(p, c) -- utility code; don't worry about this
while not p:FindFirstChild(c) do
p.ChildAdded:wait();
end
return p[c];
end

local library = assert(LoadLibrary('RbxGui')) -- load our RbxGui library

function onItemSelected(item) -- create our callback that gets called when an item gets selected
-- arguments: item (string)
print("'" .. item .. "' was selected!")
end

local listOfItems={"This", "is", "a", "list", "of", "items."} -- our list of items
local dropDownList, updateSelection=library.CreateDropDownMenu(listOfItems, onItemSelected); -- create the drop down list with our list and the callback
dropDownList.Size = UDim2.new(1, 0, 1, 0) -- this is to make the drop down list fit in our GUI correctly

local holderGui = Instance.new('ScreenGui') -- make the screen gui that holds everything
local holderFrame = Instance.new('Frame') -- make a frame to hold the drop down list
holderFrame.Size = UDim2.new(0, 200, 0, 26) -- make it the size you want
holderFrame.Position = UDim2.new(0.5, -100, 0.5, -20) -- position it the way you want (right now it's in the center)
holderFrame.BackgroundTransparency = 1 -- make it transparent for the drop down list
holderFrame.Parent = holderGui

dropDownList.Parent = holderFrame -- put the drop down list in the frame

if game.Players.LocalPlayer then -- make sure we have a player
local playerGui = waitForChild(game.Players.LocalPlayer, "PlayerGui"); -- wait for playergui
holderGui.Parent = playerGui -- put the screen gui in the playergui
end
Report Abuse
Lukekneenew is not online. Lukekneenew
Joined: 20 Oct 2009
Total Posts: 746
29 Jul 2013 09:41 PM
Umm, what about the scrolling bar?
Report Abuse
Lukekneenew is not online. Lukekneenew
Joined: 20 Oct 2009
Total Posts: 746
30 Jul 2013 07:06 AM
Anyone?
Report Abuse
Phyclops is not online. Phyclops
Joined: 27 Sep 2012
Total Posts: 5895
30 Jul 2013 07:19 AM
we fix your scripts
we don't make them for you
Report Abuse
ZachBloxx is not online. ZachBloxx
Joined: 26 Jun 2013
Total Posts: 2833
30 Jul 2013 07:41 AM
@Luke, that makes a scrolling list..
Report Abuse
Lukekneenew is not online. Lukekneenew
Joined: 20 Oct 2009
Total Posts: 746
30 Jul 2013 07:07 PM
I need a scrolling BAR with a scrolling list.
Report Abuse
areaquest2 is not online. areaquest2
Joined: 05 Jun 2010
Total Posts: 196
30 Jul 2013 07:09 PM
can you just make a gui that uses basicly the same code so it goes down as the other one does?
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image