iscariot83's Forum Posts

  • 5 posts
  • If you try to take a cube root of a negative number in C2 - for instance (-8)^(1/3), the answer should be -2.

    If I try to do this operation in C2 though, it comes out as NaN. Reading up on it, I'm seeing that this is an issue in some other programming languages, and I'm wondering if this is something that's possible to fix in C2 or not - It seems pretty fundamental.

    Assuming this can't be fixed...does anybody have an easy workaround for this?

  • I've had several situations in C2 where I've wanted to trigger a function call once, and only once, when two objects in different families come within a given range of one another - similar to an 'on Collision' trigger, but I need it to happen before the objects actually collide.

    I've dived into this problem a little bit more tonight, and at first I thought it was a bug, but now I think I may just be misunderstanding something about what's happening in the engine.

    Here's a capx to demonstrate:

    https://dl.dropboxusercontent.com/u/616 ... eport.capx

    In this scene, there are 2 families of squares, Blue and Red. The intended behavior is that whenever two squares in different families enter a radius of 200 px from one another, they should each fire off a single bullet of their color at the closest member of the other family.

    This seems to work fine, except in the case where BOTH blue squares are within range of one or both Red squares - at that point, the event stops behaving as a 'trigger once while true' and starts to fire every tick.

    Can anyone explain why this is happening? I can think of a couple of workarounds for this problem, but I'm more interested in understanding the underlying reason why this particular situation doesn't work.

    And better yet - what *is* the simplest way to trigger an event once and only once when members of different families enter into a given range of one another? I'm looking for a solution where for at least one of the families, I won't know the exact number or type of the family members.

    Thanks for any insight or help anybody can offer!

  • Hey everybody - I have minor snafu I'm wondering about:

    I added a couple of image points to 'all animations' on one of my sprites, and then later realized that I needed to name them differently.

    The 'Undo' function in C2 doesn't get rid of the new image points though - and as far as I know, there's not a way to delete them in bulk, other than going through every frame of every animation and manually deleting them.

    It seems weird to me that there's a quick way to add image points to every frame of every animation, but not a quick way to delete them all (either by name, or index, or something). Does anybody know of an easy way to do that?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Normally that's what we'd do, but we have a dynamic camera in the game, and we need the sprites to still look good even when it zoomed in.

    The really weird thing is that all the other sprites look fine, despite being scaled down equally as much - and the sampling quality ought to be a global project setting.

  • So - this is a pretty specific question/issue I've run into, and I don't know if it's a bug, or if I've got an incorrect setting somewhere.

    If you take a look at the attached screenshot, the archer (3P) looks blocky and pixelated, where as 2P's sprite looks smooth and crisp. (make sure you're viewing at 1:1 zoom - It's a subtle difference, but very noticeable when the game is in motion)

    As far as I can tell, I have pixel rounding ON, Sampling set to Linear, and Downscaling at Medium - And these are all global project settings anyway, so they shoudn't affect one sprite differently from the others.

    All of the source images for the animations are set to the same size as well - The original artwork for both characters is roughly 256x256, so both of these characters are scaled down significantly from full size.

    Does anybody have any insight as to why one sprite might render differently from another like this? Thanks in advance for any help!

  • 5 posts