x


Can I change movement from Unity 3d into Unity 3D iOS

Hi i'm newbie please suggest me about how to adapt control of movement in Unity 3D into iOS device any one who want to help me and any one who have informations about development of iOS version please tell me :) Thanks so much .

more ▼

asked Aug 30 '11 at 05:07 AM

panorama gravatar image

panorama
1 9 12 12

(comments are locked)
10|3000 characters needed characters left

2 answers: sort voted first

if u want to using buttons use this it will work in unity 3d and ios

void OnGUI()
{
    if(GUI.RepeatButton(new Rect(Screen.width/10,Screen.height/1.5f,Screen.width/15,Screen.height/10),"up"))
    {
       transform.Translate(Vector3.forward*Time.deltaTime*50); 

    }

    if(GUI.RepeatButton(new Rect(Screen.width/10,Screen.height/1.15f,Screen.width/15,Screen.height/10),"down"))
    {
       transform.Translate(Vector3.back*Time.deltaTime*50);

    }

    if(GUI.RepeatButton(new Rect(Screen.width/40,Screen.height/1.3f,Screen.width/15,Screen.height/10),"left"))
    {
       transform.Rotate(Vector3.down, 90*Time.deltaTime);
    }

    if(GUI.RepeatButton(new Rect(Screen.width/5.6f,Screen.height/1.3f,Screen.width/15f,Screen.height/10),"right"))
    {
       transform.Rotate(Vector3.up, 90*Time.deltaTime);
    }
}

other wise, u can use joystick for the movement in ios. the standard package is present in standard assets mobile in the unity itself.
so u try it once.
In menu->assets->import package->standard assets(mobile)

more ▼

answered Aug 30 '11 at 05:27 AM

mohanrao164 gravatar image

mohanrao164
146 3 3 5

When i add your code It warn Assets/NewBehaviourScript.js(4,67): BCE0044: expecting ), found 'f'. How can I resolve that Thx

Aug 30 '11 at 07:51 AM panorama

actually it is not js script it is cs script. try it in the c# script. u will definetly get it

Sep 02 '11 at 05:31 AM mohanrao164
(comments are locked)
10|3000 characters needed characters left

I will be code in I appreciate in your kindness dude Thx a lot.

more ▼

answered Aug 30 '11 at 05:30 AM

panorama gravatar image

panorama
1 9 12 12

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x1998
x1952
x1362
x1171
x679

asked: Aug 30 '11 at 05:07 AM

Seen: 854 times

Last Updated: Sep 02 '11 at 05:31 AM