LittleStain's Forum Posts

  • Found this topic using the search, might be of help:

  • It's rotating towards the player..

    If you don't want to use the rotation you can turn it of in the properties..

  • Take a look in this .capx:

    https://drive.google.com/file/d/0B-bh_etMDYP_Y3pKRVJXVEtTLUU/view?pli=1

    Are you sure you have linked the right capx?

    This one has nothing to do with pathfinding and/or animations..

    Besides that it's very inefficient, for it can be done with two actions:

    https://dl.dropboxusercontent.com/u/485 ... angle.capx

  • https://www.scirra.com/manual/126/system-expressions

    clamp(x, lower, upper)

    Return lower if x is less than lower, upper if x is greater than upper, else return x.

    so you could clamp the x-position of the sprite by:

    sprite set x = clamp(sprite.x,100,200)

    the x-position of the sprite can only be between x=100 and x=200 this way..

  • So it seems you have created conflicting events..

    Events that are true when other events are also true overwriting certain actions you still want to happen..

    Without seeing the events themselves it would be wild guessing..

    Either look at your events and try to figure out why they conflict with the events you had, or share them here so we can have a look..

  • In what way did you implement the multitouch?

    Are you using the drag and drop behaviour on the players or are you using TouchID, XForID and YForID?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • What are the events concerning the hp and the bar?

    I don't think they should be affected by ai unless you have some conflicting events..

  • I'm not sure what you mean..

    int(random(number, var) just chooses a random number between your number and your var not including var

    random(a, b)

    Generate a random float between a and b, including a but not including b.

  • Seems you misunderstood unlerp:

    lerp(a,b,x) =y

    unlerp(a,b,y)=x

    so

    lerp(0, 100, 0.5) = 50

    unlerp(0, 100, 50) = 0.5

    You are trying:

    lerp(0, 100, 0.5) = 50

    unlerp(0, 100, 0.5) = 200

  • You can get the angle of movement with the expression sprite.pathfinding.movingangle and base your animations on that..

  • The imagepoints (origin and all others) are set inside the editor, I don't think there is a way to change their positon through events..

    You can ofcourse reference the imagepoints and base your events on them..

    What are you trying to achieve and why would that involve changing the position of the origin..

  • How much experience do you have with Construct2?

    Have you followed the beginners tutorials to get a hang of working with events?

    What you are asking for all sounds pretty basic.

    One way would be to give the player bullet behaviour and rotate it's angle towards mouse.x,mouse.y a certain amount every tick, double-clicking increase it's speed..

    For each fish pick the nearest and check if it's bigger or smaller, basing the actions on that..

    etcetera..

  • tested right now the game "STRIKERS 1945-2" its VERY fluid, event when the screen has a HUGE boss, explosions and lot of ennemies, but my game, no, it lags

    Unless you are saying this game was made with Construct2 and/or runs on Javascript/Html5 I don't really get the point..

  • Could you explain what you mean by control point number 0?

    I've never heard of it..

  • So when should the enemy follow the player and when not?

    (what are the conditions?)

    When should the enemy attack and when not?

    Being close could be checked with distance(enemy.x,enemy.y,player.x,player.y) < Whatever amount of pixels you like..

    If you only want to check in the horizontally abs(enemy.x-player.x) should do the trick..

    Fleeing when hurt could be done by giving the enemy a boolean variable "Hurt" and setting it to true when hurt..

    Adding the condition enemy is not hurt to your attack and follow events and adding an event what to do when enemy is hurt.

    It's all about telling the computer when to execute certain actions (when all conditions are met)