Actor control / movement question

harlin36harlin36 Member Posts: 101
edited November -1 in Working with GS (Mac)
Hi all,
I am making a game that requires the character(a flying fat Chicken) to move in a particular way,when I touch the left side of the character I want to propel it right and vice versa. At the moment I can only make it fly in one direction(up)! How do I make it go in all directions so the user has total control of the actor?

Hope this makes sense !

Any help will be greatly appreciated.

Comments

  • UtopianGamesUtopianGames Member Posts: 5,692
    Depend if you want it to go only left right up and down, for eg you could make 4 rules like if touch is pressed and mouse position Y > self.position.Y propel upwards but if you did this for all 4 if you touch the bottom right corner for eg the chicken would propel left up diagonal.

    For the chicken to ONLY go left right up and down i would probably make 4 invisible actors around the chicken constrained to its X Y and offset these.

    Darren.
  • UtopianGamesUtopianGames Member Posts: 5,692
    Made a video for you,



    Darren.
  • harlin36harlin36 Member Posts: 101
    Cheers Darren,this is exactly what i've been trying to do.what a star!!!

    Thank's again,

    Steve.
  • UtopianGamesUtopianGames Member Posts: 5,692
    Glad i could help.

    Best of luck,

    Darren.
  • harlin36harlin36 Member Posts: 101
    How can I make this work on a larger screen? I tried tshirtbooths camera offset fix but it doesn't
    seem to work on this type of actor control.
  • harlin36harlin36 Member Posts: 101
    bummmp!
  • harlin36harlin36 Member Posts: 101
    If this is not possible could someone who knows tell me so I'm not wasting hours trying to make
    it work ?
    It feels like getting blood out of a stone sometimes on this forum!

    Newbies like me depend on people with the knowledge of this program to point us in the right
    direction.

    If it's a matter of having to pay for the expertise please let me know.

    Cheers
  • old_kipperold_kipper Member Posts: 1,420
    When you say bigger screen do you mean on a larger device or within a set camera size with a large scene size that you want to move your actor and camera over? If its the first it should work as is and if it's the second you need to set the camera to be controlled by the actor. The amount of slack in the camera is set in the scene camera control attributes.
  • harlin36harlin36 Member Posts: 101
    Hi old_kipper

    It's a large scene size 4096x4096. I tried tshirtbooths camera offset fix but it doesn't seem to work on this movement ,only when the actor is constrained to the mouse/touch.
    my actor is moved by outside touch meaning if I touch anywhere on the screen the actor
    moves in the opposite direction.
    P.S this is for iphone
  • old_kipperold_kipper Member Posts: 1,420
    Not quite sure of the effect you are after, and I don't know tsb's offset fix. I presume that you want to drive the actor about inside the scene and have the camera follow it? If so have you tried the ordinary control camera behaviour inside your actor? You can also get some interesting effects with this style of control by placing it on a non scrollable layer so it stay central to the camera. Maybe I am just not getting what your trying to do.... it happens.
  • harlin36harlin36 Member Posts: 101
    I already have a control camera behaviour inside the actor but I can't control the actor when it
    gets past a certain point, the camera still follows the actor but the actor will only go up and to
    the right!.
  • harlin36harlin36 Member Posts: 101
    Here is a video to illustrate the problem
  • old_kipperold_kipper Member Posts: 1,420
    It looks like your external actors or control areas have reached the edge and gone off the screen? If this is the case you will have to limit the the bird actor to within an area within the scene so this is never an issue. One alternative is to have you actor bounce on walls set up on the borders of the scene.
  • harlin36harlin36 Member Posts: 101
    Can anyone understand what I'm trying to do?

    At the moment my imac is in serious danger of a good thrashing!!!

    aaaaarrrgggghhh!
Sign In or Register to comment.