Vrav's Forum Posts

  • Such frequent updates, yay.

  • - Improve the Controls system; allow two movements to use separate controls, have a Set control action, allow gamepads and such.

    It would be nice for you to include the full keyboard. I can't test my games in dvorak, where wasd is actually ,aoe... there is no comma or period in the controls or key pressed check. Or at least, that I saw. If I'm wrong, it would be nice to know the way, outside of switching to qwerty every time I wish to test a Construct game.

    Gamepad use would be one way around it, but still.

    "Set control" sounds awesome.

  • It would be useful for development as well, since currently (I think) if you try to update the graphic of a sprite, everything you have put on it is simply thrown away. Disappointing.

    Similar effect when you cut objects from one layer to another. It completely destroyed my code. :\ But! Lesson learned.

  • Why not make a background layer and place everything you need there?

  • Messed with your game when you first posted it... I set ball and particle to Bullet movement, and could get the particles to spray downward, ball to bounce off the bat, but my lack of trigonometric ingenuity resulted in only a basic, fairly incorrect deflection when the ball hit the new wall object I made. So, I gave up on math.

    http://www.mediafire.com/?62tx55scdmx

  • I haven't set it up properly for my game yet, but AutoHotkey is an incredible program once you get the basic hang of redefining keys.

    Tested an old script I used to play an RPG on my 360 gamepad, and it worked fine in Construct. Just so you get an idea of how simple it is, this is the script in notepad:

    Joy6::Send {Enter}
    Joy8::Send {Escape}
    
    Joy1::
    Send {Down down}
    SetTimer, WaitDown, 30
    return
    WaitDown:
    if not GetKeyState("Joy1")
    {
    Send {Down up}
    SetTimer, WaitDown, off
    return
    }
    Send {Down down}
    return
    
    Joy3::
    Send {Left down}
    SetTimer, WaitLeft, 30
    return
    WaitLeft:
    if not GetKeyState("Joy3")
    {
    Send {Left up}
    SetTimer, WaitLeft, off
    return
    }
    Send {Left down}
    return
    
    Joy2::
    Send {Right down}
    SetTimer, WaitRight, 30
    return
    WaitRight:
    if not GetKeyState("Joy2")
    {
    Send {Right up}
    SetTimer, WaitRight, off
    return
    }
    Send {Right down}
    return
    
    Joy4::
    Send {Up down}
    SetTimer, WaitUp, 30
    return
    WaitUp:
    if not GetKeyState("Joy4")
    {
    Send {Up up}
    SetTimer, WaitUp, off
    return
    }
    Send {Up down}
    return[/code:2jusld89]
    
    The only reason I set movement to the keys instead of joystick is because I'm lazy; bear in mind that it entirely possible to customize and macro-ify any keyboard, mouse and gamepad input with an AutoHotkey script.
    
    Built-in gamepad use for Construct would be cool! If you didn't know, you can change global input keys and their aliases when you click your game name in the project pane; 'controls', at the bottom of its properties window.
  • To remove the period, try setting HPcurrent and HPmax to int(); as for the incorrect result, use & instead of + for concatenation.

    Text: Set text to int(RedCastle.Value('HPcurrent')) & "/" & int(RedCastle.Value('HPmax'))

    Or so I would think.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Actually, running it a certain number of times is preferable! That way, there becomes a maximum falling speed. Thanks for the information. My loop seems to have been wrong because it had no ending reassurance, I guess.

    There aren't really bugs in movements so much as... conflicts in what I'm trying to do. For example, I had the pCenter a physics object (this is the object that determines the player's location and momentum), and another physics object, pLowBound, below it that dynamically resized according to the animated limb extents. The detector sits below this as well, also keeping accurate width. When pCenter and pLowBound were both physics objects, the addition of width and height adjustment events made the player freeze immovably after a short movement from its spawn location.

    By now I've made it so pCenter is the only physics object. For accurate ground collision, its pivot is always set to the bottom of pLowBound. For wall surfaces, when pLowBound collides, I set pCenter's velocity to drop, and if due to extra momentum pLowBound manages break the wall object's edge, and overlap, I gently bounce the player in an opposite direction. Should probably make ground collision similar to what I have for walls, but the actual physics object gravity pulls pLowBound through the ground until pCenter hits it if I only work with its collision, as a non-physics object.

    It's still pretty messy, as the physics objects seem to enjoy sinking into one another, but I think by using a single physics object with extra objects attached, I can accomplish what it is I want to do.

  • In an attempt to create my own pseudo-physics platformer without using any of the seemingly buggy movement presets, I seem to have instead created an atomic bomb.

    Setting the player object to Always drop by pCenter.Y + pCenter('gravity'), I tried to create a loop that would, over time, add a number to gravity while the detector does not intersect the ground. Not really sure how to use the loops, though... so I set While as a sub to the Always, with the additional condition that detector does not intersect ground. In that event, gravity is increased by 2.

    Running the program makes it run but not show, and Construct freeze up strangely. My music even started skipping. So I closed construct, restarted, and it was still messed up. So, reinstall. I didn't actually have to restart: done this a couple times, and all one has to do to successfully reinstall is force the Temp.exe process to end.

    So... yeah.

    How does one use loops? <img src="{SMILIES_PATH}/icon_razz.gif" alt=":P" title="Razz" />

  • Tried it out here and everything worked fine - keycount got reduced, door destroyed. So... I have no idea. Check your objects' collision settings?

  • Hey, everyone.

    I'm trying to create a platformer (seems popular) that animates characters based on physics and primitive inverse kinematics. First I made a biped ragdoll, but that was useless, because the physics did not obey my set-force-to-angle commands 100%; the best I got was a limp zombie-looking thing, whose feet fell through the floor, limbs spinning.

    Today I realized I needed invisible objects to just nail the jointed biped graphics onto. So I created a player object, and two feet, and am trying to animate them with cycles of "set force towards position" and velocity added to the player body, a la deadeye's kickit.

    I'm not really a programmer, just an artist, but like messing with stuff like this. As a result, however, there are a bunch of problems I cannot seem to overcome. For one, the feet are colliding with each other, and that is not what I want. Can I make them pass through each other but still collide with the environment?

    Additionally, they tend to drag behind the player. Is there any way to restrict physics movement within a hard radius, dramatically without elasticity? I tried hinge, but it lagged the program horribly. I already have one of the feet set to animate with a force when its position reaches certain coordinates, resulting in forward and backward cycling while the control is held down, but it's difficult to balance masses, forces and everything. And the collisions with pfoot2 are not helping.

    Finally... I can't seem to figure out how to add the ? to a condition, like I see in others' projects. <img src="{SMILIES_PATH}/icon_confused.gif" alt=":?" title="Confused" /> It would be useful to use in a manner similar to kickit, as well. Is there some secret way?