dop2000's Recent Forum Activity

  • This event actually works and attack animation starts playing, but you have other events #18 and #19 on the PlayerEvent sheet that immediately change animation back to idle or some other one.

    You have a bit of a mess with different events setting different animations..

    I would suggest adding an instance variable "playerState" and set it to "run", "attack", "jump", "idle" etc. And then create a single event that changes animation when playerState changes.

  • You can add Drag&Drop behavior to the Boombox sprite in my example, move it around and see if the sound area follows it. (it does)

  • Yeah, character position could be saved in an array on every tick, and then "replayed".

    However, if there are lots of other moving objects, saving movement history for all of them could be a nightmare.

    Here is a plugins that may help:

    https://c2rexplugins.weebly.com/rex_tarp.html

    plugin-time-action-recorder-and-player_t79821

  • I really don't understand why there is no "Spawn" action. It's not a deal-breaker, you can always use "Create object" instead.

    Other than that I think SpriteFont is very similar to sprite.

  • Please post a screenshot of your event sheet, or share your capx.

  • You can also use instance variable to store array's UID.

    Add a couple of helper functions for setting/getting values in array by its UID and voilà - you have your array in instance variable.

  • No, you created something very weird <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    I forgot to tell you that before playing the sound, you should check that it's not already playing.

    Anyway, here is the working example:

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

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thanks for the capx. So what's happening is when at least 1 enemy has line of sight, "Else" event is not executed for other enemies, which don't have LOS.

    You need to change your event to this:

  • If you are talking about the project size or performance, then no, adding Browser object doesn't affect that.

  • [quote:3w4z38dp]So when the enemy loses line of sight and doesn't have sight to anything else it should follow the ELSE code and set SeesEnemy to 0 along with EnemyX to 0 and EnemyY to 0, and then find path to its target (didnt screenshot that part)

    The error could be in that part. Could you share the screenshot of all events related to line of sight and pathfinding?

  • If by "using code" you mean "using events", then this works:

    Button Set Text to "?"

    If you meant "by numeric code of a character", add Browser object and try this:

    Variable charCode=981
    Button Set Text to Browser.ExecJS("String.fromCharCode("& charCode &")") 
    [/code:1qkt1a7i]
  • Not exactly...

    Your variable DistanceSoundBomb changes from 0 (complete silence) to 1 (full volume).

    If distance between objects is 1000 pixels or more, then it will be 0.

    You can change "1000" in that formula to 50 or whatever number you want.

    For playing/stopping sound you should use these events:

    System->Compare two values -> distance(detector.x, detector.y, bomb.x, bomb.y) is less than 50 -> Play sound

    System->Compare two values -> distance(detector.x, detector.y, bomb.x, bomb.y) is greater than 60 -> Stop sound

dop2000's avatar

dop2000

Member since 26 May, 2016

Twitter
dop2000 has 280 followers

Connect with dop2000

Trophy Case

  • 10-Year Club
  • Entrepreneur Sold something in the asset store
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Forum Wizard Made 5,000 posts in the forums
  • Forum Unicorn Made 10,000 posts in the forums
  • x5
    Popular Game One of your games has over 1,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • Enduring Visitor Visited Construct.net 90 days in a row
  • Unrelenting Visitor Visited Construct.net 180 days in a row
  • Continuous Visitor Visited Construct.net 365 days in a row
  • RTFM Read the fabulous manual
  • x3
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • x14
    Great Comment One of your comments gets 3 upvotes
  • Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

30/44
How to earn trophies