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.


Topics - szomaza

Pages: [1] 2
1
This is quite worrying and I am pretty sure I wasn't doing anything wrong as both cases are so simple:

1.
I was working on a uGUI and I made the FSM template work properly on one button and then copied over the
- playmaker uGUI component proxy (was set to target Use Owner)
- and the template FSM to other 3 similar buttons
and tested it and found the bug that when I pressed one of the buttons another one was also pressed at the same time. Restarted several times with same result.
I was like ??? this should just work, what could be wrong? The buttons weren't overlapping of course.
I changed the target in the component proxy from Use Owner to the specific game object and it worked well that way.
Restarted Unity and set back the component proxys to target the Use Owner and it all worked perfectly and keeps on working since then.

I am pretty sure it just needed a Unity restart.
Why is this?
How can I know when I need to restart Unity to get such things working properly so I don't waste time debugging stuff that should just work.

2.
Just now I found that the
Convert Formatted String To Float and the Convert String To Float
just does not work.
I looked at the state when it was running and the string value was there, but all the float results were 0.
I tried many different number styles but all resulted in 0 in various float variables and even the simple Convert String To Float was not converting 56.00 to nothing, the resulting float was 0.

Restated Unity and all works, perfectly.

Why is this?
How can I know when I need to restart Unity to get such things working properly so I don't waste time debugging stuff that should just work.

Has anybody else experienced such behavior?

Br,
szomaza

2
Playmaker Help / Draw Line sort order
« on: October 26, 2017, 10:56:10 AM »
Hi All,

I have been using the Draw Line action to, ... well draw some lines. :-)
Now I put some uGUI images "behind" it and I am unable to make the line appear anymore, as the ugui images appear before it.

I have moved them on Z axis behind, also set their draw order to -50, but still the lines only appear when I turn the uGUI images off.
(Draw Curve and Draw Spline behaves the same.)

Is this how it should work?
Could the Draw Line action have a Sort Order setting?

Is there any other action that could help me draw some simple lines that appear before the uGUI?
Maybe some mesh plane based thing with which you could position the 4 vertexes of a mesh plane? (to form it at runtime into a thin rectangle: a line)

Thanks in advance for any help,
szomaza

3
Playmaker Help / Found a bug with Enum on iOS
« on: March 07, 2017, 12:15:34 PM »
Hi All!

I am sending enum data in a send event action and then doing an Enum Switch to branch the other FSM.
Works perfectly on Android but does not work anymore after switching Unity to iOS platform.

1. What I see on iOS is that no matter which one of the enum data are selected when the game is run (in editor) the enum data settings all default back to the first enum data value.
2. This defaulting back to the 1st value can also be observed (even when Unity is set to Android) when copying enum actions in an FSM: after copying the enum data gets changed back to the 1st value. Does not keep the vale that has been set in the action that was copied.

Is/was this a known bug? Has it been fixed in newer version?

I am on:
Unity 5.4.1f1
Playmaker: 1.8.3.f4

br,
szomaza

4
Playmaker Help / Speed of X solution versus Y when formatting a string
« on: February 06, 2017, 10:25:28 AM »
Hi All,

I have a general question about how do programmers know which solution to code when faced with a problem when there are several different ways to achieve the same result?

