Ashley's Recent Forum Activity

  • Usually this means the device browser does not support the gamma even though the phone does.

    Try building it with PhoneGap or appMobi. Those wrappers can sometimes add support.

  • I've been thinking about the 'Else' condition and how it ought to work. I found some difficult points so I thought I'd post for feedback on how you think it should work.

    Case 1: logic only

    <img src="http://www.scirra.com/images/else1.png" border="0" />

    This is a simple case: the 'Else' runs when 'Variable1' is not equal to 0. In other words, the 'Else' condition is identical to a 'Variable1 not equal to 0' condition, or "If last event did not run" condition. No objects are picked in either event.

    Case 2: picking

    <img src="http://www.scirra.com/images/else2.png" border="0" />

    IMO, this case should work differently to case 1. If it is 'logic only' (runs only if the previous event was false), the 'Else' will never run at all if there is a single instance with X < 320. It looks like the intent with this event is to make objects on the left faded out (opacity 33), and objects on the right normal (opacity 100).

    So this event should run like so:

    1. Test if any objects have X < 320.

    2. Make those instances opacity 33.

    3. In the 'Else' event, invert the picked objects: pick all objects with X >= 320.

    4. Make those instances opacity 100.

    Note this is different to the first case: the 'Else' event still runs even if the previous event also ran. The 'Else' event would only not run if all instances have X < 320, so there are no instances with X >= 320, so there is no need to run the event. So this is different to "If last event did not run". It's more like "Invert the picked objects and run if some are left".

    Case 3: mixed logic and picking

    <img src="http://www.scirra.com/images/else3.png" border="0" />

    This is the difficult one: when should the 'Else' condition run? Which objects should be picked in the 'Else' event?

    I'm not sure what the intent of these events is if someone made them. I can think of two possible answers:

    A) Treat as case 1: simply run if the previous event did not run.

    Problem: 'Else' never runs if a single instance has X < 320. This could be annoying, because maybe the intent was the same as case 2. It could also be confusing since 'Else' running depends on whether the previous event has a system condition. So adding a system condition to case 2 suddenly makes it run like case 1.

    B) Treat as case 1, but tweaked:

    • if Variable1 is not 0, run the Else with all Sprites picked.
    • if Variable1 is 0, run the Else with sprites with X >= 320 picked.

    Problem: this is so complicated I'm getting a headache trying to figure it out. The sprites picked in the 'Else' event changes depending on the truth of a system condition. And the 'Else' event can still run even when 'Variable1' is 0 which is pretty counter-intuitive!

    C) Treat as case 2: pick all sprites with X >= 320, and run the 'Else' event if there are any instances there.

    Problem: The 'Else' condition can still run if 'Variable1' is equal to 0! So the text is always set to "Some other text" if a single instance has X >= 320.

    D) Maybe something else I haven't thought of?

    I'm siding with option A) because it is the easiest to understand. Basically it means

    • if there is a system condition in the previous event, 'Else' means 'Last event did not run'.
    • otherwise, 'Else' means 'Invert which objects are picked and run with those'.

    You can then make it pick instances by rearranging in to a subevent like this:

    <img src="http://www.scirra.com/images/else4.png" border="0" />

    It's now clear that it picks the instances in the Else event.

    This avoids 'Else' still running if a system condition is false. However, it still seems a little complicated to me. It's supposed to be a conceptually simple event that is easy even for beginners to use, but the rules of how picking works still take a bit of thinking and possibly rearranging in to subevents to get it working how you want.

    Does this design for 'Else' sound straightforward enough even for beginners? Will it "just work" and do what you want or do you think you'll be tripped up by the change in behavior when adding a system condition? Is there some other way it could work I'm missing? I'm surprised how complicated the exact definition of this seemingly simple condition is.

    I'd prefer to only have one kind of 'Else' condition which works intuitively, just like you expect it to. I'd really prefer not to have two different kinds of 'Else' condition.

    I can't remember exactly what Construct Classic did, but I do know it was too buggy to use in any serious capacity. (Obviously I want to make it bulletproof in C2!)

    Let me know if you have any thoughts.

  • Thanks, should be fixed in next build.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • simwhi - sounds like the same as this open bug.

    It's a browser bug and should be fixed in Chrome 19. I reported the issue to Google already. You can work around it by having an offscreen text object that you set to 'tickcount' every tick - this ensures the screen updates properly and should fix the problem.

  • MakkaOleba, that's a different issue, look at the error messages - they're different and caused by different things.

    "Audio filename cannot be found in project" sounds like one of your audio files you've imported can no longer be found. Perhaps you deleted it from a folder based project?

    Glad you've got backups set up anyway!

  • I think the Anchor behavior takes a tick to update the sprite position. Try using 'Compare two values' to test tickcount = 2 as an alternative to 'Start of layout'.

  • See Tips for posting in 'How do I...?'. Providing a .capx of what you've tried, or at least a more detailed description, will help you get the answer you need.

  • Try the latest beta release, r85.

  • Thanks, and good luck with your game making!

  • The problem is you just need CallJS and custom javascript to work with LAN preview. Have I interpreted your post correctly?

    I don't really want to make hackish changes or add "dangerous" features to support third party plugins. I think the best solution is to host your custom javascript on the web and include it via a plugin. Perhaps if 'CallJS' had a 'Load external script' action. You'll need to set up cross-domain permission on the server for it to be able to access it from the preview server, but it should be straightforward. Then your work flow can be to develop your script hosted on the server while also working on LAN preview. When you're ready to compile just include the script inline like you'd usually do. Does that sound like it would work?

  • What version of IE do you have installed? The start page is displayed using an Internet Explorer frame, so try making sure you have IE9 installed.

    Other than that try reinstalling Construct 2, maybe some of the files went missing!

  • Can you post a .capx showing the issue?

Ashley's avatar

Ashley

Early Adopter

Member since 21 May, 2007

Twitter
Ashley has 1,774,248 followers

Connect with Ashley

Trophy Case

  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Forum Wizard Made 5,000 posts in the forums
  • Forum Unicorn Made 10,000 posts in the forums
  • Forum Mega Brain Made 20,000 posts in the forums
  • x126
    Coach One of your tutorials has over 1,000 readers
  • x74
    Educator One of your tutorials has over 10,000 readers
  • x5
    Teacher One of your tutorials has over 100,000 readers
  • Sensei One of your tutorials has over 1,000,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • x42
    Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

32/44
How to earn trophies

Blogs