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

Pages: [1] 2 3
1
Playmaker Help / Re: Get Animator State Last Frame
« on: August 10, 2018, 02:42:23 PM »
You could have a animation state specific to this action with a "Changing Gun" Bool to prevent firing during this sequence.

IE. - Idle -> Bool true -> Changing gun state -> Trigger Weapon in -> Changing gun state -> Trigger Weapon out ->  Changing Gun state -> Bool to False->  Idle

This saves you from having to check animation states every frame.

If you want to do a small script to fire off events during the animation then you can use this https://docs.unity3d.com/Manual/animeditor-AnimationEvents.html for reference.

2
Action Requests / Re: Replace String's Wild Card Charas With...
« on: August 07, 2018, 03:30:01 PM »
What you can do is use the String Replace Action.
This way you can change a word in your string at runtime. You will need to build the string as a local or global variable and then use string replace to change your wildcards.
Eg. "This is a great [item]" -> Set as string variable (Local or Global)
Replace string action -> [item] to your variable

Realistically your probably really looking for something like Dialog System on the asset store. This has playmaker integration and is very robust.
https://assetstore.unity.com/packages/tools/ai/dialogue-system-for-unity-11672

3
Action Requests / Re: Replace String's Wild Card Charas With...
« on: August 06, 2018, 05:40:46 PM »
Using Build string would work for that.
Set a global string variable as PlayerName and EquippedItem
Then use a Build String action:
Part One: Hello,
Part Two: PlayerName
Part Three: How are you today

etc.

Hope this helps.

4
General Discussion / Re: Mutiplayer game with Playmaker?
« on: July 03, 2018, 05:52:32 PM »
@FunD

Here is a nice guide for basic multiplayer from unity https://unity3d.com/learn/tutorials/topics/multiplayer-networking/introduction-simple-multiplayer-example
It shows 5.3, but is current for 2018.

Also Playmaker works great for multiplayer as well.

5
Playmaker Help / Re: achievements, in game shop, ads
« on: June 23, 2018, 11:32:25 AM »
Sorry,
to clarify SimpleIAP would be for the shop only.
Achievements would have to be done separately.

Thanks

6
Playmaker Help / Re: achievements, in game shop, ads
« on: June 23, 2018, 07:17:13 AM »
Simple IAP works for XBOX as XBOX uses the windows app store for its transactions.
For achievements you could still make them using Playmaker and an array to hold them, with pop up windows, etc.. When you are ready to jump into the Xbox side you can then create a FSM that links the two together. IE. when you earn the achievement in local game side you can fire an event to send it to the xbox side.

Just an option for you. I know it doesn't solve your question, but this would allow to you code in all your achievements, build your game and then look again at assets when you are close to completion. Assets change all the time so something better may come along.

7
Sounds like and awesome death scene :)

I'm not sure how your player/game is setup, but you could do a reset of your variables and then once the screen goes black do a set position back to the beginning. This could be called through a Broadcast All "Reset" Event tied to the FSMs that need to be set back to zero/default values.

Another option, you can duplicate your playing scene so once you are done in playing_scene1 you can async load playing_scene2 during the death animation and load into playing_scene2. Then you can just keep switching back and forth between the two.

Food for thought.


8
Here is a method that I used for character customization:

Setup an array or hash table that corresponds to the area you are changing.
EG. HeadItems - array, LeftHand -array.
Put all the gameobjects that need to go in that spot into the proper array.

Then I set the following as global variables: (probably not the best method, but one I personally found most consistent). I use all caps for Globals.
PLAYER_OBJECT - As GameObject
HELMET_ITEM - As String

To set and change the equipment: using a helmet as an example
Local FSM Variables needed
Gameobject - NewHelmetObject
Gameobject - OldHelmetObject
GameObject - HeadMountPoint
GameObject - ArrayResult
Int - IndexID
String - CurrentHelmet_String
String - array/hash table reference (optional)
String - Child mount point location (optional)

State1:
Load key to fill CurrentHelmet_String (Easy Save preferred). Default is blank
Holder state that is fired off from a send event -  eg. Change_Helmet

State2: check for valid object
Array List contains game object:
Check HELMET_ITEM string to see if array list contains the object
Game Object: Owner or Specify Game Object
Reference: HeadItems
Game Object Name: HELMET_ITEM
Result: ArrayResult
Result Index: IndexID
If true go to State3 - change
If False go to state5 - default catch

