Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Mat Brummitt · Apr 27, 2010 at 08:56 AM · iphonewindowscrollingcontent

Scrollable Content Window? Unity iPhone

Hi all,

This might seem like a very basic question but it's something i've not needed to know until now...

A game i'm working on requires the user make a song selection from within the game (not a song from the iPod or anything, but a song from my own predefined list)... The number of songs to select from far-exceeds what can fit on one screen, so the user needs to be able to scroll down the list to make their selection. It might be nice if the scrollable area sat underneith the top-bar of the app so that scrolling doesn't push the top-bar off the screen.

I was wondering if there's anything built in for this purpose or if anyone had any suggestions for the best way to go about doing this? I'm using SpriteManager for all of my on-screen elements for performance (keeping down draw calls) and i'm avoiding OnGUI features which i'm told racks up draw calls.

My initial thought was that i'd have to physically move the camera to give the effect of scrolling and parent the background image to the camera so that it doesn't appear to scroll... however I figured there's probably a less cumbersome way to do this simple thing.

Any advice greatly appreciated as always.

Thanks

Mat

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

2 Replies

· Add your reply
  • Sort: 
avatar image
2

Answer by StephanK · Apr 27, 2010 at 09:43 AM

As you won't display this menu all the time in your game I don't see why you couldn't use OnGUI(). There is GUI.ScrollView to deal with your problem... ;)

Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Mat Brummitt · Apr 27, 2010 at 10:12 AM 0
Share

I guess 1 added draw call wouldn't hurt, but would I not need to use other GUI elements to make up the song selection elements? Or, is there a way I could use Sprite$$anonymous$$anager in conjunction with GUI.ScrollView?

Thanks very much for your help

avatar image StephanK · Apr 27, 2010 at 06:03 PM 0
Share

Never used Sprite$$anonymous$$anager, so don't know the answer to that question.

avatar image StephanK · Apr 27, 2010 at 06:05 PM 0
Share

However, the point was, that when showing a menu fps isn't that important, so that keeping drawcalls down maybe isn't necessary.

avatar image
1

Answer by Groov · Jul 16, 2010 at 02:41 AM

I guess i have something similar for my app's main menu system, where there are 13 selections available, with the screen only showing 3 of these at a time.

I place each of the 13 selections as GOs and use spritemanager2 to assign the texture from the atlas material.

I then use a touch controlled scroller script to control the main camera up and down the list. To the right of my list is an info bar that is a GUITexture. This also acts nicely as a frame (you could have it on top too if you want and the GOs would scroll under it).

(note that the above 13 items are NOT children of the main camera, but are placed in the scene one under the other).

I find this method very easy to set up and not costly on the draw cells too.

Hope this helps

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

No one has followed this question yet.

Related Questions

A node in a childnode? 1 Answer

How to support Retina display 1 Answer

How do I invert the Y axis in Penelope tutorial? 3 Answers

Compiling in Xcode? 0 Answers

Spawn Script not working on iPhone? 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges