Ashley's Recent Forum Activity

  • I've evented a motion blur in Construct and it runs very well (my GeForce 8800 GT can manage 1500-8000FPS constantly, depending on blur distance), and without the step-aliasing in your pictures. However this is not a true motion blur, I find if you move the object slowly, it becomes slightly transparent - this is not realistic, because at least some areas of the object will be opaque, where there has always been something in the way over the "exposure". It's probably because the algorithm you state does not blend equally each rendering, but rather is only tending towards the correct value - for example, drawing two 50% transparent objects over each other gives you a 75% opaque image, so this method of rendering is not accurate for a motion blur. Still, interesting technique, I'll see if it can be refined - it still looks great!

  • I want to do this, but I haven't managed to dig up any information on a fast variable-radius gaussian blur algorithm. If you open the .fx files in the Effects folder for the blurs, you'll see they're hard coded with the blur values for 13 pixel blur. If you can find any more info on this, I'd gladly have a shot at variable blurs!

  • The turret object doesnt require a base object - it just enables the turret to rotate realistically with the base, if there is one. It's optional.

    I can add both an RTS and Turret movement to an object... is there some kind of bug with that?

  • [quote:22ae0mvf]Physics -> Set Velocity

    X: MouseX - Sprite.X

    Y: MouseY - Sprite.Y

    Awesome! Also, if you use:

    (MouseX - Sprite.X) * 3

    (MouseY - Sprite.Y) * 3

    it follows the mouse quicker (you can use other values like 2-5 to adjust this), but also means anything it hits is batted away with more force.

    I hadn't been able to figure this out, but thanks for the find, might be able to adapt this to other movements

    As for the .cap, sorry, looks pretty junked up, not sure if I can do anything about it I'm afraid

  • This is a really nice effect, but I don't think it can be done as a pixel shader - shaders themselves can probably do it, but limitations (such as bounding boxes) that Construct places on shaders makes it difficult. It could be coded as a 'movement', i.e. you add it on to the object and it changes how its drawn (a bit like what Rich said). This has the added advantage it doesnt actually require any pixel shader hardware - it's just drawing the sprite a bunch of times!

    Also I'm pretty sure this would look better in Construct - since Construct uses floating point X and Y coords, you wouldn't get any of the step-aliasing I can see in your screenshots, if you look closely, especially in the first and last pictures. However, I still don't think it's a true motion blur - you can see outlines of the original image at the first and last position, when really no individual image should be visible. Ideally, each step should be rendered and blended equally to a final image (temporal anti-aliasing), but this is probably near enough for most uses.

    I'll see if I can come up with something for the next build!

    Another more interesting idea is full-scene motion blurring which is possible with temporal anti-aliasing - but this is trickier, I'll have a think about that...

  • MMF effectively uses a huge texture the size of the frame for the background, and when you paste something it modifies this texture. Construct does not have any texture for the back of the layout, because it limits the size of the layout to the amount of memory you have: a relatively modest 5000x5000 area would take up at least 75mb of memory in MMF, but in Construct, it doesn't take up any at all. I think they have a virtual size feature which works around this, but I guess you can't paste anything past the actual size. A large 50,000 x 50,000 area would use a rather prohibitive 7.5 gigabytes of memory for the background, whereas Construct would still use no memory.

    So this is why you must create objects instead of pasting in Construct. But there's no object limit in Construct and sprites with a single animation with a single frame to display, which are not moving (aka a static, unchanging sprite) are highly optimised and you should be able to create them in the high tens of thousands before the object count starts impacting performance.

  • I would give the turret movement another shot - it does the range checking for you, and it does it very fast and efficiently (it's compiled, optimized C++ code inside the plugin rather than events). So on the contrary, it would be a waste of resources to get it working with events when the turret movement can do what you want!

  • Yeah, the solution is in the question

    15 % 6 = 3

    Both sides of the % must be integers.

  • That should work fine. Try an event like this:

    + Always

    : Sprite - Set Y to .Y + 1

    using .Y is a shortcut for Sprite.Y if it's an action in the same object.

  • I don't think 'random' can take a negative value. By saying random(0-639) you're not saying between 0 and 639, you are literally saying zero subtract 639, which is random(-639), which probably isn't doing what you want it to. random(640) goes between 0 and 639 inclusive, which is probably what you want.

  • Deleted other thread, please don't cross post! Happy birthday for saturday

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Instead of 'print randchar[cox]', you just need an ordinary Set Text action with a String object. As the expression for the text, you can enter Python("randchar[cox]") - this expression evaluates the Python variable and returns it to Construct. That should do what you need.

Ashley's avatar

Ashley

Early Adopter

Member since 21 May, 2007

Twitter
Ashley has 1,382,887 followers

Connect with Ashley

Trophy Case

  • Jupiter Mission Supports Gordon's mission to Jupiter
  • 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
  • Forum Wizard Made 5,000 posts in the forums
  • Forum Unicorn Made 10,000 posts in the forums
  • Forum Mega Brain Made 20,000 posts in the forums
  • x107
    Coach One of your tutorials has over 1,000 readers
  • x61
    Educator One of your tutorials has over 10,000 readers
  • x2
    Teacher One of your tutorials has over 100,000 readers
  • Sensei One of your tutorials has over 1,000,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • x35
    Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

32/44
How to earn trophies

Blogs