dop2000's Recent Forum Activity

  • Oh, sorry I didn't realize this post was in C3 forum.

    I think you should be able to use "c3_callFunction" to call back your C3 function.

    It could be something like this:

    In your JS file:
    adsCompleted = function() { 
            c3_callFunction("myAdsCompleted");
    }
    
    In the event sheet:
    Function "myAdsCompleted" -> Set variable gamePaused=1
    ....
    [/code:316tm13t]
    
    See an example in this comment:
    
    (as R0J0hound mentioned, you'll have to rename "c2_callFunction" to "c3_callFunction")
  • Tough luck..

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • This depends on how you made your grid.

    If you are using Tilemap, see SnapX(x) and SnapY(y) expressions.

    If your grid is a bunch of sprites, you can use "Pick nearest"

    Or use a formula like this:

    newX = round(Character.X/16) * 16

    newY = round(Character.Y/16) * 16

  • Is the arm and bow one sprite or several?

    It will be easier to help you if you share your capx.

  • You do not have permission to view this post

  • Yes, "Set angle=No" in Bullet properties.

  • I would suggest MoveTo behavior:

    When all buttons on the keyboard are released, use MoveTo to move the character to the closest cell on the grid.

    You might want to set initial MoveTo speed to Character.8direction.speed.

  • NetOne, thanks for the explanation!

    I'm familiar with the x360ce software, but it doesn't work with html5 games.

    I found another generic Bluetooth gamepad, it's not that old (about 4 years), but it too has the same issue with the right stick.

    So now I have three different gamepads with the same problem...

    I tried RawAxis expression and it does read Right Stick Y position. Axis number is 5.

    So I'm still confused - whose fault is it that filtered input from the right stick doesn't work in Chrome?

    Is it because Scirra didn't implement dinput method, or because Chrome doesn't support it?

    STARTECHSTUDIOS, what gamepad model do you have?

  • Scirra website is very slow, the link does work, just try again.

    If you are reading the questions from AJAX, you need to load them all into the array first:

    Array set size to X=0, Y=1, Z=1

    For x=0 to (tokencount(AJAX.LastData, "|")-1) : array Push trim(tokenat(AJAX.LastData, loopindex, "|"))

    Then pick a random index from the array:

    System -> set RandomIndex to int(random(array.width))

    Then print the question:

    function -> Call "show" (array.At(RandomIndex))

    Then delete this index from the array:

    Array -> Delete index=RandomIndex

  • Ashley

    Like I mentioned in my bug report, I ran tests on two different laptops (Windows 8.1 and Windows 10) and with two different gamepads - Logitech and Phillips.

    On both machines and for both gamepads the Right analog Y axis didn't work in Chrome.

    Maybe the Xbox 360 does work, but all other gamepads don't?

    NetOne

    I just tried axis numbers from 4 to 10 - no luck.

  • Then I suggest you start with tutorials, there are lots about using the arrays.

    https://www.scirra.com/tutorials/all

    To add a question to array:

    Array-> Push "Question text"

    To pick a random index:

    System -> set RandomIndexVariable to int(random(array.width))

    To print picked question on the screen:

    TextObject -> set text to array.At(RandomIndexVariable)

    To delete this index from the array:

    Array -> Delete index=RandomIndexVariable

    I also highly recommend using Debug Mode (Ctrl-F4) - it will allow you to monitor the contents of the array, variables etc.

dop2000's avatar

dop2000

Member since 26 May, 2016

Twitter
dop2000 has 257 followers

Connect with dop2000

Trophy Case

  • 8-Year Club
  • Entrepreneur Sold something in the asset store
  • 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
  • x5
    Popular Game One of your games has over 1,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • Enduring Visitor Visited Construct.net 90 days in a row
  • Unrelenting Visitor Visited Construct.net 180 days in a row
  • Continuous Visitor Visited Construct.net 365 days in a row
  • RTFM Read the fabulous manual
  • x3
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • x13
    Great Comment One of your comments gets 3 upvotes
  • Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

28/44
How to earn trophies