Range Trigger on non-dialog system code?

Announcements, support questions, and discussion for the Dialogue System.
terrymorgan
Posts: 97
Joined: Wed Sep 10, 2014 5:29 pm

Re: Range Trigger on non-dialog system code?

Post by terrymorgan »

Very slick! here it is again with the standard assets 1st person controller, just move it WASD in scene view, didn't
put a camera on him.


https://dl.dropboxusercontent.com/u/102 ... itypackage
1.0MB
User avatar
Tony Li
Posts: 20774
Joined: Thu Jul 18, 2013 1:27 pm

Re: Range Trigger on non-dialog system code?

Post by Tony Li »

Handy little script, eh? :-)
terrymorgan
Posts: 97
Joined: Wed Sep 10, 2014 5:29 pm

Re: Range Trigger on non-dialog system code?

Post by terrymorgan »

Here's the same scene with one of the free Mixamo animals

https://mixamo.com/store

The animations are available elsewhere, I've only used the horse, but all the animals, horse, dragon, dog, came in the same
directory with names like trot_1 (the dog), trot_2 (the horse), so you'll have to separate them out. Also, it looks like there's
a mesh model with every animation, not sure how to separate that out, wasteful.

https://dl.dropboxusercontent.com/u/102 ... itypackage
3.4MB
User avatar
Tony Li
Posts: 20774
Joined: Thu Jul 18, 2013 1:27 pm

Re: Range Trigger on non-dialog system code?

Post by Tony Li »

If you want only the animation clip, you can expand the FBX file in the Project view, select the animation clip, and press Ctrl+D to duplicate it as a standalone animation clip file. Then you can delete the FBX.
terrymorgan
Posts: 97
Joined: Wed Sep 10, 2014 5:29 pm

Re: Range Trigger on non-dialog system code?

Post by terrymorgan »

Ctrl+D to duplicate it
I had to do that anyway before it would drag into the animator controller's blend tree, I also wanted to rename them, they're
all called 'mixamo.com'.
User avatar
Tony Li
Posts: 20774
Joined: Thu Jul 18, 2013 1:27 pm

Re: Range Trigger on non-dialog system code?

Post by Tony Li »

This is moot now that you've duplicated it, but you can change the animation clip name in the FBX file, too. On the Animation tab, click on the name field ("mixamo.com") and change it to whatever you want. Then click Apply.
terrymorgan
Posts: 97
Joined: Wed Sep 10, 2014 5:29 pm

Re: Range Trigger on non-dialog system code?

Post by terrymorgan »

Here's my notes on the Mixamo stuff, can't locate the animals though

https://sites.google.com/site/terrymorg ... ree_assets
terrymorgan
Posts: 97
Joined: Wed Sep 10, 2014 5:29 pm

Re: Range Trigger on non-dialog system code?

Post by terrymorgan »

New snapshot, the giraffes animators are disabled too with bigger sphere colliders, I think I need some fog just before they hit 'go' mode

https://sites.google.com/site/terrymorg ... d_may_2016
terrymorgan
Posts: 97
Joined: Wed Sep 10, 2014 5:29 pm

Re: Range Trigger on non-dialog system code?

Post by terrymorgan »

It doesn't work on the RPG kit generic Skeleton type enemy though, there's 2 animators, and the 'setup animator' gives an error when I add it to the
components list

NullReferenceException: Object reference not set to an instance of an object
PixelCrushers.DialogueSystem.RangeTrigger.SetTargets (Boolean value) (at Assets/Dialogue System/Scripts/Supplemental/Utility/RangeTrigger.cs:92)
PixelCrushers.DialogueSystem.RangeTrigger.OnTriggerEnter (UnityEngine.Collider other) (at Assets/Dialogue System/Scripts/Supplemental/Utility/RangeTrigger.cs:36)
Attachments
goblin_ranger_r1.jpg
goblin_ranger_r1.jpg (176.77 KiB) Viewed 1336 times
User avatar
Tony Li
Posts: 20774
Joined: Thu Jul 18, 2013 1:27 pm

Re: Range Trigger on non-dialog system code?

Post by Tony Li »

At runtime, inspect the Range Trigger component. Make sure there aren't any null or missing entries in the Components list.
Post Reply