State3: Create and place new object from array/Hash table
Array List get: Get your object from the array. store as NewHemletObject.
Find Child:
     GameObject: PLAYER_OBJECT 
     Child Name: (eg) Player/Head/Hat/MountPoint
     Store Result: HeadMountPoint
Create Object Advanced (ecosystem):
     GameObject: NewHelmetObject
     Parent: HeadMountPoint
     Set Active: Check
     Store Object:  OldHelmetObject (important so you can destroy old hat if equipped)
String compare: HELMET_ITEM to CurrentHelmet_String. If not matching fire event to move to State4

State4: Destroy item and reset
Set String Value: CurrentHelmet_String to HELMET_ITEM
Save: CurrentHelmet_String (Easy Save)
Destroy object: OldHelmetObject
FINISHED Event points back to State2

State5: Set to default
Set String CurrentHelemt_String: Set this string to a default object in your array - array item can be empty (none)
Set String HELMET_ITEM string: Set to same name as above
FINISHED Event - Go to State2

I am looking forward to what others may have done as well.
Always up for learning :)




9
You could make your death a different scene and then have your main game start loading in the background and switch back. If it is only a summary screen the transition time would be seamless.
Main scene -> player dies -> switch to death scene (summary screen) -> load main async in background -> load  back to main game.

If you knew the average loading time you could purposely slow down your summary screen info. IE text that appears line by line, fly's in from the side. Things like that. This way the gamer doesn't really realize how much time has passed. 

Just a suggestion to get the ideas going.

10
Playmaker Help / Re: Advice on save/load
« on: May 03, 2018, 06:51:13 PM »
The tut was just to show that Easy Save will save the position and rotation of the prefab objects. Just make sure you have a button or timer that will fire off a Save like the one on the Load Scene Button. This will then save all the prefabs that you've registered. In the settings under Windows -> Easy Save 2 Window -> Settings, you can choose to have it auto save on Application Quit, Application Pause or None.
I usually have this set to none so that I can control the saving and loading manually.


11
Playmaker Help / Re: Advice on save/load
« on: May 03, 2018, 12:14:12 PM »
Sorry Richardh,
I loaded up a fresh scene and the latest version doesn't work like that. Sorry for the bad advice. So now let's fix it :)
Here is a video. Sorry for the background noise.

Hope this helps.
https://youtu.be/Kk5pYeRvqiw

12
Playmaker Help / Re: Advice on save/load
« on: May 02, 2018, 11:32:46 AM »
Easy Save is amazing.
The new Easy Save 3 auto save might be what you are looking for.
In short:
Install Easy Save
Go to Assets -> Easy Save 3 -> Enable Easy Save for Scene
Create Parent Object -> Add ES3 Autosave script and enable Save Children

This will auto save at scene end (quit) and auto load on scene start.

From there you can tweak your needs.
Not sure the performance hit on loading 10,000 objects would be  :)

Thanks


13
Playmaker Bug Reporting / Re: state stop on first send event action
« on: April 07, 2018, 06:59:07 PM »
A quick guess is that on your GO goupille it is not on the correct state to accept the UNLOCK send event.
ie. If it is on the first state and that state does not have the UNLOCK event on it then this send event won't fire.
Second guess is that your FSM Name does not match correctly.


14
Playmaker Help / Re: Can't set non-string FSM variable?
« on: March 27, 2018, 01:10:51 PM »
For the bool:
Set Value:
-> with checkmark =  Set bool to True
-> no checkmark = Set bool to False

In short if you want the bool to set to false then leave the Set Value checkbox blank.


15
Action Requests / Re: Limit Look at Rotation
« on: March 15, 2018, 08:35:45 AM »
There are Look At and Smooth Look At actions.
To prevent it from rotating into a wall or object I use a float compare. When x/y > or < the area of rotation limit, we move to a second state that stops the turret/camera following the player.
Simple Setup:
1st State: (make sure every frame is selected on all)
Get property on turret x/y rotation - store in float value "rotation"
Float compare - "rotation" > 90 -> go to 2nd state -  this is your upper limit of rotation
Float compare - "rotation" < 0 -> go to 2nd state - this is your lower limit of rotation
Look at or Smooth Look At -> Player Object

2nd state:
 To get it to re-activate, should the player re-enter the area, here are a couple of options:

1. Have an empty game object inside your turret that continues to look at the player. This object will rotate without affecting your actual turret. Track its x/y rotation and do a float compare. When the values are within range then go back to your tracking state.

2. Have 2 colliders that are being checked for onTrigger. One at the top range and one at the bottom range and when the player enters go back to your tracking state.

Hope this helps.



Pages: [1] 2 3