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 - codejoy

Pages: [1]
1
I have NGUI and I saw this HUDText and I am thinking bout springing the 20$.  what I really need is a good way to give characters dialog and I see it can do that.    It looks relatively easy to set up...I couldnt' tell but I think it can use different kinds of fonts? ttf?  can it do the 2d toolkit kinds of fonts?  What I really would be looking for is to use this in conjuction with some way of doing text bubbles for a 8bit res kind of a game where the text bubbles pop up near a character complete with low res text bubble graphic and a nice ttf font that fits the theme I found.  if it can do this I am getting this( even if I have to somehow finagle the 2d text bubble graphic to match the hudtext, no clue yet how id do that.)

I guess real fast too, if the camera zooms in and out does the text scale accordingly?
(probably what I am asking is it it real world coordinates?)

Thanks for any info to help deciding if this will work for me in my project.

Shane

2
NGUI 3 Support / Camera in UI Root 3D putting Example 4 into my 2d Game...
« on: February 24, 2015, 03:33:39 PM »
I am confused I guess by the camera that is part of the UI Root 3D?  In the Example for, this looked great, I loved how the menu flew in and out, and I created even a test scene in the NGUI examples that let me bring up that window when escape was pressed (As if it was a pause menu).  I guess I had thought the Camera in that UI Root 3D that is part of all the NGUI stuff would "take over" when the Root was active.  After I got the window working and running how I wanted it from example 4 I saved it off as a prefab and copied it all to my main game project.

Though when adding it to the scene, it does not take up the whole screen and looks odd, not like it should...attached graphics in hope of figuring out what I am missing or doing wrong.


I want the window to show up like it does in pauseMenuUp.png, alas it shows up (when enabled or when it will be paused) like it does in ingame.png, I was hoping the camera in the UI Root(3d) would take over and it would look like pauseMenuUp does.

Attached are the various settings I have it is pretty much unchanged from Example 4, just trying to put it into my game that is 2d with a perspective camera of its own.


3
NGUI 3 Support / Re: UIKey Binding - keyboard+mouse selection problem
« on: February 24, 2015, 12:57:17 PM »
Excellent fix this totally worked, opening up a new discussion on a topic related to this example, but for now this totally worked thanks!


4
NGUI 3 Support / Re: UIKey Binding - keyboard+mouse selection problem
« on: February 21, 2015, 02:00:05 PM »
That's just the thing.   Thexample foudoes not work out iofthe box.   Was there something else to be done on it?  Just opening it up and pressing enter on the options button does nothing 

5
NGUI 3 Support / Re: UIKey Binding - keyboard+mouse selection problem
« on: February 19, 2015, 06:13:27 PM »
Okay.  I am trying to step back and evaluate what I am doing.

I originally opened up that Example 3, it had the nice window you click options it flies to the other window, you click done it flies back.  Does this all day.

I just wanted it to do this when the enter key or joystick was pressed and the options button was highlighted.

So I added to the Options Button in Panel - Main (which is enabled) two scripts:

I added a UIKey Navigation script (Added this to all the buttons on Panel - Main).  So great, I can move the keyboard up down and even hit enter and it makes the sound like it was clicked (as each button in this demo has a sound but the options button sounds different when clicked).  All this still happens.  It just never goes to the next window?  So i thought "a-ha I need a UIKey binding to intercept the enter/joystickbutton press"  So the UIKey binding on the options button is:
Key Code: Return
Modifier: None
Action: PressAndClick

I thought this would act as if a click was pressed on that button, which to me should set off the animations and the tweens.  But this never happens, it clicks, makse the noise, the animation of the clicking.

Now I discover if the UIKey binding is and attached to t hat options button, then pressing enter on any selection  always makes that one click too.  So i disabled the UIKey binding.

So I can select with the UIKey navigation script and arrow keys any button (and if I goto all their animations that do the hover animation, and change that to selected) the animations work as I press up and down on the arrow keys.  But pressing enter: does the click animation, plays the selected click sound but never goes to the other window.   Which the other window is ultimately disabled.  The thing that confuses me is why does it act like its clicking just never execute the fly to the other window, is it because the UIPlay Animation and UIPlay tween scripts are all looking for a trigger even of "OnClick" which if that was the case, and pressing enter on a button with UIKey Navigation on it means it should NOT make the clicking noise or anything, but it is, which sure enough the UIPlay sound looks for OnClick.

