Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 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 IBone · Jul 26, 2013 at 05:43 PM · 2dlight

2d dynamic lighting?

How could I make, in a 2d scene, a lantern be the only thing giving off light, and you can't see the rest of the scene except what the lantern is lighting up. I've tried everything with fog and environmental lighting, but still everything stays lit up with the lantern area being a little brighter. Any suggestions? Thanks for any help!

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

3 Replies

· Add your reply
  • Sort: 
avatar image
0

Answer by hubbyo9 · Jul 26, 2013 at 06:31 PM

I think what you want is shadows, and that is a pro feature only

Comment
Add comment · Show 2 · 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 Jamora · Jul 26, 2013 at 06:33 PM 0
Share

Actually only dynamic shadows are a Pro only feature. Here's an answer how to get shadows in Unity Free. You can also have simple dynamic shadows as explained in this youtube tutorial. You get the Blob projector byt following this answer.

avatar image hubbyo9 · Jul 26, 2013 at 06:36 PM 0
Share

i meant dynamic shadows

avatar image
0

Answer by Kiloblargh · Jul 26, 2013 at 08:03 PM

Here is a super cheesy but definitely-will-work solution. Make a second camera on a higher layer than the first, and have it render a shadow object that is twice the screen size and centered on the lantern; that is just a flat plane with a multiply particle texture on it of all black with a blurred white circle in the middle. You could also make it a mesh with vertex colors but no texture map, and you can animate its scale or have more than one of them and animate their position and color if you want a flickering effect.

Plenty of 2d games from the '90s got away with doing that.

Comment
Add comment · Show 2 · 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 IBone · Jul 26, 2013 at 09:43 PM 0
Share

Umm, that sounds like it might work but I am way confused on how to do it. I am really new to unity obviously so all I understood out of that is make a second camera then I got lost hehe

avatar image BossGrand · Jan 27, 2014 at 08:55 PM 0
Share

if you're super new don't worry about dynamic shadows. $$anonymous$$ake something simple

avatar image
0

Answer by F-N · Feb 16, 2016 at 12:10 PM

For people who are still trying to achieve this in a simple way without Unity pro: Add a point light and add a material to a sprite(prefered shader: sprites/diffuse). Then go to environment lighting settings under Window/Lighting/Scene and finally change the ambient intensity to a really low value or just to zero.

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

20 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

How can I achieve this particular 2D lighting effect? 2 Answers

2D Lights with Unity 4.3 2 Answers

Directional Light seems to have no effect on MeshRenderer. 1 Answer

ortographic spotlight ? 1 Answer

Shader not whiter than the original sprite color? 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