SullyTheStrange's Forum Posts

  • No prob, sorry I couldn't help with everything. Tell Alex I said keep up the good work. <img src="smileys/smiley17.gif" border="0" align="middle" />

  • db.tt/51KuGhLu

    Alright, this took a while to sort out... At some point I just threw out a lot of it and redid it a different way. Rather than each enemy having a collision detector, I put a single one on Alex's feet -- that gets rid of the problem of trying to keep each one on each enemy. As for the two guys on the right walking straight into the pit... well, I have no idea why that was happening, but if you take out one of the two, it works fine. Hopefully someone else can come in and explain that. <img src="smileys/smiley5.gif" border="0" align="middle" />

    Now, I gotta ask... where are these sound effects coming from? I get the feeling you're recording them yourself. <img src="smileys/smiley36.gif" border="0" align="middle" /> Music's great too, did you make that?

  • Not sure what you mean by "changed at the url", but you could set the original dimensions to variables at the start of the first layout.

  • Shake just the background? I'm not sure if that's possible using the ScrollTo behavior. You might have to do it manually, which would involve making it move in random directions for very very short amounts of time. I don't have time now but in about an hour I could try to whip up an example for you.

  • Hilarious indeed. <img src="smileys/smiley36.gif" border="0" align="middle" />

    db.tt/cVSAsruW

    Ta-da! I added two simple things to make it work. First, a variable for Collision called "ID", which you set to the BlargBlock's UID after spawning it in the start. Second, a condition for the collision event that specifies that it only picks the BlargBlock whose UID matches the ID set to the Collision bar -- that way, only that block disappears rather than all of 'em.

  • EDIT: Didn't check for new posts before I posted, I see you basically have the same thing already. Your problem with all blocks getting destroyed is that the event isn't picking them properly, usually due to how you set up events -- if you post your .capx, I can help you more on that.<img src="smileys/smiley1.gif" border="0" align="middle" />

    First, you want to make the block solid. If you don't know how to do that, click on the block in the bottom right in the object list, then add "Solid" as a behavior in the panel on the left.

    Next, you'll have to make a small invisible sprite following your player. It'll serve as your little "detector"; since two solid objects can't overlap each other, you need something that isn't solid to detect collisions. Have an "Every tick" event that sets the detector's position to your character's X and the top of their sprite (either figure out what that is manually, or say "Player.Y-(Player.Height/2)", since Y is their center).

    Now you can detect collisions between the detector and the block. So on collision between Detector and Block (you can also test to make sure your player is jumping), destroy block.

    This is what I do and works perfectly, hope my explanation was good enough!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • How do you want it to work? After contact with the enemy, do you want the animation to play only while in contact, or do you want it to play until it finishes and then go back to standing?

    Plus, it might help if you upload your .capx so we can see how you're setting it up.

  • Couldn't you just use an inverted Overlap condition instead?

  • This would be pretty convenient, actually. I always set to a 1,1 grid for exact placements and whatnot.

  • Hmm, this is strange... I fixed it, but I'm not sure why it works now and not before. <img src="smileys/smiley17.gif" border="0" align="middle" />

    All I did was change the Sprite - Spawn object num event to System - Create object num at Sprite.X, Sprite.Y. Now the text beneath the boxes reads like you wanted, 1 2 3 4 5 etc.

  • There's no prebuilt way to do it, but setting it up yourself is pretty simple. Here's a way to do it in three short events:

    db.tt/YxbrKASu

    It's mostly straightforward, except for the mid() function if you're unfamiliar with it. Its function is to take a smaller part out of a whole string. It takes three parameters, a text variable (or the string itself, if you want) that you want to display, the letter you want to start on, and how many letters from there you want to go.

    So the way I wrote it is, the variable TextCount is incremented once a tick. Every time it's divisible by 5 (which happens twelve times a second), use the mid function. It looks like mid(Cake,0,(TextCount/5)), so let's break that down.

    Cake is the text variable I made, which says "This cake is delicious!" (yum! <img src="smileys/smiley4.gif" border="0" align="middle" />) 0 is the letter you want to start on, which is the first one, "T". TextCount/5 is how long you want it to go on for -- since TextCount is divisble by 5 every time the function is used, that'll always be a whole number. When TextCount is 5, TextCount/5 is 1, so mid is taking the substring of Cake from letters 0 to 1, which only includes "T". Once TextCount is 10, TextCount/5 is 2, so mid takes 0 to 2, which is "Th". It keeps going on until the entire string is displayed piece by piece.

    Hopefully this is what you're looking for and hopefully my explanation was good enough. <img src="smileys/smiley1.gif" border="0" align="middle" />

  • Alright, that makes it plenty less glitchy, thanks! The remaining problems might be issues with my animation system, so I'll try to work those out on my own.

  • Hey,

    I've been trying to get your solution working in my game, R0J0, but I'm apparently doing something wrong. Would you mind taking a look?

    db.tt/61FvHuSV

    All the events are on the Misc event sheet, under the comment "Vertical". The platform on the right is the vertical one, by the way -- just watch out for that Goomba. <img src="smileys/smiley17.gif" border="0" align="middle" />

  • It happens in Chrome, Firefox, and IE for me. I don't have Opera or Safari but they're probably the same too.

    So I guess it isn't possible to store the mirrored image before it's used? Sounds like that would fix it. Then again, I have no idea how complex this stuff is. <img src="smileys/smiley17.gif" border="0" align="middle" />

  • Easiest way is to make a variable for your character, such as Alive = 1 for when you're alive, and 0 for when you die. Make the score only keep adding when Alive is 1. <img src="smileys/smiley1.gif" border="0" align="middle" />