tulamide's Recent Forum Activity

  • Oh Tulamide... where art though??

    I'm very sorry, had no access to the internet while visiting my parents... can't convince them *sigh*

    Well, this is the current situation: Nothing helped! I finally de-installed python and deleted the pythonpath. Still the same error. Your app starts after the 5th error message, but whenever hitting the button, the error message appears.

    I'm not familiar with .dll, esp. how they are managed by the system. I have some backups of older python installs, could they still interfere? On the other hand, I had no problems with other python apps so far (boa constructor, pype, py2exe ...)

    This might be a very special case...

  • But it won't let you change the color

    look for this line in outline.fx

    if (left.a != 0 || right.a != 0 || top.a != 0 || bottom.a != 0) {
                return float4(1,1,1,1);[/code:gzfu65zr]
    
    replace the first three values of float4(1,1,1,1) with your choice as a percentage. They represent the r, g, and b values (the last one is the alpha value). if you are used to working with values 0-255, devide by 255.
  • Downloaded the .exe zip, extraced and started ai_chat_example.exe ...

    "An error occurred in python, but construct is unable to obtain any error information without StringIO.pyc"

    WinXP sp2, complete python installation (2.6) already (maybe pathprobs?), don't know, what sytem information exactly you're interested in

  • I want each enemy to have a little healthbar. So my event looks like:

    For each enemy -> Spawn monster_healthbar.

    I'm have no hand on construct right now. But from my mind: Isn't 'for each enemy' true every tick? If you just want to happen this once you have to further limit it, for example for each enemy that doesn't have a healthbar yet, or something.

  • It seems that Cinema 4D is also very capable of such things.

    http://www.maxon.net/en/products/modules/modules/thinking-particles/particles-in-motion.html

    But, Construct is not designed to be the most flexible graphic creation, but the most easiest and fast game development tool.

  • What it does

    What can be done with Disk.fx? Well, this:

    Heck if we had a radial gradient you could even do a Warner Bros. title screen.

    h2]Original

    Ok, sort of, but at least I try

    The boring basic explanation is, Disk allows you to focus on a part of an object using an oval shape by darkening everything outside the shape.

    Disk takes care of transparencies and semi-transparencies and offers a set of parameters to suit your needs.

    Two useful .cap-files, not only showing the effect in action, but letting you tweak a bit also to get a first impression of the capabilities, are provided.

    One limitation: Unfortunately, the important values of pixelWidth and pixelHeight are always passed incorrect to an effect (at least on my system). So there is no chance to take care of the aspect ratio. In other words, you will only get a perfect circle, if the object the effect is attached to is of a square size. I first thought about letting you pass the aspect ratio manually, but I rather decided to do an update when the bug is corrected.

    How to use it

    • Size Defines the size of the shape in percentage of the object's size.
    • Horizontal Center Defines the horizontal position of the shape in percentage of the object's width.
    • Vertical Center Defines the vertical position of the shape in percentage of the object's height.
    • Smooth Border Defines the smoothness of the shape's border (0% = sharp, 100% = gradient to the center).
    • Darken Defines, how much the area outside the shape is darkened (0% = White, 100% = Black).
    • Opacity Defines the opacity of the darkening color (0% = Transparent, 100% = Opaque).
    • Replace Content *Handle with care* A simple switch (0 = Off, anything else = On). Almost always you don't need Replace Content. But in certain situations it can be useful. For example, if you want to use a Tiled Background as a layer effect (TB uses less VRAM than Canvas), you can setup a very small empty image in the TB and then activate Replace Content. It will then draw its own image with a 100% transparent shape and a darkened outside area. In the car.cap Replace Content is used on a Canvas to create a subtle dust effect.

    Installation

    Download and place Disk.fx in the effects folder.

    Download

    Disk.fx

    Disk.cap

    Car2.cap

  • Nice one!

    Just one thing: If you want the scanlines to stay with the sprite, when a sprite with this effect moves, you should use boxTop like so:

    float darken = 2*abs((((Tex.y - boxTop)*tot) %1)-0.5);[/code:1d2q3v7p]
    
    Thank you for this one, will play around with the code
  • Coordinates in the runtime go from 0 to 1, from top to bottom and from left to right of the screen.

    In the Editor, though, this is from the edge of the EDITING WINDOW, not the layout, so effects get different coordinates.

    That said, you are testing for an int result of a modulus

    so if you were thinking integer pixels

    vpos=0 -> vpos%2 = 0, darken
    vpos=1 -> vpos%2 = 1, ignore
    vpos=2 -> vpos%2 = 0, darken
    vpos=3 -> vpos%2 = 0, ignore[/code:35mxhfk7]
    
    but the shader is fractional
    [code:35mxhfk7]
    vpos=0 -> vpos%2 = 0, darken
    vpos=0.3 -> vpos%2 = 0.3, ignore
    vpos=0.7-> vpos%2 = 0.7, ignore
    vpos=1 -> vpos%2 = 1, ignore
    vpos=1.2 -> vpos%2 = 1.2, ignore
    vpos=1.7 -> vpos%2 = 1.7, ignore
    vpos=2 -> vpos%2 = 0, darken[/code:35mxhfk7]
    
    As you can see, depending on the size in pixels the effect will look very different.
    
    I recommend the following test instead
    [code:35mxhfk7]if(vpos%2 > 1)[/code:35mxhfk7]
    ALL THAT SAID.... yeah, the diagonal line shouldn't be there at all, and the scanlining should be regular, so yeah it looks like a bug in effect coordinates.....
    
    MORE TESTING REVEALS that this effect only happens when there's more scanlines than physically possible (half the vertical resolution). Why? no idea, but while testing, I ended up writing a full scanlines shader, so here it is.
    
    EDIT: Posted as addon: [url]http://www.scirra.com/forum/viewtopic.php?f=29&t=5643[/url]
    you may change number of shown scanlines, scanline width and intensity of the effect. No offset, because I didn't feel like it.
    

    Thank you very much, madster

    I am mislead by "pixelHeight". I thought it was the factor, the height of one pixel in units and that coordinates would give results in units orienting at pixelHeights, so that dividing would lead to integer pixel values. Listened and learned.

    I will post to the tracker, and hopefully find workarounds for the bug in transmitting the coordinates to the shader.

  • Before posting to the tracker, I want to make sure that I am not doing anything wrong. I am currently testing for a few effects in mind, but the results are unexpected.

    For example, this code:

    float4 EffectProcess( float2 Tex : TEXCOORD0 ) : COLOR0
    {
        float4 color = tex2D( foreground, Tex.xy );
        float vpos = (Tex.y - boxTop) / pixelHeight;
        int test = vpos % 2;
        if(test == 0)
            color.rgb *= float3(0.5, 0.5, 0.5);
    
        return color;
    }[/code:20hyqrqi]
    
    leads to this result in the editor (better look at the original size):
    [url=http://www.bilderhoster.net/img.php?id=z5z9wjjs.jpg][/url]
    exactly what I expected. Every second line darkened, beginning with the first line. However, when I run the layout or export to exe, I get this result:
    [url=http://www.bilderhoster.net/img.php?id=hvgyjgwr.jpg][/url]
    
    How come? Any idea, or should I post to the tracker?
  • Select the animation, in the tab on the left side of the editor you will see all properties.

  • I can't for the life of me find that shader now though... I know it's here somewhere on the board. I can't even remember who made it. It's not linkman's hue shader, because that changes all the colors at once, not just one of them. Argh, I really wish people would put their finished plugins into the Completed Addons section

    It is called (tadaa) "Color Replace", created by lucid, and can be found in this thread:

    http://www.scirra.com/forum/viewtopic.php?f=17&t=4234&hilit=color+replace&start=10

    Does the shader take into account semi transparencies, or offer a color range?

    No, and no.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You could count down to zero over time. In another event you could use a random value for milliseconds to take the current value and present it.

    -Every 5 milliseconds

    -Every random(1000) milliseconds

tulamide's avatar

tulamide

Member since 11 Sep, 2009

Twitter
tulamide has 3 followers

Trophy Case

  • 15-Year Club
  • Coach One of your tutorials has over 1,000 readers
  • Email Verified

Progress

17/44
How to earn trophies