playMaker

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

Pages: [1] 2 3
1
ok so recreating GetPosition + WorldToScreenPoint and SetPosition as customActions doing their thing in LateUpdate improved the result..

2
Playmaker Help / Re: Crossy Road Movement Issue
« on: September 07, 2018, 04:54:50 AM »
i see that your set rotations are done in WorldSpace while the addforce is done in self.
maybe you should consider putting some consistency inbetween both things.

3
or should i modify the 3 actions i use to make them act in FixedUpdate ?

4
hi
any ideas how to fight against a 'lag' inbetween camera movement and a UI element update onscreen?

i have a FSM
- grabbing a scene object X and Y world position
- immediately doing 'WorldToScreenPoint'
- applying this position to a UI canvas element.

The goal is to have an info bubble which flies above an object and is UI (not worldspace)
Usage example: Imagine you have a door and over the handle i want a bubble saying "press E to open"

Now my camera is a FPS style controlled with the mouse.
The problem is that if user moves the camera around, even gently, the UI info bubble updates it's position onscreen with some latency.
i basically want to get rid of this latency to the maximum.

i have been reading posts about:
https://answers.unity.com/questions/828905/what-is-1-and-what-is-2-in-vsynccount.html but the 3 options here don't seem to make any difference.

I also tried to make the set position normaly or as "late update" but it does not change anything.

Long story short : since this UI element is the thing in front of the eyes of players at all times i want it to be as responsive as possible and with a lag inferior to what human eye can catch.
Also i dont want lag on slower harware configs.

stumbled upon these posts:

https://docs.unity3d.com/Manual/ExecutionOrder.html

https://docs.unity3d.com/Manual/class-MonoManager.html
not sure if i can make an FSM (custom script ?) as the highest prio in my project ?

https://hutonggames.com/playmakerforum/index.php?topic=4095.msg19134#msg19134

https://hutonggames.com/playmakerforum/index.php?topic=3858.msg17862#msg17862

there are so many options here that i don't know in which direction to start.
maybe someone can help me save some long experimentation hours ?
thanks in advance.

5
Pre-release Discussion / Re: input fields loose focus
« on: August 31, 2018, 05:30:18 AM »
same error here on unity 2017.3.1f1 + pm1.9.0.f5
closing the global variable tab fixes it.

it kept coming back and i did not understood what's going-on.
i ended up typing fsm name or field value in notepad and copy pasting it in the field ^^

seems that the global variables window is causing strange behaviors
(like this one discussed these days http://hutonggames.com/playmakerforum/index.php?topic=18901.new;topicseen#new )

6
Playmaker Help / Re: "Owner == null!"
« on: August 30, 2018, 05:47:01 AM »
unity 2017.3.1f1 + PM 1.9.0.f5

7
Playmaker Help / Re: "Owner == null!"
« on: August 30, 2018, 04:12:38 AM »
hi

i have a similar error.
can't share project unfortunately.


Owner == null!
UnityEngine.Debug:Log(Object)
HutongGames.PlayMakerEditor.FsmVariable:set_Owner(Object) (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariable.cs:88)
HutongGames.PlayMakerEditor.FsmVariable:.ctor(Object, FsmFloat) (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariable.cs:237)
HutongGames.PlayMakerEditor.FsmVariablesEditor:Reset() (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariablesEditor.cs:201)
HutongGames.PlayMakerEditor.FsmVariablesEditor:SetTarget(Object) (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariablesEditor.cs:174)
HutongGames.PlayMakerEditor.GlobalVariablesWindow:DoGUI() (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/GlobalVariablesWindow.cs:43)
HutongGames.PlayMakerEditor.BaseEditorWindow:OnGUI() (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/BaseEditorWindow.cs:117)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

if i close the GlobalVariables window the error does not appear on play.

if i  click on Globals tab while in play mode i have the following error

Owner == null!
UnityEngine.Debug:Log(Object)
HutongGames.PlayMakerEditor.FsmVariable:set_Owner(Object) (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariable.cs:88)
HutongGames.PlayMakerEditor.FsmVariable:.ctor(Object, FsmFloat) (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariable.cs:237)
HutongGames.PlayMakerEditor.FsmVariablesEditor:Reset() (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariablesEditor.cs:201)
HutongGames.PlayMakerEditor.FsmVariablesEditor:SetTarget(Object) (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariablesEditor.cs:174)
HutongGames.PlayMakerEditor.FsmVariablesEditor:.ctor(EditorWindow, Object) (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariablesEditor.cs:158)
HutongGames.PlayMakerEditor.GlobalVariablesWindow:Initialize() (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/GlobalVariablesWindow.cs:34)
HutongGames.PlayMakerEditor.BaseEditorWindow:OnGUI() (at C:/Users/Alex/Documents/Unity/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/BaseEditorWindow.cs:87)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

if i click on Globals tab while NOT in play mode the error is the same as the first one

i guess this is harmless but it would be nice to not see it in the middle of my other countless warnings ;-)

