Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - capitalj

Pages: 1 [2] 3 4 ... 6
16


Ok, so this happens when I instantiate a dynamic font uilabel prefab and anchor it to a gameobject offscreen. This only appears in builds, not in the editor. So far I've tested only iOS and Mac builds. In the editor the labels work perfectly and anchor themselves to my object. In builds they are gigantic when instantiated....

17
NGUI 3 Support / Re: Dynamic labels and soft clipped panels
« on: May 08, 2014, 03:00:44 AM »
Yeah, I tried that after reading up some other posts about soft clipping. I've tried a few different quality settings and nothing restored the label.

18
NGUI 3 Support / Dynamic labels and soft clipped panels
« on: May 08, 2014, 01:26:54 AM »
This is odd, and might just be limited to iOS platform, but dynamic font uilabels don't seem to show up (are invisible) when placed under a panel that has soft clipping turned on. If you turn off the soft clipping the uilabel appears, or if you move the label to another panel.

19
Other Packages / Re: Tasharen Fog of War
« on: May 07, 2014, 10:40:28 PM »
Hi, has anyone had luck getting FOW to work on iOS using the shader based approach? The Image Effect works fine, although a bit processor intensive, so I'm trying to see if I can use the shader approach but when I switch the project over to iOS the FOW doesn't show up, even in the demo scene.

I've tried in a brand new project as well and switching to iOS platform seems to disable the fog itself, but objects still appear/disappear as if the fog was there.

20
Other Packages / Re: Tasharen Water
« on: May 02, 2014, 01:39:41 AM »
So I tried adjusting this line in the shader:
// The amount of foam added (35% of intensity so it's subtle)
half foam = nmap.a * (1.0 - abs(col.a * 2.0 - 1.0)) * 0.5;

but a higher value just makes the existing foam brighter, not wider/bigger. Is is possible to make the foam go further from the shoreline so that it is several times wider/thicker?

21
NGUI 3 Support / TweenHeight changing anchor left and right
« on: April 30, 2014, 12:00:17 AM »
Hi, I am trying to do a TweenHeight animation on a sprite that is anchored to it's Panel using Unified anchor. The left and right anchors are +0 but when the tween happens (which should only affect the height of the sprite?) both the left and right anchor values start changing as if they are trying to maintain the aspect ratio of the sprite (but I have aspect set to Free). In fact if you just drag left/right on the sprite height attribute the anchor does this as well. Is this the way it is supposed to work? If so, how do I do a tween height and not affect the width on an anchored sprite?

22
Other Packages / Re: Tasharen Water
« on: April 29, 2014, 07:51:16 PM »
Hey, I've just purchased the water and was wondering if it's possible to adapt a few things to make it work in large scale? My game uses a 1:1 scale, so my play area is around 15000x12000 unity units. I have to stretch out the water to around 10000x10000.

1) The tiling option in this case is limited so even at the smallest tiling value it looks very tiled. Can I change this in the shader or some other way to match the tiling to my game's scale better? Found the value to adjust inside the shader :)

2) Is the a way to increase the shoreline size? Again at this scale the shorelines are very thin and when zoomed out barely visible. It would be great to be able to increase their "thickness" so they extend out further from the shore.

23
Other Packages / Re: Tasharen Fog of War
« on: April 17, 2014, 07:31:18 PM »
Or an even easier solution is to just turn off the FOW image effect whenever I switch to the viewpoint that shows the skybox (where the blocked areas aren't visible anyways). :)

24
Other Packages / Re: Tasharen Fog of War
« on: April 16, 2014, 03:36:31 PM »
2. When using the Image Effect based approach the skybox is a part of the scene so yes it will be covered by the fog. If you want selective fog of war, you need to use custom shaders on objects as shown in the second example.

Do you think it would be possible to have a 2nd camera that only renders the skybox and still use the Image Effect approach and not have the skybox affected by the FOW effect?

25
Other Packages / Re: Tasharen Fog of War
« on: April 06, 2014, 10:06:57 PM »
You can try setting the Raycast Radius to 0, I'm not sure if that will help in your situation but I remember doing something like that and it hid the backs of mountains.

26
Other Packages / Re: Tasharen Fog of War
« on: April 01, 2014, 01:45:00 PM »
Ah ok, I'll try out the shader based approach then.

So for the explored/unexplored areas, is there a way to disable that feature? So that areas that are hidden (whether previously explored or not) are always at the same darkness?

27
Other Packages / Re: Tasharen Fog of War
« on: April 01, 2014, 01:54:25 AM »
Hey, 2 questions about FOW:

1) Is it possible to have only 1 texture? I don't really need an explored and unexplored color. I would like to have everything either be  hidden or visible.

