Jon Czeck will save you with his bundle of scripts
They work perfectly in Unity 2.5, and he included RenderToCubeMap.
Be aware that this version will now be accessible from the “Custom” menu, together with a bunch of great other scripts (just love that “deselect” shortcut with the “A” key, thanks so much Jon !)
I’m sorry Dremora, I don’t understand. I just downloaded this package. I don’t script at all and I don’t know which bit is the class or which . you mean.
Weird. I just checked again : create a new project in Unity 2.5 for Mac, double-click on “Graveck Editor Package.unityPackage”, everything imports smoothly.
Dremora, I’m trying. It helps enormously when the manual explains things. It is the Unity script, which is not third party, that I was trying to get working in the first place and I tried Yann’s suggestion because I couldn’t figure out why it wasn’t working. Also the Graveck stuff is a download from the Unity website and it looks very good. If I can get it to work.
Yann.
OK, I did as you suggested and imported the assets into a new project. It worked OK i just got a few different errors. They only apply to one script though so I’ll probably ditch it for now. I don’t know why I can’t import it into the project I’m working on but weirdness abounds with this project at the moment and I’m having all sorts of trouble.
I’ll try and import them into the other project one by one.
RHD, your editor scripts should remain in a folder named “Editor”. Your screen capture shows that you put them in a a “Script” folder. Your first screen capture, that is.
OK, I restarted, and reimported the Graveck Editor Package. This time it’s come in fine, not so much as a wimper from the console.
The reason the script is not in the Editor folder is that when I try and drop it on the camera, which I guess is what you do with it, I get an error message saying it can’t be used because it’s in the Editor folder. If I put it outside the Editor folder I get a different error message.
If you don’t add it to the camera you are trying to make the cubemap with, what do you do with it?
Editor scripts don’t have to be assigned to an object : their function is to extend Unity’s editor. You just use them, as you would use any other Unity editor function. In this case, go to the new “Custom” menu, choose “Render Into Cubemap” and follow the instructions. The new cubemap will have to be assigned to an already existing cubemap asset, so you will have to create it from the “Assets/Create” general menu, or from the “Create” menu of your Assets folder if you don’t want to erase the existing ones.
Right! I’ve obviously erased an existing one. It must have been a standard asset somewhere.
I’ve just started getting to grips with attaching scripts to objects. Making things happen the old fashioned way, through the Edit menu threw me into a confusion!
Great bundle of assets. Thank you for drawing attention to them and for your patience helping me sort it out.
The cubemap looks fantastic. It’s wonderful when it works!