i hope this would help identify the source of this debug line
Regards.


8
Playmaker Help / Re: Know last 'U Gui Button On Click' Event Source
« on: July 03, 2018, 06:27:30 AM »
good suggestion.
i guess i need to put a wait of at least 0.1 in my main script to leave some time to the FSM of the clicked button do the action you talk about.

9
Playmaker Help / Re: Know last 'U Gui Button On Click' Event Source
« on: July 03, 2018, 04:14:04 AM »
ok option 3 does not work
first all the gameobject assign actions are done and then ONLY all the Button On Click waits for a click.

10
Playmaker Help / Know last 'U Gui Button On Click' Event Source
« on: July 03, 2018, 03:58:54 AM »
Hi

i searched the forum and echosystem for this.

is there a simple way to store the last button which generated an event via this action :


too bad this action does not have an additional param which would be "button script carrier" and we could store that in a gameobject variable.

in a state i have several stacked actions monitoring several buttons.
i was thinking about 3 ways to accomplish this but both feels overkill for me.
also each of these seems kinda viable if you just have 2 up to 5 buttons, but if you have way more buttons all look very complex to handle a simple problem.

1) on each of the buttons monitored : put an FSM-event call in OnClick() in the inspector. Call another FSM which has only one role : catch with a global transition event which button of the pool of buttons was the last pressed.

2) the simple stupid one : put a different event on EACH of the stacked actions, and save the clicked button in a global variable before doing anything else.
the problem is that this solution looks ugly to me. it visually pollutes the FSM.


3) -Does not work-
Right above each 'U Gui Button On Click' of my stack : put a "set gameobject" and store the button from the action right under in a variable (same variable for all onclick's).

given that the state will exit via one of the OnClick's it means that it will not execute the gameobject assignation lower than the actual button which was just pressed. As a result the variable would have the last pressed button saved.

Any suggestions to handle this the most clean and easily maintenable way ?
thanks.

11
Action Requests / Re: Create material Action.[SOLVED]
« on: May 02, 2017, 12:29:30 PM »
thanks a lot jean.
it seems to do what i wanted.

For noobs like me : take note that the material(or shader actually) that is created during runtime don't appears in the hierarchy of the project.
But if you store this new material in a variable and set it on an object it will actually work and you can modify the color of it individually, independantly from any other instance of the same object.


12
Action Requests / Re: Create material Action.
« on: April 26, 2017, 03:00:46 PM »
Here ya go mate
Code: [Select]
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using System ;


namespace HutongGames.PlayMaker.Actions

{
[ActionCategory (ActionCategory.Material)]


public class AddMaterialAction : FsmStateAction
{
[UIHint(UIHint.Variable)]
public FsmMaterial AddMaterial;


public override void Reset()

{
AddMaterial = null;

}


public override void OnEnter()

{
AddMaterial = new FsmMaterial (Shader.Find("Standart"));

Finish ();
}
}
}

Hello.
can i have more infos about the usage of this piece of code ?
it doesn't seem to create any new material inside the project folders.
do i use it properly ?
what am i supposed to put inside the "add material" variable of the action ?
am i supposed to tell the action which material i would like to make a COPY of ?

please help

13
sorry it worked after i added a MeshColider to my blocks

now i have the UV info as a hint between 0 and 1
so i guess i have to use GetTexture size to convert the 0to1,0to1 float coordinates to real int,int texture coordinates to use this with Get pixel color

14
hello

i'm trying to use the action UVRaycast.cs but
in the category DEBUG the value of "pixel UV" remains always (0.0,0.0)
while the rest of the raycast seem to work weel (i can see it with debugdisplay and i can retrieve all other infos using "get raycast hit info"

basically what i wanted to do is "get material texture" once i identify the material
that was collided and then make a "Get pixel color"
this way i want to retrieve the color of the pixel that was hit by the UVRaycast.

thoughts anyone ?

is this action too old / deprecated ?



15
Share New Actions / Re: Follow Mouse[SOLVED]
« on: January 22, 2016, 03:34:25 PM »
hello

i wanted to use this script for a proto that i playtest on PC and Mobile Android aswell

the script works fine on Pc and on device
UNTIL you touch the screen with a second finger
at this moment instead of snapping on the position of the first or the second finger ... the object always follows the exact position inbetween the 2 fingers touching the screen.

is there a way to avoid this ?
either by changing something in the script or maybe some way to deactivate the multi-touch (i dont plan to use it at all in this project) ?

thanks

Pages: [1] 2 3