2) the FOW currently projects onto the skybox if viewed from a ground level instead of overhead view: http://cl.ly/image/0e2z31360d22

28
NGUI 3 Support / Keeping Widgets anchored to GameObjects on-screen
« on: March 29, 2014, 07:31:27 PM »
Hi,

I'm using the anchoring of UIWidgets to anchor to GameObjects (like characters). Is there any way to have the widget stay on screen even if the GameObject itself is off-screen? So if I move the camera so that the GameObject is off-screen to the right of the camera, the widget will just stay along the right edge of the screen.

I've done this type of thing when manually creating code to follow objects with NGUI elements before this new anchoring system, so just wondering if there's a easy way to do this without having to write brand new anchoring code? of if there's an example script of this already out there.

-JJ

29
Other Packages / Re: Tasharen Fog of War
« on: March 29, 2014, 05:26:11 PM »
Sounds like you are overthinking it. Why do you care when the FoW is updated? Its performance hit is minimal. If you truly care about it for some reason, then just enable the FOWSystem when you know it will be updated, and then disable it some time later -- after some delay of a few seconds, for example. FOWSystem is meant to be real-time, not turn-based, so by trying to change it to be updated manually you are only creating headaches for yourself.

Yeah, maybe. My stuff has to run on mobile so I usually want to try to reduce the cpu use to free up room for other things. I'll keep working away at it. Unfortunately turning the component off and on doesn't really work, the results are not always the same and it doesn't update when it is enabled sometimes.

Unrelated question: what do I have to do to update the FOW system if I have terrain that is loaded at runtime? I've found that if a different terrain is loaded during the game start the FOW still reflects the terrain that was in place before the terrain was changed. Even when my characters move and call Rebuild on their revealers, it still doesn't update to match the new terrain. Is there a way to force it to redraw the FOW from scratch?

30
Other Packages / Re: Tasharen Fog of War
« on: March 26, 2014, 08:09:04 PM »
I see. Ok well the issue with my implementation is that I don't know when the FOW logic is being updated, but it would be great to just call some function on FOWSystem to have everything updated at that time. So I'm just confused as to how to make this work in a turn based system like my game where I don't need any sort of update frequency happening, it's all manually called. Maybe the game flow is not clear, here's what I am looking to do:

There are 2 teams, which should not be able to see each other's characters if they are in the FOW.

1) Game start: each player's character's FOWRevealer is enabled or disabled depending on whether it is that character's team's turn. The FOW system then needs to update to reveal the current team's characters.

2) Player moves a character. The FOW needs to update to reveal the change based on the character's new position.

3) Player ends their turn. Each character's FOWRevealer is enabled or disabled again based on whether it is that character's team's turn. Then the FOW system needs to update to reveal the new team's characters and hide the old team's characters (if they are in the fog).


So what I don't understand is which components to enable/disable and force update when these 3 stages happen. I have the FOWRevealers all changing properly when the turns change, but the whole FOWsystem stuff is not really working, which must be because it's in the middle of some sort of updates or transitions when I have these stages happening. Sometimes it works perfectly but sometimes there is no update to the FOW.. or the FOWSystem.isvisible reports that a character is visible even though they are in the fog.

Pages: 1 [2] 3 4 ... 6