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

Pages: [1] 2
Action Requests / Re: get renderer bounds
« on: February 01, 2016, 02:35:59 PM »
Works beautifully as long as I add a collider to my object. Thanks a lot jean, as always.

Share New Actions / Re: calculate bounds
« on: February 01, 2016, 02:24:15 PM »
well first I get a popup that tells me I need to update my APIs because the ones the script use are obsolete .

I went ahead and did it because I really wanted this action, and after I did I lost my new playmaker functionality of creating new variables from the drop down. This functionality: disappeared after I clicked "go ahead I've made a backup."

I'm about to try the link to the action in ecosystem that you sent me in another thread. I've never heard of ecosystem until then.

thanks for the reply. Two questions: 
Which property has the "bounds" of the collider? 
Is this an efficient way of doing it? 
I ask the second question because so many time I come up with a solution for something, and I feel like "should I really be doing this? is this what someone with experience would do? is this going to slow my game down?" 
being self taught with just knowing some actions, to me, I feel like a student of the english language who knows vocabulary, but no grammar.

yea, just to clarify, for anyone else wondering what I meant:

I want to know the height and width of a rectangular game object specifically. Not it's scale, but how many units it takes up in space.

PlayMaker Help / Does anyone know how to find the size of a game object?
« on: January 29, 2016, 12:54:07 PM »
Is this possible to do in playmaker? I've read a lot of stuff talking about finding bounds or extents, but my mesh render properties have no such option.

Action Requests / get renderer bounds[SOLVED]
« on: January 28, 2016, 05:52:04 AM »
This would be huge for me. I don't know how to program. I've been trying all kinds of ways to find where the renderer bounds are stored. Looks like someone made an action for this back in 2012

Share New Actions / Re: calculate bounds
« on: January 28, 2016, 05:48:08 AM »
wow, this is exactly what I need. Any chance you can update it to playmaker 1.8, unity 5? I'll put this in the action request page as well.

I figured it out! The camera HAS to be set to orthographic is seems. It spawns my object on the Z depth of the camera, even in ortho mode, but in the corder of my actual screen resolution. 
I think I really need to look into the 2D settings of unity since I'm making a 2D game, but I'm scared.

Thank you so much. This seemed to clear it right up. I was terrified to use 1.8 because it said BETA.

I went to the gym feeling hopeless, and came back to an answer, really. Thanks. 

Any ideas why screen to world 1, 1, 0 (normalized) would return 0, 0, -7.8? I don't see how this is possible, but at least my variables are no longer glutting out on me.

yes vertical video, because I felt it served a purpose :) 
anyways... what's happening here? It's a fresh scene with only this FSM

Thanks for taking some time to look through that :)

what's a triple for loop?

I know I will have to do a couple more iteration type things similar to this for other scenarios.

Later I'm going to have to make a method for moving a tile up or down. It's going to need to make sure nothing in the row above it has the same x value plus or minus half the width of the tile.

It seems I've fixed my problem. You're reply tipped me off on what to look for Jean, Thanks. I had to write a whole new process to give my sort action something it can actually sort, but I'm afraid my method is too clunky. I was hoping for some suggestions, so I made a post in the general board. Here is a link for anyone who might be interested.

If anyone has anything to say about the link, please reply in that topic :)

I'll keep it short as possible. I often run into situations while using PM like this and always feel like I'm doing something wrong. I'm always thinking I'm not being efficient enough or my code is too sloppy. Here's an example I'm hoping you can look at. Let me know what kind of suggestions you have.

I have squares that spawn (using a spawn pool).
Each square starts on the right and moves to the left.
There are 65 Possible positions 5x13 grid.
I have an array list with every position on it called all positions
When a tile spawns on the right side I look through the array list of all positions for all the positions that match the spawned tile's row (in this case that is the Z axis)

All matching z axis are added to a new array list called possible positions

I iterate through the possible positions list taking the x (right to left value) from each vector 3 and adding it to a new list called possible positions x

now that I have an array with only floats I "array list sort" it and it puts the lowest value on top

Next, now that I have the lowest X value, I know which value is in the same row as the spawned tile, and of those, which is the furthest away.

I reassemble the y and z to my new found x, and use this vector 3 as my position to "move to".

I remove this vector 3 from the all position list, so the next tile that spawns in the same z (row) wont consider it.

This seems like such a long process to me, and I'm terrified that once I finish my game is going to be clunky

it never even crossed my mind, but can you not sort a vector 3 array? I guess I don't actually know what sort does  :-[

every array list I am using uses Vector 3. This is what I get in console (I think this is all one error)

InvalidOperationException: No IComparable or IComparable<System.Object> interface found.[Object] (System.Object value1, System.Object value2, IComparer`1 comparer) (at /Users/builduser/buildslave/monoAndRuntimeClassLibs/build/mcs/class/corlib/System/Array.cs:1755)
System.Array.qsort[Object,Object] (System.Object[] keys, System.Object[] items, Int32 low0, Int32 high0, IComparer`1 comparer) (at /Users/builduser/buildslave/monoAndRuntimeClassLibs/build/mcs/class/corlib/System/Array.cs:1721)
System.Array.Sort[Object,Object] (System.Object[] keys, System.Object[] items, Int32 index, Int32 length, IComparer`1 comparer) (at /Users/builduser/buildslave/monoAndRuntimeClassLibs/build/mcs/class/corlib/System/Array.cs:1674)
Rethrow as InvalidOperationException: The comparer threw an exception.
System.Array.Sort[Object,Object] (System.Object[] keys, System.Object[] items, Int32 index, Int32 length, IComparer`1 comparer) (at /Users/builduser/buildslave/monoAndRuntimeClassLibs/build/mcs/class/corlib/System/Array.cs:1677)
System.Array.Sort[Object] (System.Object[] array, Int32 index, Int32 length) (at /Users/builduser/buildslave/monoAndRuntimeClassLibs/build/mcs/class/corlib/System/Array.cs:1608)
System.Collections.ArrayList.Sort () (at /Users/builduser/buildslave/monoAndRuntimeClassLibs/build/mcs/class/corlib/System.Collections/ArrayList.cs:3185)
HutongGames.PlayMaker.Actions.ArrayListSort.DoArrayListSort () (at /Users/R2D2/Dropbox/ColorSavvy_4.0/Assets/PlayMaker ArrayMaker/Actions/ArrayList/ArrayListSort.cs:48)
HutongGames.PlayMaker.Actions.ArrayListSort.OnEnter () (at /Users/R2D2/Dropbox/ColorSavvy_4.0/Assets/PlayMaker ArrayMaker/Actions/ArrayList/ArrayListSort.cs:37)
HutongGames.PlayMaker.FsmState.ActivateActions (Int32 startIndex)
HutongGames.PlayMaker.FsmState.OnEnter ()
HutongGames.PlayMaker.Fsm.EnterState (HutongGames.PlayMaker.FsmState state)
HutongGames.PlayMaker.Fsm.SwitchState (HutongGames.PlayMaker.FsmState toState)
HutongGames.PlayMaker.Fsm.UpdateStateChanges ()
HutongGames.PlayMaker.Fsm.LateUpdateState (HutongGames.PlayMaker.FsmState state)
HutongGames.PlayMaker.Fsm.LateUpdate ()
PlayMakerFSM.LateUpdate ()

Pages: [1] 2