Rhindon's Recent Forum Activity

  • I FIGURED IT OUT!

    My problem was in the variable I was using in order to identify WHICH ShipCourse objects to update. I was telling it to identify all objects above the variable that counted which ShipCourse to create NEXT and NOT from the value of the object that was deleted! So, if I had created up to four objects, the variable I had been using would have been 4. So if I deleted, say, the first object, the value was still 4 (or rather 3 after calculations), so it wasn't counting all the way back to the first object which was the deleted one.

    I created a new variable that stored the value of the deleted ShipCourse object and told it to update all objects AFTER that value (the one that was deleted). Thank you, guys, very much for your help all the same! I'm very grateful for your time.

  • WOOPS! The edge of the picture cut off the details of what I'm trying to do.

    tarek2 - Thank you for your capx. That's pretty much what I'm trying to do, yes.

  • tarek2 - Thank you for pointing that out to me. The action should have been Subtract 1 from Self.OrderID. I have now corrected that.

    The "Battlefield" is a space on the screen where all the action takes place. I don't want the player tapping just anywhere and the destination markers (the ShipCourse objects) appearing where they shouldn't. The player can tap elsewhere on the screen, such as selecting a weapon type, as well. So the goal is to designate where the following actions will take place.

    Here's how it should go...

    https://www.dropbox.com/s/jq4228tm8le6mm3/Space%20Shooter%20RPG%203.png?dl=1

  • So this is what I edited my event sheet to...just as you suggested along with the particulars for what I'm trying to do...

    https://www.dropbox.com/s/7wjnn7vs33kdxhk/Space%20Shooter%20RPG%202.png?dl=1

    The OrderID instance variable is pre-assigned to each of the ShipCourse objects.

    Each ShipCourse object has animation frames (speed 0) of all the ShipCourse images lower than itself, as well. So, if ShipCourse3 (one of the objects in the ShipCourse family object) has its OrderID value decreased by 1, it will then appear to be ShipCourse2, and so on until it is destroyed. Basically, each ShipCourse object simply updates its appearance when an instance object is deleted.

    The check on the OrderID value is just to make sure that ONLY the ShipCourse objects that were created after the one being deleted are updated in their appearance.

    All that said, I implemented your advice and it still will not work as it should.

  • Thank you, The multiple "Is Touching" conditions are to make sure certain events don't take place - such as tapping an enemy, which is later going to be used as a different feature. I'll implement your suggestions and see how it works!

  • Please bear with me, this issue I'm having has a few facets to it. I'll try to be clear and brief as possible. Thanks in advance for your help and suggestions.

    I'm working on a "turn-based" style of mobile space shooter. Every wave is preceded by an opportunity for the player to tap in the "action area" (where the spaceship and enemies exist) and lay down up to five destination points. Upon activating the action for that wave, the spaceship will follow those points in the order they were created. During this pre-action phase, the player can tap any existing destination point already laid down to delete it. Any destination points that were created after the one being deleted will have their order values decreased - so destination point 4 will become the new 3 when destination point 3 is deleted.

    This is a screenshot of my current set up - and I've tried SEVERAL variations (including using a tilemap...but I couldn't work out getting the correct X/Y coordinates for Pathfinder to follow).

    https://www.dropbox.com/s/tcsw8znp9g8enax/Space%20Shooter%20RPG.png?dl=1

    The problem I have discovered is that the deletion portion of my script here acts immediately after the creation of the ShipCourse objects, even though I added the stipulation of ON TOUCH END. It shouldn't delete anything YET because the object hasn't even been created until AFTER the touch is finished. At least...that's the check-n-balance I'm trying to work out. I've also tried using the ELSE condition to differentiate between when a ShipCourse object is being created or deleted.

    I am quite certain there's a nuance in the way C2/3 reads conditions versus how I understand them. I'd be very grateful for some insight and help. Thanks again!

  • Ooooh, okay. I see. I guess I didn't realize to what extent the On Touch End worked. Alrighty then. Thanks, guys!

  • I'm not sure that will work. Do you mean to use those two conditions in the same singular event line?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The subject line says it all.

    While there are condition checks for when a Touch comes to an end, there's nothing for when touching a specific object stops. This can be very handy for when, for example, a player is holding a long-press over an object (or dragging said object) and then releases it. You don't want to test SIMPLE when the long-press is released, but when a long-press over an object is released.

  • [Please pardon my exuberant emotional outburst of joy. ... Given my struggles at game design and learning C2, I feel I've earned it. LOL] IT WOOOOORKED!!!!! Absolutely PERFECTLY!!! Exactly as I planning. Thank you again!

  • DUUUUUUUUDE!!!! So obvious, ! But leave it to me to miss it. LOL I will get to work on that and see if it meets my needs...but I'm pretty sure it will. Thank you so much!

  • Helloooo.

    I'm working on an interface where the player clicks/taps on a cell in a grid and that cell is labeled with a value of 1 through 5. First click/tap, 1; second click/tap, 2; etc. At any time, the player can deselect any of the highlighted cells. Thus, if 1 through 3 is selected and the player deselects the 2 cell, the 3 cell becomes the new 2.

    The purpose of this is because my character will follow the customized path devised by the player - the order of the selected cells will determine that path.

    I initially figured using an array and pushing the UID of that selected cell node onto the back of the array. No problem there. Adding the UID values into the array is good.

    The problem is IDENTIFYING the correct index in the array that has the UID value of the cell node when DESELECTING it (and thus deleting that array element).

    So far, I can't QUITE think of a succinct method to DESELECT cells and thereby update that order of selected cells.

    Any suggestions? THANKS!

Rhindon's avatar

Rhindon

Early Adopter

Member since 8 Jan, 2013

Twitter
Rhindon has 2 followers

Connect with Rhindon

Trophy Case

  • 11-Year Club
  • 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
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

18/44
How to earn trophies