Unnatural20's Recent Forum Activity

  • Well, the one piece of advice I could offer without seeing the code would be trying an immediate "Set Car Behavior Disabled" Action on 'destruct'

  • There is an option under the bullet behavior; select your object from Projects list. In the Properties, under Behaviors, under Bullet, under "Set Angle," you want "No" instead of "Yes"

  • I think you want a "for each" condition.

    Click "GoldMine -> Is overlapping player"

    press "C"

    Double-Click "System"

    "For Each"

    choose "Player"

    How does that work for you?

  • Global a=0;

    Global b=0;

    Global NextBlock=1;

    on hit | System -> Set a= (array X of block hit)

    -------------System -> Set b= (array Y of block hit)

    System -> NextBlock = 1 | System -> NextBlock = 0

    ------------------------------------Array.setAtXY(a,b) to "0"

    (subevent) Inventory Value at (a,b-1) = "C" | System -> set NextBlock to 1

    -----------------------------------------------------------| System -> set b to b-1

    (subevent) Inventory Value at (a+1,b) = "C" | System -> set NextBlock to 1

    -----------------------------------------------------------| System -> set a to a+1

    (subevent) Inventory Value at (a,b+1) = "C" | System -> set NextBlock to 1

    -----------------------------------------------------------| System -> set b to b+1

    (subevent) Inventory Value at (a-1,b) = "C" | System -> set NextBlock to 1

    -----------------------------------------------------------| System -> set a to b-1

  • do not need a path. you need to read the data cell array and on the basis of these data, move the sprite

    word "path" means where sprite goes

    example

    where would sprite go in this picture case

  • What would it do if there were two paths it could take?

  • The problem I see is in Event 131, under ">Mouse -> On Left Button Clicked on ObjectsDisp"

    You have, "Inv -> Delete index Inv.IndexOf(ObjectsDisp.ItemGroup) from X axis."

    This can delete the intended object, , or it might instead remove another object with the same item group. However, you always *create* the right kind of object, so you could (as the demo stands) end up with two hoes or two hammers.

    My suggestion: Give ObjectsDisp another instance variable named "SlotNumber".

    Then, in refresh inventory, Inv -> For Each X element (Event 128 or so) add ObjectsDisp -> Set SlotNumber to Inv.CurX.

    Then, in place of what you had, Inv -> Delete index ObjectsDisp.SlotNumber

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • So many questions. Including your .capx would probably help!

  • I'm not seeing your problem? Once I re-implemented the frame fix and origin fix, things seem to work pretty well.

  • zatyka

    Great example! I would have headed towards some sort of tilemap based solution, but this is far more elegant and efficient.

    It is super elegant and very efficient!

    I added it to a .capx with just about 10 events, given that the existence of the objects and their overlap was already there.

    Now, though, I must decide; since my cameras can potentially rotate... do I prohibit rotation? Do I ignore their rotation, and simply estimate coverage? (if this algorithm finds a square rotated 45 degrees, for example, it will treat it as a square covering twice the volume.)

    Do I allow rotation up to a certain number of degrees?

  • This is really cool! But I have a question: in event 11, you set TestRectangleRight to (Xcoordinates.At(loopindex("X")))+(Xcoordinates.At(loopindex("X")+1)-Xcoordinates.At(loopindex("X")))

    Doesn't this always evaluate to the same as Xcoordinates.At(loopindex("X")+1)?

    Approximately the same expression appears for TestRectangleBottom.

  • Can you upload your current .capx?

Unnatural20's avatar

Unnatural20

Member since 8 Jan, 2015

None one is following Unnatural20 yet!

Trophy Case

  • 9-Year Club
  • Email Verified

Progress

10/44
How to earn trophies