oosyrag's Forum Posts

  • Does the AI have to play perfectly? If not, then just break down what you would do in any given situation in terms of available information and decision to be made. The key is to really identify why you make the choices you do and translate that into conditions.

    Otherwise, you're gonna need to understand the math behind it or find someone to do it for you.

  • You should do read and follow the multiplayer tutorials.

    You can consider the host to be the "real" game. Syncing refers to updating synced objects' properties (position, angle) on peers to match the host's game state.

    Peers send their inputs to the host via input states or messages, and the host then applies those inputs to the game objects, which are then synced back to peers.

    In a real time game, to hide latency, peers can also apply their inputs to their local copies immediately when pressed by using local input prediction.

    Syncing objects and local input prediction are sometimes not necessary in a turn based game, given that results of inputs are deterministic. That is when the result of any particular input will always be the same on any device. Messages can work fine in this case for peers to communicate with the host either what was input, or the result of what happened after the input (or both). If not using synced objects, the host will then need to forward the same message to all the other peers. Naturally that doesn't apply if there are only 2 players involved.

  • You can have collisions on an animated sprite.

    You don't need them separate.

    I find it is helpful organizationally to separate the underlying collision logic from animations myself. Animations can change shapes, sizes, and origin points which may have an effect on collisions. When dealing with a lot of animation frames or when making changes to animations, it is pretty common to accidentally introduce hard to spot irregularities in regards to bounding boxes.

    Tldr you definitely don't have to, but many people do so as a "best practice".

  • LTS Releases are a kinda a step towards that.

  • There are potential benefits in terms of collisions logic, organization of events, and flexibility of animations. Many things can be done multiple ways. It depends on the preference of the author which way they are more comfortable working with.

    For Demonaire, there are still collisions to account for despite not utilizing physics.

    Speaking in general, for a more extreme example consider a fighting game like Street Fighter, which uses multiple helper collision boxes separate from the animated sprite, such as hitboxes, hurtboxes, and pushboxes.

  • Sorry! My mistake. It was the custom movement behavior that had the accelerate towards position action, not bullet. It should preserve momentum as the object overshoots the target, and gradually decelerate/accelerate back towards the target.

  • Use the bullet behavior. Accelerate towards the player position slowly, every tick.

  • Mostly useless. An aggregation tool that dresses up search results in an approximation that's just good enough so that if you don't have any idea about the subject you're asking about or generating, could possibly fool you into thinking you got a reasonable result.

    As far as code goes, from the perspective of ignorance, it looks amazing, but if you are familiar with the topic at all...

  • Instead of having the correct answer in the event, you could store it in an instance variable instead. Then for each answer box, check if the textbox.text=textbox.answer.

    Not that there's much difference between 60 events or 6000. You're going to need to input the correct answer for each one somewhere anyways, whether it's in instance variables, events, or an array.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • A little late, but that is exactly what the permutation table feature of the advanced random plugin is for in C3. A permutation table is a randomized set of nonrepeating numbers.

    + System: On start of layout
    -> AdvancedRandom: Create permutation with 50 values starting at 1
     // Push permutation table values to array size (0,1,1)
    ----+ System: Repeat 50 times
    -----> Array: Push back AdvancedRandom.Permutation(LoopIndex) on X axis
    
     // If the value 25 is in an index below 20, delete that index, and add 25 at a random index between 20 and the remainingwidth of the array.
    ----+ System: Array.IndexOf(25) < 20
    -----> Array: Delete index Array.IndexOf(25) from X axis
    -----> Array: Insert 25 at index floor(random(20,Array.Width)) on X axis
    
  • Bullet patterns consist of combinations of angles, speeds, and interval. Adjusting the frequency of each of those results in different patterns.

    Even irregular paths generally boil down to changing the angle over time.

    If you can describe a specific pattern you are aiming for, perhaps you can get a more specific answer.

  • I was addressing

    The problem is, once the server disconnects randomly, another peer becomes the host I believe. So when I try to reconnect to that room as the host it can't.

    Peers don't automatically become hosts in an existing rooms if the host disconnects, unless you have them do so.

    There are a million possible reasons you could lose connection over long periods of time, and not all of them are under your control. Best way to proceed is to plan how to manage if and when it does happen.

    Since you also mentioned you did some testing with different browsers, if it's consistently reproducible, submit a bug report. And use the workaround you've discovered in the meantime, if you suspect that it will make a difference.

  • The platform behavior also has vector x and y available and adjustable for momentum purposes, along with moving angle and angle of gravity.

    You can recreate it with physics behavior, it's just going to be a lot more work and you'll probably find less help with it in since it's not common. Good luck though.

  • If you want to use physics for movement, use it exclusively.

    Solid platforms would be set to immovable. You'll need to recreate all the other features of the platformer behavior yourself.

    That said, there's nothing about portals that should need the physics behavior, given that portals are by nature NOT following physics rules, and the physics behavior is doing it's best to simulate real physics. Your decision to rely on physics is probably based on a flawed assumption to begin with.

  • I don't think so actually, Diego did say "when you draw a tile", so if your tilemap is empty (no tiles drawn/added) presumably all those empty tiles (note that tile 0 is not "empty") by default wouldn't need to be considered or have an overhead.

    Regardless, as you mentioned, it wouldn't have much of a memory impact even if it did, relative to image/sprite data.