R0J0hound's Forum Posts

  • 1)

    There probably are enough.

    2)

    Check the blog for the future plans. They also say they are doing well. Will C3 still be around in three years? Probably.

    You could learn JavaScript to make plugins.

    3)

    Pc’s are more powerful but it’s still possible to need to be concerned about performance.

    4)

    It’s dead simple. Why not try it?

  • How do you know you need that? Have you trie changing it to textarea intstead of text. That will let it be multiline

  • When you call the function you can pass the uid of an object as a parameter. Then in the function you can pick the sprite by uid.

    Start of layout

    Pick random sprite instance

    —- function: call “foo” (sprite.uid)

    On function “foo”

    Sprite: pick by uid function.param(0)

    —- do something with sprite

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • With unbounded scrolling on, make a duplicate of the tile map and put it right above the layout and another right below. The jump from moving the player from the top to bottom should be mostly undetectable. The wrap behavior is likely not sufficient so you’ll have to do:

    Player.y<0

    —-set y to self.y+layoutheight

    Player.y>layoutheight

    —- set y to self.y-layoutheight

    So basically you’re just duplicating everything to make it look seamless. You can probably get away with one deplicate instead of two if you position the duplicate depending if the player is close to the bottom or top. Moving objects can be trickier but the duplicate is always at the same offset from the original, a y difference of layoutheight.

    I’ve also used the paster object instead so that you draw the bottom part of the layout to it and move it above the layout when the player is near the top. The bottom is handled in the same way. Tile maps won’t work as is with paster because only the tiles onscreen will be drawn as an optimization. The trick to make it work is to move the paster and tile map objects onscreen first before drawing.

    Either of those will make it look like it’s seamless. Next thing to deal with is making stuff work across this seam. They’d have to be handled on a case by case basis.

  • That should be the case. Maybe post a screenshot of the event.

  • Just do it with events. Give the robot three variables vx=0, vy=0, and gravityStrength=400. In the click event it shows how to set vx and vy from a speed of 200 and an angle of 45.

    Global number gravityDir=0

    for each robot

    --- set gravityDir to angle(robot.x, robot.y, planet.x, planet.y)

    --- robot: add self.gravityStrength*cos(gravityDir)*dt to vx

    --- robot: add self.gravityStrength*sin(gravityDir)*dt to vy

    --- robot: set postion to (self.x+self.vx*dt, self.y+self.vy*dt)

    --- robot: set angle to angle(0,0,self.vx,self.vy)

    on click

    --- create robot at (player.x, player.y)

    --- robot: set vx to 200*cos(45)

    --- robot: set vy to 200*sin(45)

  • To arrange the sprites like in your example you can do this:

    for each sprite

    --- set position to (lerp(100, 300, loopindex/(Sprite.count-1)), 400)

    100 if the leftmost x and 300 is the rightmost. 400 is the y.

  • I won’t be doing that.

  • Deformations can be done without webgl. I’ve done it before in plugins, it’s just not super fast.

    If you want to do deformations now, there are a few plugins that can be used.

    For one, there is the creature2d plugin. It does mesh deformations but you have to design them with the creature2d software. There may be another plugin for some other animation software as well.

    If you want to do the deformations manually with events. There is the custom draw and paster plugins. They both let you draw deformed quads. Combine multiple quads together and you can get some nice effects. The paster examples are a bit harder to find in the plugins topic.

    If neither of those float your boat then you can make your own plugin I suppose. The sky is the limit.

  • Ai can be many things. You’ll have to break it down in more detail what you want the enemy to do.

    By doing that you should be able to have a lot of simpler things you can figure out how to do easier.

    Then if you still get stuck you’ll have some more specific questions and be able to get more specific help.

    Anyways as broad a question as it is you could look into the pathfinder or line of sight behaviors as a start. But there is a lot more different ways to do ai.

  • There isn't any expressions to get the current effect parameters.

  • You could use a global layer to be DRY.

  • You could try the persist behavior. It makes things stay the same when you leave a layout and come back.

    Another idea is to just have the inventory on a layer that you keep hidden most of the time.

  • It's just a matter of saving the position of one of the objects to some variables and then setting the position of the objects to the other.

    global number tempx =0

    global number tempy = 0

    start of layout

    --- set tempx to sprite.x

    --- set tempy to sprite.y

    --- sprite: set position to (sprite2.x, sprite2.y)

    --- sprite2: set position to (tempx, tempy)

    For the example of swapping pieces around, i'd assume they are all instances of the same object type.

    global number tempx =0

    global number tempy = 0

    global number iid1=0

    global number iid2=0

    start of layout

    repeat 100 times

    --- set iid1 to int(random(sprite.count))

    --- set iid2 to int(random(sprite.count))

    ------ pick sprite instance iid1

    --------- set tempx to sprite.x

    --------- set tempy to sprite.y

    --------- sprite: set position to (sprite(iid2).x, sprite(iid2).y)

    ------ pick sprite instance iid1

    --------- sprite2: set position to (tempx, tempy)