sqiddster's Recent Forum Activity

  • No problem... your method is obviously better for a view cone function ;)

  • Dalal, that is all well and good however if you want the view to be blocked by objects, then it is impractical to use a purely logical method - it will be much simpler to use the bullet method.

    EDIT: I just thought of an idea which would be better... Why not just extend a line (make a stretched sprite) from the enemy to the player? Then you can just test if it is overlapping an obstacle, so he cannot then see the player. This is superior to the bullet test as it only requires 1 collision test per tick.

  • EDIT: This method is unnecessary. Go a few posts down.

    With this kind of thing, it is very easy to slow down your game. Make sure you aren't making too many checks per tick.

    Just make the enemy spawn a bullet towards the player then use a loop to move until it hits an obstacle. If it hit the player, he can see him, if not, then not.

    I wasn't sure if you had solved it or not, but there's my method anyway.

  • We discussed this issue a while ago and came up with a few alternatives to fix it.

    Hope this helps you out!

  • I don't know the games you are talking about, but in the FAQ you can see a nice example.

    As you can see it is quite complex, and if you want to do something like this you will have to be quite comfortable with arrays.

  • Yeah, we'll need a capx as this is probably just a logic error.

  • Nice examples!

  • I searched for the word 'card' and these are probably the closest tutorials:

    scirra.com/tutorials/280/creating-a-memory-match-game

    scirra.com/tutorials/277/3d-card-flip-effect

    With C2, you really don't a step-by-step tutorial about how to make your game - it's so easy you should just be able to do it yourself.

    If you have any specific questions for us, we will be more than happy to help you.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • It's really whatever you choose ;)

  • Glad I helped :D

  • You can always resize the invisible rectangle. Seriously, however, it is extremely important to have the invisible rectangle, unless you fancy yourself getting stuck in walls...

  • Probably the best way to do it is this:

    You should already have an object "player" which is an invisible rectangle, and the "player_image" animations are stuck on top of that. If you don't have this, do it now, as it will save you a collision headache in the future.

    Once you have done this, simply add and rename all of the animations in the player_image so you have something like this:

    1_run

    1_attack

    1_walk

    1_jump

    Then you can just add the corresponding other character's animations in the same format.

    2_run

    2_attack

    2_walk

    2_jump

    3_run

    3_attack

    3_walk

    3_jump

    etc.

    Then, you should have a global variable called 'character' or something which will always be the number your character is at the moment.

    Then, in your animations, instead of doing

    set animation to: "run"

    you can just

    set animation to: character & "_run"

    And that should work nicely.

sqiddster's avatar

sqiddster

Member since 5 Sep, 2011

Twitter
sqiddster has 4 followers

Connect with sqiddster

Trophy Case

  • 13-Year Club
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Email Verified

Progress

16/44
How to earn trophies