(I only use Playmaker, don't code.)
I could implement both ways and run them a zillion times and measure it or watch profiler, then I would know which one is faster, but is there a more CLEVER step by step evaluative way to judge which solution would run faster?

The task I need to solve is that I'll have a bunch of integers in string format. All between 0 and 999 and I need to make them into 3 length strings.
e.g.:
1 should be 001,
56 should be 056,
258 will remain 258.

With playmaker I could simply get this result by, converting the string to int and then from int back to string with using 000 formating.
This would be very easy to set up in one state but I fear because of the string-int-string conversion it might run quite slow.

The other way would be to check the length of the string, then Int Switch 1,2 or 3 length and then use a bit different build string for the first 2 and nothing when it is already 3 long.
This would require many more states, but might actually run faster in the end.

Any words of wisdom, how a programmer would think about which method to use? Which will run faster?



Thanks in advance,
szomaza

5
Playmaker Help / How to store data online?
« on: October 01, 2016, 07:47:59 AM »
Hi All,

I am making an app an I store a bunch of achievements, progress and stats for the player from one play session to the other but only locally in playerprefs.
It would be a disaster to lose all the when the player gets a new device, or simply deletes and reinstalls the app.

Is there any plugin/extension that would help with this easily: just connect to google game services, iOS or Facebook and save/sync/store/reload the playerprefs?

I have searched the forum but found only EasySave and similar ones which don't solve the server part of the saving.

Please help with some ideas I should investigate.

Thanks in advance,
szomaza

6
Playmaker Help / Set String Value does not accept empty string
« on: March 31, 2016, 10:28:25 PM »
The Set String Value action does not accept an empty string.
In most use cases this is a good check, as it shows an error and reminds you to fill that field out. (In most cases you want something there.)
But I wanted to use it to empty a string variable. I can't have even a space character in it.

Should there be a Empty String Value action?

Luckily I am not stuck, as the Set Fsm String does the job. It allows an empty value.

7
Playmaker Help / Create a duplicate of a Game Object
« on: March 14, 2016, 10:59:31 PM »
Hi,

Is it possible to simply create a duplicate of a game object during runtime, along with all it's child objects and all parameters of it's components?

What I am doing is loading in game objects by merging scenes, but in some cases I would need 2 of some of those game objects.
I searched but could not find anything, like a PlayMaker action to do this duplication.

Action would simply: duplicate game object stored in variable, and save newly created object in another variable.
Am I dreaming?

Instead this, I believe I could use a bunch of get component, get property and set property actions, add FSMs to them, etc. but that could get complicated ... for me.

Or I could save each different object (I'll eventually have hundreds) into prefabs and simply spawn 2 of each, where required.
Then I would not need the whole: loading them by merging a level part, but spawning many prefabs does have a huge hit on performance.

Please shed some light, how I should proceed or share your experience/solution to similar problem.

Br,
szomaza

8
Playmaker Help / Every Frame in Send Event does not seem to work
« on: March 11, 2016, 12:19:26 AM »
Hi,

I am trying to use the Send Event
https://hutonggames.fogbugz.com/default.asp?W34
with the Every Frame ticked but it only sends the event once.

The send Event code looks like this:

Code: [Select]
// (c) Copyright HutongGames, LLC 2010-2013. All rights reserved.

using System;

namespace HutongGames.PlayMaker.Actions
{
[ActionCategory(ActionCategory.StateMachine)]
[Tooltip("Sends an Event after an optional delay. NOTE: To send events between FSMs they must be marked as Global in the Events Browser.")]
public class SendEvent : FsmStateAction
{
[Tooltip("Where to send the event.")]
public FsmEventTarget eventTarget;

[RequiredField]
[Tooltip("The event to send. NOTE: Events must be marked Global to send between FSMs.")]
public FsmEvent sendEvent;

[HasFloatSlider(0, 10)]
[Tooltip("Optional delay in seconds.")]
public FsmFloat delay;

[Tooltip("Repeat every frame. Rarely needed.")]
public bool everyFrame;

private DelayedEvent delayedEvent;

public override void Reset()
{
eventTarget = null;
sendEvent = null;
delay = null;
everyFrame = false;
}

public override void OnEnter()
{
if (delay.Value < 0.001f)
{
Fsm.Event(eventTarget, sendEvent);
Finish();
}
else
{
delayedEvent = Fsm.DelayedEvent(eventTarget, sendEvent, delay.Value);
}
}

public override void OnUpdate()
{
if (!everyFrame)
{
if (DelayedEvent.WasSent(delayedEvent))
{
Finish();
}
}
}
}
}

Am I right that there is this line missing from the OnUpdate part?
Fsm.Event(eventTarget, sendEvent);
before checking for    if (!everyFrame)

Br,
szomaza with Playmaker 1.7.8.3p2

9
Action Requests / Date actions: day of the week, month length...
« on: February 09, 2016, 01:43:12 AM »
Hi,

Some more DATE actions would be very handy for us non programmer types.

With Get System Date Time: https://hutonggames.fogbugz.com/default.asp?W823
we can already get the year, month and day. That is great!

An action to calculate the length of any particular month would be nice to have. (give year and month, get number of days in month)
Also an action to tell which weekday any particular year/month/day is.

Thanks in advance,
szomaza

10
Playmaker Help / Canvas Image (Script) SET/GET property problem
« on: January 29, 2016, 02:30:08 AM »
With the canvas image script one can animate the image, for example to make it fill radially like a clock.
http://docs.unity3d.com/Manual/script-Image.html

There is a 0-1 float value there for this so I figured I'll just drag the component over to a state and Set Property, but for some reason the set/get property window does not appear when I drag this type of component.
Why is that?
Which Unity components can't be used this way and why?

I am on Unity 5.2.1f1 and Playmaker 1.7.8.3p2.

Thanks in advance,
szomaza

11
I can't seem to find where I can turn this feature on in the preferences.
The action usage count and the ability to find them - please see attached image.

In a previous version of Playmaker I can see how many times an action has been used and can use the find to jump to them in FSMs.
This is grayed out in the latest version of Playmaker.

How do I turn this on?

Br,
szomaza

12
Playmaker Bug Reporting / Game Analytics[SOLVED]
« on: July 11, 2015, 04:44:42 AM »
Tried installing the latest version of Unity, Game Analytics and Playmaker, but my efforts were stopped by different errors:

I did the following: Installed the newest version of all:
- Unity 5.1.1f1
- Game Analytics Unity SDK 2.1.0
- Playmaker 1.7.8.3
then toggled the playmaker scripts of GA and received this error:

Assets/GameAnalytics/Plugins/Playmaker/SendBusinessEvent.cs(53,39): error CS1501: No overload for method NewBusinessEvent' takes7' arguments

Then toggled these scripts off and installed the "fix" package from here:
the 0.6.6 fix: https://hutonggames.fogbugz.com/default.asp?W1170
 
this resulted in all sorts of errors in GA_Menu.cs starting with:
Assets/GameAnalytics/Editor/GA_Menu.cs(11,42): error CS0103: The name `GA' does not exist in the current context

What happened, how did GA jump from 0.6.6 to Unity SDK 2.1.0?
Could somebody create a fix for this latest version?

Thanks in advance,
szomaza

13
Playmaker Help / Instead of Application Quit
« on: March 07, 2015, 05:02:49 AM »
I can't find an action that would just close the application to be "paused" in the background.

This one quits the application.
https://hutonggames.fogbugz.com/default.asp?W672

When using this the application closes and after clicking the application icon again it restarts from the beginning.
What I would like is to have an action that does what the Android Home button does to a running application. It does not quit it, but just puts it into the background.
In this case when clicking the application again to restart it, it does not start from the beginning but quickly comes up and continues where it was left before the home button was pressed.

I would like to use this action instead of the quit one when the user taps the back/return Android button to just close the app temporarily instead of totally quitting it.

br,
szomaza

14
Android Help / CRASH - textfield entry
« on: February 24, 2015, 12:03:55 AM »
I found a crash that happens every time on Android device.
I have no idea if it is Unity's fault or Playmaker action's, as I don't know how to debug the  app running on the Android device and probably would not understand the error log anyway.  :-)

But it is as simple as it gets. Here are the repro steps:
1. look at attached image and create one gameobject with one FSM that does the same.
Explanation: this simply displays a text field the user can click, than enter or edit the text in it. After pressing OK (on virtual keyboard), the text field entry disappears for 3 seconds, than it is displayed again, can be clicked and the previously entered text edited. And so on.
2. It crashes and the app is exited and an Android window shows: ("Unfortunately, (App Name) has stopped.") every time when the following is done:
3. first enter any text into the field and pres OK on the virtual keyboard
4. this saves the text into the string variable and after 3 seconds the field is displayed again, now with the previously entered text in it,
5. tap the field to bring up the virtual keyboard and edit the text,
6. now just move the text entry cursor to the end of the text and press OK
7. observe that the app hangs for a few seconds than it is exited with the above error message.

In case the text is edited, any letter written to it, or deleted, or the cursor left at the beginning of the text entry field this crash does not happen when pressing the OK.
It only crashes in this one case, when the cursor is moved to the end and nothing is modified, just the OK is pressed.

Same happens if GUILayout Password Field is used instead of the Text Field.

First I thought I might be causing this crash but than stripped it down to this bare minimum and it still happens, so I guess this will cause problems for anybody using textfields.

Please figure out what is causing this and fix.
Br,
szomaza

15
iOS Help / What do I need to be able to ask for app store rating?
« on: February 10, 2015, 11:27:32 PM »
Hi,

Many apps have a popup window at some stage asking the user to rate the app in the app store.
They can press 1-5 stars and/or be taken to the app's page on the app store.

Is there any add on that can do this? Has playmaker actions for popping up a window, asking for rating and taking the player to the app store URL (if that is also required to achieve this).

thanks for any help,
szomaza

Pages: [1] 2