blackhornet's Forum Posts

  • You are right. I just ran as-is, which was Chrome. Nodewebkit doesn't produce the same results.

  • If tried you samples and successfully sent and received the REGISTER communication. I added some Broswer.Log messages to watch each step.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You've got Parallax on Layer 3 set to 0,0. Put it back to 100,100

  • I'm not seeing that. The red square pins to the black sprite with the hole in the middle and they move around together. It might help if you add a tiled background so you can see the movement. It's hard to see anything useful with a white background.

  • You need to set the position first, then Pin.

  • For one, you can use 'For each', then check your condition. That forces C2 to look at each of your objects individually, rather than lumping them together. Second, a simple state machine typically uses an integer, which you set to constants. So have const: ROAMING=1, FOUND=2, etc. Then you just check each of these values to see what state you are in, and process accordingly. This is similar to the Switch concept.

  • Here's a couple of ways to use the Timer behaviour.

  • I can't post an update right this minute, but you can fix this manually. Just open the behaviour's runtime.js file and replace:

    var all = this.behavior.my_instances.values();

    with

    var all = this.behavior.my_instances.valuesRef();

    I'll update as soon as I can.

  • 'On collision' is a trigger. You can not combine triggers with an AND. You could use triggers to check for the overlapping of both tires. Make the event an OR block then add the second trigger. Then add the sub-condition to check if both tires overlap an object. You may need an invisible object to test overlap, tied to your platform. See if overlapping the platform works first - I can't say for sure.

  • All of the concerns you mention are valid - each device/OS deals with fonts differently. This has nothing to do with C2. Fonts are always managed by the device. The only guaranteed mechanism for all cases is to use SpriteFonts.

  • In that case, you need the opposite. If you want to know who shot which bullet, you store the Enemies UID on the bullet.

  • Just store the UID when you spawn it. Use an instance variable on the Enemy, if that makes sense. This is only if there is one bullet at a time. Otherwise, you'll have to provide more details on what you are trying to do.

    Enemy.StoredBulletUID = Bullet.UID

  • You need to try a few more tutorials. C2 is a repeating script - your event sheet runs every tick, so your event is being repeated constantly. For now add 'On start of layout' and drag your event as a sub-event of it. It will then just run once.

  • You are a victim for the old "can't create an object and pick it until the next top event" issue. Your LogoTrigridPiece objects can't be picked in event 15. This is a known artifact of C2's architecture. You just need to make a second "On start layout" immediately after the first and move event 15 under it. I still don't think it is doing what you want, but this will get you closer.