To me the Pressing enter while a key is selected (like options key) mimics an OnClick as the sound plays, and the other clicking animation plays, but the other things that trigger to onclick (Play animations to fly windows in and out) never play.  So I am not sure what I am missing, the UIPlay Animations all have if disabled on start enable the play (the two animations for the window no the one for the button selection, that was previous on hover

Since this is to me a simple case of attaching the UIKey Navigation to the options button from that demo so that pressing enter (or the A button on a 360 game pad) makes that options button press and goto the other window seemed pretty straight forward I am not sure where the disconnect of my understanding of this process is.






6
NGUI 3 Support / Re: UIKey Binding - keyboard+mouse selection problem
« on: February 18, 2015, 01:19:33 AM »
I am confused as to what I am trying to have enabled... Is it through the UIKey Navigation or the UIKey Binding somewhere that I have to enable the options window I want to goto from hitting enter on the options button on the main window?

Actually I am making some progress, I changed the On Trigger condition for the animations that make that window fly in and out...I didn't realize there were so many conditions (On Click I don't want ditching mouse) I am going purely gamepad/keyboard navigation.  I thought "On Select" true... but that triggers just by moving the arrow keys or the joystick to select that button, it doesn't wait for enter key or button press before flying the windows in and out...  So it is closer, I mean I really am not changing anything in the Example 3 that I know of, just trying to get keyboard navigation with enter key or gamepad navigation with button press to actually goto the next window or come back depending upon the options button highlighted when they hit enter or a joystick button, or if the done button on the other window is highlighted when they hit enter or press a button on the gamepad.


7
NGUI 3 Support / Re: UIKey Binding - keyboard+mouse selection problem
« on: February 16, 2015, 12:28:04 AM »
Nope I really cannot believe I am making this so hard sorry.  I added a UIKey Binding to the Options Button in the Example 3 of the NGUI.  I thought with the UIKey Navigation Script plust the UIKey Binding Script I could make it where moving the arrow keys up and down (or joystick) would select buttons (it does that) but pressing enter (or JoyStickButton0) does not select the button and go onto the next window like at all.  The first button in that menu in the UIKey Navigation is set to "Starts Selected"
 The constraints on all buttons are set in the UIKey Navigation.  I simply want it to work just like as if you had clicked with the mouse the options button.  I noticed I thought that was part of what Example 4 in the NGUI examples is telling one to do, and that does not work and I didn't touch it... It spoke of in example four the override , for what to do the on click?   Is there something I am totally missing, is it because most the logic seems to be done in Example 3 through the UIPlay Animations ??? which respond to an OnClick which does not seem to be emulated when the button is selected and the enter or joystickbutton 0 is pressed?

apparently very lost.


8
NGUI 3 Support / Re: UIKey Binding - keyboard+mouse selection problem
« on: February 15, 2015, 08:17:00 PM »
Ahhhh I think I was only using key navigation.   Sounds like I also need key binding too.   Maybe that's my missing piece

9
NGUI 3 Support / Re: UIKey Binding - keyboard+mouse selection problem
« on: February 15, 2015, 02:44:19 AM »
Okay I am still new to this,when you say target object (using the example 3) i am trying to make it where clicking A button on 360 wired controller goes to options panel.

I have "starts selected"  selected for the options button (but I think i want the first button to have that)....I am not sure where this starts enabled is... it seems like the "Select on Click" really does just that, selects the ui component as if it was hovered over or the controller was moved to it, but it doesnt push a OnClick to the system (so again all the components in the example 3 pick it up and change out to the options window).  Am I close to right?

10
NGUI 3 Support / Re: UIKey Binding - keyboard+mouse selection problem
« on: February 14, 2015, 04:55:25 AM »
I am trying to get the third example working with the example scene 3 where that window goes back and forth.   It works but I want the UIKey Navigation script to work too.  Strange thing is all the animations are triggered on an OnClick it seems and I cannot figure out how to make that options window in the demo pop up when enter/ or a button a controller is pressed..it acts like it presses it does button animation and the sound but the options panel never comes in.
And as an aside, how can I make that options panel visible so I can edit on it too?



Pages: [1]