andreyin's Recent Forum Activity

  • Ashley any news on this? It's been almost two months since your last update saying it would be around soon..

  • Have you tested with other controllers? Maybe your controller sets the d-pad as other buttons instead of POV?

  • It seems the next C2 release will have the plugin! HYPE!!

    https://www.construct.net/br/make-games ... s/beta/r15

    [quote:28wv2hr0]Yes, we will also be back-porting this plugin to Construct 2 as well! The next C2 update will also include it

  • You said you are settings something to 1 every X seconds, but are you settings it back to 0 after that?

  • Thanks for your help!

    I noticed that your example has the same bug - if you move the player in front of 2 enemies, and move him just a little out of the LoS of the enemy in the back, this enemy's animation will get stuck (same problem as mentioned before).

    I ended up finding an easy fix though, just had to add "On animation finished" to the enemy.

    Thanks again!

  • GO TCHECO!!!!!

    Very nice as usual man, keep it up.

  • hey 99Instances2Go , first of all, thanks for the help!

    I noticed that this problem is also happening with "if player is overlapping" like you said, and I understand what you mean.. since that certain event is already true, it can't be true again, so this happens.

    But why doesnt it work if I do this:

    This should make these events work for each instance of that object, right? But the same thing happens.. to be honest I've been using C2 for quite a while and have never had a problem like this, maybe I really am approaching this in a wrong way?

    What I'm trying to accomplish is simple - if the enemy has the player in its LoS, the enemy should change animation. When it does that, if the animation frame is = 1, it should shoot a sprite at the enemy. If the player is no longer in the enemy's LoS, the animation should change back to default.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Problem Description

    Line of Sight doesn't seem to activate if there are multiple instances of the same object close of one another.

    Attach a Capx

    https://www.dropbox.com/s/n1ge78vasx2pd ... .capx?dl=0

    Description of Capx

    A single event checks if the enemy has LoS on the player. If it does, then triggers its animation to change once.

    Steps to Reproduce Bug

    • Create an object with the LoS behavior
    • Add multiple instances of it
    • Check if it has LoS on the player and trigger something to happen

    Observed Result

    If enemies are far apart it seems to work, but if 2 enemies are close by only one of the enemies change animation.

    Expected Result

    Each enemy should change animation if the player is close to them.

    Affected Browsers

    All of them.

    Operating System and Service Pack

    Windows 10

    Construct 2 Version ID

    r243

  • You can do that by also having a blank sprite load the tilemap image. Then you can get the sprite's height/width to get those values.

  • What C2 is calling "a new tilemap image" is indeed a tileset.

    Here's an example of how you load different tilesets:

    https://www.dropbox.com/s/us4peovqb1btm ... .capx?dl=0

    Each tileset is a separate image. You can check them in the Files folder in the Project Tree.

    Edit: Keep in mind that changing the tile width/height in runtime is impossible, though.

  • Edit: Sorry lol I just read your post from before and my assumptions were wrong.

  • When you create an object, any actions below that refer to that object, so maybe if you do something like:

    Start of layout ->

    create object Tilemap

    load tilemap

    create another object tilemap

    load second tilemap

    It should work. If you want better control over it you can just pick which tilemap you mean using IIDs. Something like:

    Start of level->

    Pick tilemap where tilemap.IID = 0 ->

    Load tilemap1

    Pick tilemap where tilemap.IID = 1 ->

    Load tilemap2

andreyin's avatar

andreyin

Member since 11 Jan, 2010

Twitter
andreyin has 1 followers

Connect with andreyin

Trophy Case

  • 14-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • x3
    Great Comment One of your comments gets 3 upvotes
  • x2
    Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

21/44
How to earn trophies