0 Favourites

Setting walkable space

This forum is currently in read-only mode.
  • Hi guys. I was recently playing with a game idea based directly from my childhood favorite anime movie Laputa. The main game world is made of floating islands on which the player can walk around and do stuff. The problem is quite plain if not dumb but i dont know a proper method of making everything except those islands - off limits. just like with normal islands and ocean/water.

    I am aware that i can just edit the islands colision mask to have a small solid border but that would imprison the player and limitating.

    in normal games you have your gameworld in which you just place obstacle which cannot be passed. i need the exact opposite - to have the whole game world unpassable by default with passable objects.

    Have in mind that i also want player to be able to move across that unpassable space from time to time with use of bridges or ballons or ect.

    I know what i want - but i dont know how to execute it.

    Any ideas? know any methods for simulating this?

  • Construct 3

    Buy Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Buy Now Construct 3 users don't see these ads
  • You could do something like:

    ->sprite compare x value= clamp(.x,platform left edge, platform right edge)

    ->0r

    ->sprite compare x value= clamp(.x,platform2 left edge, platform2 right edge)

    ->0r

    ->sprite compare x value= clamp(.x,platform3 left edge, platform3 right edge)

    -->sprite set sprite.x to .x

    Edit:

    Ok .x just stops it, but you could do a last x using a private variable, or:

    + System: (Sprite2.X) Equal to (clamp(Sprite2.x,Sprite.Left+50,Sprite.Right-50))

    -> Sprite2: Normal user input

    + System: Else

    -> Sprite2: Inverted user input

    .... Kinda works.

    + System: Else

    -> Sprite2: Bounce

    Works well.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)
Similar Topics Posts Views Last Post
Unread hot topic
0 Favourites
Space Zombies by RED BABOON
77 9,768
imothep85's avatar
imothep85
Unread hot topic
88 9,238
goldentreee's avatar
goldentreee
Unread hot topic
56 4,727
MPPlantOfficial's avatar
MPPlantOfficial