mystazsea's Recent Forum Activity

  • So far Untested but ...

    you could try(experiment!) using the invert function and play with that...So like a combination of both overlap and inverted overlap

    so something like...

    is red cube x,y, = black cube x,y ->

    is red cube overlapping ->

    is red cube width,height <= to Black Cube width,height ->

    as a pre check set of conditions

    and then compare it to the next statement

    is red cube x,y, = black cube x,y ->

    is red cube NOT overlapping -> (use the invert function)

    of course this doesnt take into consideration any Alpha transparencies areas that the object may have..

    That I know of

    Its always worth experimenting...You may find out something new and undocumented.....!!! bonus points if you share!!!

  • Just a few ideas....

    I am testing a few of these today...

    pretty sure they will work...

    Yes making smaller wall segments is an option but you could also try adding a few instance variables to the Wall segment and Store "fake" Y coordinates in them...

    Determined by getting the BASE Y of the wall segment and then subtracting divisions of measurement to create the Variable "fake" Y positions.

    then if you game is more or less tiles based you can compare the Units Y axis to the Fake Y coordinates of the wall segment....if you know what I mean...

    For example a Wall segment that was 100 pixels wide but spanned say, 100 pixels in Y coordinates..then you could break the Variables up into proportionate "fake" Y coordinates... at each respective jump in Y difference....Does that make sense?

    Of course you will still need to refine it..but it seems that you are using a sort of Grid based snapping system? try to incorporate that into your grid system...if you are not using a snap to position grid then It may be alot harder....

    You could also use image Points to enable snap to positions set at any interval you like along the wall edge ..then when your attacking units

    get close to the wall you could Snap them to the image points position...

    Or even easier, place a small invisible marker sprite at the wall edge image points which you set up in the animations editor..(let's call them "Attack points")

    Then you can very easily "direct" your attacking units to the wall segments "Attack points" via the "Set VECTOR" or "Set angle of motion to object" or similar functions

    Example image

    <img src="http://s10.postimage.org/prldiunx5/FAKE_BASE_LINE_EXAMPLE.jpg" border="0" />

  • Nope that Method should work exactly the same for the Top down shooter except of course that it wont appear the same....because of the viewpoint..the mechanic is the same the visuals arent but if it was me i would combine the bullet effect with an animation that is called just prior to the Knockback mechanic...this will increase the illusion of knockback if you make your animation believable as well...

  • If your problem is while using the editor ...you might find it easier to select objects from the Project bar list instead unless of course the object you are picking is an Instance of another object ..if so well...within the editor all you can do is remember the coordinates and then move the top object to get the under object...

    unless of course the under object is located on its own layer..if thats the case just disable the top layer ...

    There is a request thread in the general section to ask to address that situation....if its in game you are talking about...Try shinkan's Event:)

  • Or what about just putting a buffer zone sprite around the game grid edge that activates the collision mesh just before the sprite hits the game grid border and falls out? It should work..or use y coordinate value to trigger collision mesh on..for example collision mesh is defiantly turned on at y pos= 700 pixels..with the solid frame border at y pos=750

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • OK...well then the array idea sounds like the best idea..great method but instead...use a data array and a corresponding jewel image array the same dimensions as the data array

    Consisting of preset tiles locked in place that dont move but rather respond to a set of preset rules that relate to what tile was immediately around it..is whether or not a tile is cleared falling or colliding for the first time..its just a numerical system of correlated rulesets.

    using tiled animation framed color sets plus a invisible/transparent tile color frame to represent empty as well as a variable stating what color each tile is...etc

    Then by using the image array and whether or not a grid square not using falling bricks except for determining which color is falling and when it reaches the position...'turn on the preset array colored stone and just turn off the visibility of the falling one ...this way it doesn't matter if your tiles fall out coz you would just turn off their visibility when outside of the game grid area...leaving only the preset image array displaying its color....does that make sense? I hope I am clear enough...the array idea is a good one...just needs tweaking..

  • Yes that's one way....there are plenty of others..

    But the way you chose would also let you set position of the spawner anywhere at anytime during your layout runtime...for any possible event...

    Not just Ctrl click dragging...you could do it via events at pre determined runtime events...

    You have the basic premise correct though.. Bravo:-)

  • What about a simpler approach?...

    By this I mean

    only checking for collisions when the block is actually falling...

    Or

    Checking only once a block has fallen and come to rest...

    Checked by a instance variable?

    This would radically cut down on the number of collision checks...

    As far as I can tell anyway....

    :-)

    Worth a test...

  • Bluephaze is right...that tutorial pretty much covers all you need..

    Fully scripting a complex A.I. can take months to debug .especially for complex environment navigation....but you have to start somewhere and that tutorial is a great place..:-)

  • Ai is complex

    But can be simplified

    You will need some various states of activity for the zombie such as

    1-normal/patrol mode

    2-targeting/targeting mode

    3-dying mode (of course:-) :-) )

    Then Use an invisible helper sprite ...pinned to the zombie ..a fake awareness sight field of view...with the zombie patrolling when the field of view collides with the player you then target lock on by setting the angle of the fov every tick to the xy coordinates of the player...simulating real vision field. ..can also be done for smell or hearing ranges...when this view range is blocked or out of view range the zombie can be told to return to patrol mode...or any other behavior..

    Just remember to reset the fov angle as well

    if you need a full ai

    Stay tuned ..a full featured ai will be released soon on the forums for top down shooters....

    Like this

    http://s17.postimage.org/6u9nqi7gf/Sketch181131154.jpg[ /URL]

  • You are on the right track...see post below for some ideas...I have a full pre formatted customizable plug and play A.I. specially designed for construct 2 and for platformers and 8 direction shooters due out in a few few weeks.. For free as a special gift to all construct 2 users...

    until then see below for a few ideas

mystazsea's avatar

mystazsea

Member since 14 May, 2012

Twitter
mystazsea has 1 followers

Trophy Case

  • 12-Year Club
  • RTFM Read the fabulous manual

Progress

13/44
How to earn trophies