Virtual Joystick TopDownCharacterController/ThirdPersonChacaterController Update*

(Jamie pearce) #1

After all said and done i give you my custom PlayerTopDownController For FREE ive been trying to get help and all i did was ask around and no one wanted to help for free so i try’d my self over and over again for 5 hours the results paid off
(note im not a very good coder so im happy i did it my self)

Download unity simple joystick by right clicking on your assets folder click import package then click crossPlatformInput

now go to rpg_ui scene drop the MobileSingleStickControl in the scene dont not as child of RPG_UI

now download my PlayerTopDownController and remove the original one and add mine to your character all features work the same i only added the Virtual joystick feature.
enjoy guys :slight_smile:

heres the Camera control script i just finished
just replace your current topDownCamera script with the new one :slight_smile:
then change the Horizontal and Vertical in the inspector of your second virtual joystick to Horizontal2 and Vertical2 (this is located in the Joystick.cs script)

Edit 2: if your having issues with a path that cant find your joystick then open the scripts and change the using statement at the top to this.

using UnityStandardAssets.CrossPlatformInput;


here is the ThirdPersonCharacterController and camera scripts for virtual joy or touch pad

you have horizontal and vertical (left virtual sctick or touch pad) then horizontal1 and vertical1 (right virtual stick or touch pad)

[guide] Mobile touch character controller
Loading/Changing Scene make RPG_UI numb/unclickable
(Leslie Young) #2

Look at the code where I use Key_FBMove, Key_LRMove, Key_GamepadLRMove etc. That is where you would have to take values from your virtual stick.

FBMove = Forward/Backward movement (W and S on keyboard)
LRMove = Left/Right movement (A and D on keyboard)

These values are in the range of (-1 … 0 … +1) (float values) normally.

can i ask why you haven’t made an implementation for this yet

Because while plyGame might work on mobile the the plyGame RPG controllers were not made for mobile use.

(Jamie pearce) #4

thats exactly what i was already looking at just took time for me to figure out how to do it XD.
Thanks thou it helped confirm i was looking where i should

(Marshall Heffernan) #5


The only person who could have helped you would be someone who…

  • Logged onto the plYoung forum to see that you needed assistance
  • Had free time
  • Has experience working with Virtual Joysticks
  • Knows how to create / edit plyGame Character Controllers
  • Knows C#

I think it’s more likely that you were asking for something complex, not that nobody wanted to help.

(Jamie pearce) #6

couldn’t be very complex if me someone who has very little coding skill did it and i had one person try to charge me 100$ to do it leslie didnt wanna do it for his own reasons

i wasnt asking for someone to be rude if anything a thanks for finally getting this done would be nice since i spent lots of hours trying to figure it out with my minimal knowledge…
yes no one wanted to help FOR FREE and yes your right im sure others who wanted to but couldn’t just wouldn’t respond witch is fine

you took my (no one wanted to help FOR FREE) key words (FOr FREE) the wrong way XD

any way i hope everyone who has been asking for this to get done is happy i know i am
XD im more happy about it since im the one who figured it out and had time to attempt multiple times

happy game making everyone

(Der_Kevin) #7

heyhey :wink: thank you for your hard work.
i just tried it but have some problems:
ive imported the latest plygame in a clean project (unity 5.3.4f1)
then i added the cross platform input assets
then i exported the sample_ui.unitypackage to get the rpg_ui scene

then i added the new PlayerTopDownController,cs, Joystick2.cs and Top Down Camera.cs and just placed it into the Asset root folder.

the erros i get now are:
Assets/TopDownCamera.cs(10,7): error CS0246: The type or namespace name UnitySampleAssets' could not be found. Are you missing a using directive or an assembly reference? and Assets/Joystick2.cs(4,7): error CS0246: The type or namespace nameUnitySampleAssets’ could not be found. Are you missing a using directive or an assembly reference?

can you help me out there? :slight_smile:
again, thanks for your hard work!

edit: changeing using UnitySampleAssets.CrossPlatformInput; to using UnityStandardAssets.CrossPlatformInput; seams to get rid of the error. lets see if it still works

edit2: works now. thanks :slight_smile:

(Jamie pearce) #8

im glad you figure that little thing out cause the error was stating that the path did not exist so it couldnt find what you where looking for but since you fix the path in script to find your path it works im sure your small issue and solution will help others that have this issue

and no problem a mobile game has been a plateform to build on since i first got plygame

ill make 3rd person scripts some time for thous people making single player 3rd person games XD

(Jamie pearce) #9

Update* Third person character controller and camera scripts

leftjoy use horizontal and vertical rightjoy use horizontal1 and vertical 1