oosyrag's Recent Forum Activity

  • Compare two values var=1|var=2|var=3|var=4 is equal to 1

    Why not set up 4 conditions and use an "or" event block? It is still one event.

  • Do it manually. On button pressed, set a variable to the character you prefer.

    The keyboard has that expression because it already has a string mapped to every key...

  • Curved or straight trajectory? Straight you can just stretch a 1px tall line sprite as long as you need it, curved you can break it up into x pieces with some creative lerping.

  • Persist will keep your objects from being destroyed upon changing layouts.

    You can also save your answers to global variables, which persist across layouts.

    Honestly though..... Sounds like the wrong choice of tool for your application. Try using a Google form and sheets in Google drive instead.

  • You will learn more in six months by actually trying to do so than you will by spending that time asking people on forums how much you will learn in six months over and over again.

  • Using an invisible helper sprite is perfectly acceptable and recommended for ease of use.

    Otherwise, you may use the viewport expressions to get the edges of the screen and use those as a condition to keep the scroll event from running past the layout edges.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You don't want to add anything to loopindex, as it correlates to your array x index. If you want to set data for your second row, you need to add an action set array at x y, where x is loopindex and y is 1.

  • Ahhh I see.

    I'm not very familiar with XML myself, so someone else may be able to give better input.

    I think the structure of an XML file generally lends itself to describing nested data rather than a spreadsheet like array. It would be more like an object and its instance variables. For an array, it may be better to use a spreadsheet saved as a .csv.

    You also mentioned procedural generation, so wouldn't your array be generated in game? In that case, you can simply save your arrays as JSON, and load that straight back into your array. No need for XML.

  • How is your xml and array arranged? What do you want to load into your array?

    To parse a project file, you will need to request it with AJAX. Then On AJAX completed, you will have access to the contents in AJAX.LastData.

    You can use tokenat or the XML object to pull out whatever relevant information you want to put into an array however you want or into any other data structure.

  • My first attempt: https://www.dropbox.com/s/bwtrse3v6wmth ... .capx?dl=0

    Really clunky but I think it works in all situations. Now to start over with a new approach to try to figure out a cleaner method like yours T_T

    If I run a function like this that destroys and recreates the triangles every tick rather than resizing them, will run into performance issues? Will the UID numbers overflow eventually? Especially if I have a significant and variable amount of them at any given time, such as for the line of sight application.

    I'm figuring drawing triangles with html5's own draw functions would be the most efficient method. Hoping Paster handles the bounding box, collision box, and transparent areas suitably for the purpose of blending modes. I'll experiment a bit with that next.

  • Not exactly what you ate asking for, but generally speaking the better approach world be to "move" the weapon with animation frames rather than fiddle with it's actual position and angle.

    But to solve your problem, set the new position AFTER your every tick event. Remember events run in order from top to bottom, so if you change the position before, the every tick event will just put it back to where it was before.

  • In a very basic sense, everything boils down to object count for the cpu. Animations are objects, particles are objects. It looks like your phone is starting to struggle with 10k objects, although 40+ fps is still rather passable. So try to avoid going over that.

oosyrag's avatar

oosyrag

Member since 20 Feb, 2013

Twitter
oosyrag has 38 followers

Trophy Case

  • 11-Year Club
  • 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
  • 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
  • Email Verified

Progress

21/44
How to earn trophies