DiegoM's Recent Forum Activity

  • dop2000

    I have been wondering where I should draw the line for this feature. This was developed in response to a suggestion (which I can not find) and the original idea was to provide a more convenient way to import entire animations, that should have been it.

    Your suggestion will likely be the last thing I will implement for this feature. The only problem is that it's a little more involved than the last two things I added (and I still managed to completely botch that!)

    I really don't know when I will work on it, so I can't give any estimates. I do want to implement it because it seems like a good addition before shelving the whole thing, that is as much as I can say.

  • newt

    There won't be a .1 release to fix the Animations Editor issue. The fix will come in the next beta release.

    I know it sounds like a cop out, but that is the point of the quick beta release schedule.

  • ninowebs

    A bug was introduced in this version which is causing most of the UI related to importing images files into the Animations editor to crash. The issue will be fixed for the next beta release.

    In the mean time you can still import images by dragging and dropping.

  • Let me update the first post with the new changes.

    Edit: Just updated the first post, let me know how it works for you.

  • It makes sense that if you pass 0 to the function it would do something strange.

    LoopIndex gives you a number as the loop moves from the start index to the end index.

    So in this case, if the start index = 0 and the end index = 0 - 1, then the for loop will be executed two times. The first time loopIndex will be 0 and the second time loopindex will be -1.

    If you plug those number in the calculation it is doing to place the bars, you will see it places the first one with no offset, and the second one to the left of the first.

    The function should have a special case for 0, so that it doesn't even go in the for loop and just exits early after destroying all the existing instances.

  • "Amount" is the function parameter for "CreateItems", function parameters look like local variables. You can try right clicking on top of the function and selecting "Add parameter" to see how adding more would look like.

    When the function is called, "theNumber" is passed in so then inside the function "Amount" takes that value. For this contrived example it wasn't really necessary, just using "theNumber" inside the funtion would have worked the same. If you try replacing "Amount" by the "theNumber" in the for loop, it should be the same.

    The reason I have the loop starting at 0 and ending at amount - 1, has to do with the calculation to position the items. I want the first LoopIndex to be 0, so the first item will not have any offset applied to it.

  • This is one way of doing it.

    dropbox.com/s/8u9ml9l2mld32pp/generateObjectsToMatchNumberCount.c3p

    The example doesn't do line breaks, so all the items are added in a single line, but it's a good starting point.

  • Look into the Set Instance action of the Timeline plugin.

    The Timeline Instances example project in the Start Page is a basic example of how to use the action to re-use a timeline animation with multiple different instances.

  • I think the issue is that the crouching animation is playing WHENEVER the arrow key is down and the uppercut, only when W is pressed.

    So what ends up happening is that the crouching animation is played, then for a brief moment an attempt is made to play the uppercut animation when W is pressed, but because the down arrow is continuously pressed, the crouching animation takes precedence.

    I think that you need to set a boolean variable when you press W to indicate that an attack has started and while that variable is true don't play the crouching animation, then it won't step over the uppercut one.

    You will need another event to know when the uppercut is complete, so you can reset the boolean and allow the crouching animation to play normally.

  • An easy way of doing it without scripting is to use the Load image from URL action on a Sprite instance.

    When that is loaded, you can use the Paste object action of Drawing Canvas to copy the image data over.

    After that you can get rid of the sprite instance.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Cool, well done!

    Before I forget, yesterday I found the full reference for the library, but it's a bit hidden away. It's very useful when you go past the basic examples.

    docs.mongodb.com/realm-sdks/js/latest

  • I am just guessing here, but judging from the console errors, there seem to be syntax error in either here

    const mongodb = app.services.mongodb("mongode-atlas");
    

    In this one, I don't think app has any property called services. Maybe you need to do something like this

    const mongodb = app.currentUser.mongoClient("mongode-atlas");
    

    Haven't actually tried this myself, just stitching together things I find that look like they make sense.

    The next line

    const collection = mongo.db("ServerDB").collection("UserAccounts");
    

    I think should be

    const collection = mongodb.db("ServerDB").collection("UserAccounts");
    

    Maybe that won't blow up, but it is still not doing anything useful, just getting some objects.

    Next you can try with

    collection.updateOne({ $set: { myNewProperty: "foo" } })
    .then(() =>
    {
     // Refresh the user's local customData property
     return app.currentUser.refreshCustomData()
    })
    .then(() =>
    {
     // try to console.log the custom data here to see if something changed
    });
    
    

    After doing this also check the database, to see if that was updated.

    I don't think I can help anymore without actually working on this :P

DiegoM's avatar

DiegoM

Member since 24 Apr, 2015

Twitter
DiegoM has 1,401,051 followers

Trophy Case

  • 9-Year Club
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

15/44
How to earn trophies

Blogs