R0J0hound's Recent Forum Activity

  • Try clicking on "Angle: 0 (Right)" on the animator toolbar. That works for me.

    -cheers

  • I used PyShell. It allows you to explore python in construct much like the python command line app bundled with python.

    Open PyShell.cap, add a Sprite and give it the Platform behavior.

    Run the Layout and you will be presented with a prompt.

    If you type dir() you will see a list that contains the names of all the objects.

    dir(SpritePlatform) shows a list of all the python equivalences.

  • It's not listed in the script editor, but it's:

    SpritePlatform.WallRight()[/code:1quy64uv]
  • Just keep track of the previous angle in a private variable like 'oldangle'. Then the delta angle would be Sprite.Angle-Sprite('oldangle').

    + System: Always (every tick)
    -> Text: Set text to "Angular Velocity: " & (Sprite.Angle-Sprite ('oldangle'))/TimeDelta
    -> Sprite: Set 'oldangle' to Sprite.Angle
    [/code:1xanolre]
  • Here's a way to get the correct z ordering:

    + System: Always (every tick)
    -> Sprite4: Send to front
    -> Terrain: Set collision mode to Bounding box
    
    + Sprite4: Sprite4 overlaps Terrain
    + Sprite4: Value 'z' Less than Terrain.Value('z')
    + Sprite4: Y Less than Terrain.Y
    -> Sprite4: Place behind of Terrain 
     
    + System: Always (every tick)
    -> Terrain: Set collision mode to Per Pixel
    -> Sprite3: Place in front of Sprite4
    [/code:1cvfo1zk]
  • The slowdown is due to construct recalculating the collision mask on resized objects for each frame. It's from a fix that I made in construct since 0.9984. Prior to that, the collision mask wouldn't get updated unless the object was resized or rotated. The only drawback is it seems to be one of the main sources of slowdown encountered in projects. The slowdown is avoided if collisions are not continuously compared with animated, resized objects.

    Anyway in your case the solution is to have a separate object that handles all the collisions.

    Here is a fixed cap

    http://dl.dropbox.com/u/5426011/examples2/fixedreadthesigns.cap

    saved with 0.99.94

    Edit :

    DravenX's solution of setting the guy's collision to box will work, but by looking at your Hitbox animations you want the hit box to be smaller than the sprite. In which case another object should be used.

    -cheers

  • The trick is figuring out when the car is skidding, the rest is easy. Basically if the angle of motion is different than the sprite angle then it's skidding.

    Example:

    http://dl.dropbox.com/u/5426011/examples2/tireNoise.cap

    made in 0.99.94

  • Here are two different ways to avoid the crash.

    First way:

    Change event 1 from "Always" to "Start of layout".

    On event 2 change the order of actions so that destroy is after spawn.

    Disable/Remove event 3.

    Second way:

    Add "Sprite6" to the family "Red".

    Change event 4 to the following:

    + System: For each Sprite6
    + Sprite6: [negated] Sprite6: overlaps Red : offset (0,-2)
    + Sprite6: [negated] Sprite6: overlaps Sprite2 : offset (0,-2)
    -> Sprite6: Destroy
    [/code:1sii29ky]
  • To correct the Z sorting you need to move the hot spots in all the Hero and Hero_det animations to the bottom of the frames, and move the hot spot of the Tree down about 8 pixels.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Here's another way to do it with only one platform behavior. You can override controls with the "set control state" action of the MouseKeyboard object.

    + System: Always (every tick)

    -> MouseKeyboard: Set control "Move Left" of player 1 to 0

    + MouseKeyboard: Key A is down

    -> MouseKeyboard: Set control "Move Left" of player 1 to 1

    Here's an example cap.

    http://dl.dropbox.com/u/5426011/examples2/controlswitch.cap

    made with 0.99.94

  • I've had similar issues with global and private variables in expressions. To fix it, specify in the expression what the type of the variable is: int, float or str.

    change this

    -> System: Set global variable 'Maxhealth' to global('Constitution')*32

    to this

    -> System: Set global variable 'Maxhealth' to int(global('Constitution'))*32

    -cheers

  • You need to rename some object and behavior names. Names with symbols or spaces will cause errors when using python.

    Rename "Mouse&Keyboard" to "MouseKeyboard" and rename the "Selection Box" behavior to "SelectionBox" in the objects SelectionBox and Gradient.

    -cheers