procrastinator's Forum Posts

  • Interesting. I can't really concentrate with vocals going on. At least you have the perfect background music to pray to God when you run into problems ;p

  • You could do it easily with the Physics object. Have you tried that yet?

    And how does the bullet behaviour not work? What does it do? Not bounce correctly? Have you edited the collision polygon? It's a bounding box by default. Go into image editor, and click the polygon tool at the very bottom of the toolbar on the left, then you can add new vertices and move them to fit your shape.

  • Mode 7 wouldn't be possible because unlike construct classic we have no way to play with the sprite objects vertices. Could be done with Canvas object but it'd be so slow it wouldn't even be worth it. Screenshots of old mode 7 games would seem faster ;p

    Outrun method is definitely possible with the use of many sprites to represent each "rasterline" of the road but you'd have no rotation of the world like in mode 7 games. I've actually done something to this effect to mimic the Space Harrier floor which I could release but it's part of a bigger thing.. if there's enough interest, I could pull it out of my current project as a standalone piece.

    I wonder if the sprite plugin could be modified to give us access to the vertices.. I'll have a look at that over the weekend as it's something I could've done with recently.

  • Happy to hear :) How did you do it in the end then?

  • Another way would be to fire invisible bullets (bullet behaviour) every 2 seconds or so from the front and back of the pirate ship. They'd start off with the same width as the pirate ship, then gradually get bigger as they get further from the ship. This will give a triangular line of sight. If there's a hit, then rotate towards player position.

    Also fire off bullets from the sides. If a side bullet hits the player (before rotation), then player is at the correct angle to fire at. If a side bullet hits the player (while rotating), then stop rotating and fire those cannons! The logic seems sound ;p

    Of course, only fire the bullets when player is within a certain distance.

  • is this doable with Construct 2?

    Yeah it's possible. You'd just create a line sprite for every "scanline" and adjust the Y, height and width based on it's Z position. I'm actually doing something along those lines, but not a road... should be able to show soon.

  • I used that site as a reference a while back to make a example in Construct Classic.

    http://www.scirra.com/forum/outrun-like-racing-game_topic40154.html

    And you kept the site secret from the rest of us eh? tsk ;p

    Awesome example though and so few events. If I attempted that, my events would run into the double figures!

  • I don't know about you guys, but I like to be lazy. Instead of distance checks. I like to use invisible sprites(visible with low opacity for testing) that are pinned to the object(also with the new container object).

    That way you can create your collision polygon either by setting the collision points or creating an image shape to match your above example.

    Yeah I only just thought of that and came back to mention it. You beat me to it ;p

    delgado, I just thought... if it's a pirate ship, wouldn't it fire from the sides? I mean, they'd do the opposite to what you're actually asking - they'd rotate so their sides are facing the player since the sides are where the cannons are.. right?

    Anyway, you can use

    PirateShip.Rotate To Position (Player.X, Player.Y)

    to turn the ship to the player's position.

  • Owe me one what? �1 million? Want my bank details? ;p

    No problem. Glad it helped :)

  • That's right, but I think my logic is flawed. I didn't take into account the angle the player may be facing. Give me a short while. Brain fog ;)

  • It's simpler than you think. TiledBackground is your friend ;)

    dl.dropbox.com/u/666574/peppo%20-%20health%20bar.capx

  • The odd thing is, a few years ago I was doing a slots game and wanted the reels to curve so they looked the part. I didn't realise at the time I was basically using a similar technique to these games! Although, my method was painfully slow (blitzmax), it did work.

    Yeah it's a very nice read. I'd love to see more old games broken down like this.

  • If distance( Pirate.X, Pirate.Y, Player.X, Player.Y ) < 50

    | If angle( Pirate.X, Pirate.Y, Player.X, Player.Y ) < 0

    | If angle( Pirate.X, Pirate.Y, Player.X, Player.Y ) > 180

    | Pirate rotate to the left

    |

    | If angle( Pirate.X, Pirate.Y, Player.X, Player.Y ) < 180

    | If angle( Pirate.X, Pirate.Y, Player.X, Player.Y ) > 0

    | Pirate rotate to the right

    | = "if distance" event block.

    You'll need to adjust the angle tests if you want it within a certain range.

  • Ah sorry, didn't mean to imply C2 had issues with Else. I just meant old habits die hard.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Yeah Else works nicely, but having Construct Classic experience, I tend to avoid Else ;)