BiffanyPFH's Forum Posts

  • in the game you hold on shift a lot for sprinting, and in a combat move that needs you to sprint + push another button, it doesn't do the move. I tested and its totally due to holding oh shift button - it does work when player releases shift and quickly does the move buttons, but it's really counter-intuitive, i've tried everything i know

    what can be done about this?

  • I guess you can use something like this:

    System-> compare two values -> CSV.At(row, column)=""

    or

    System-> compare two values -> int(CSV.At(row, column))=0

    you are, as always an angel of programming woes. Thank you my dude

  • this question is specific to a plugin (CSV by rexrainbow) but i assume answer may be provided by anyone who used an array in C2: Can i check if a cell in the csv actually has anything in it? - Not "Check if cell is valid" condition, but something like "Check if cell has data" - cause check if valid just gives true regardless of if cell has data in it

    it can also be something like check if cell has "" in it, a.k.a an empty string, that'd do also

    https://c2rexplugins.weebly.com/rex_csv.html am i missing something in these conditions?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • which one is better for performance:

    https://imgur.com/a/g5GuF

    having one object with a collision poligon with a lot of points like this or having a mask object for collision, and copying it to have the same effect? also this is going to be a platform for smaller physics objects to be in

  • my question will be about performance

    info on the project:

    game’s for desktop only, window size is 640, 360

    a character size is 17, 52 pixels, platformer

    i have this NPCMask obj with its AI events set, and this is how i plan to deal with its visuals

    to every NPCMask, “NPCBaseSprite” is attached with “every 0.01 sec, set position to” logic

    Within that base sprite will be “male, female, old, child” animation stripes

    these animations will be assigned to each NPC mask according to their “overProfile” instance variable, which will define if the NPC is old, female etc, like:

    if npc is walking,

       >if overProfile is “old”

          <start walkOld animation stripe on NPCBaseSprite

       >if overProfile is “female” etc.

    so i’ll have 4 whole sets of animations inside this “BaseSprite” object, from punchFemale to runChild - (i dont condone violence to women, that name just seems weird is all<3)

    all of the above is a “must” cause the game is all about lively towns, my question is, as i’ll have like 40 npcs on the largest level (with a small window size - we’ll see like 4-5 npcs at a time, max) - how taxing on performance would this selection of animation sprites in branching fashion be, and is there a smarter way? i especially ask cause i want to know if i can add, not a “must” but “nice to have” addition TO this

    i want to make another variable to the NPCMask, “underProfile” which will have 3 values, and they will define each overProfile’s visual sub category, things like hair additions, hats dresses etc, all as 3 sets each. Most of it transparent, just some costume and hair additions on the animation frames

    so now we have on top of NPCMask, an NPCBaseSprite, and for this underProfile thing i want to add NPCCosmetics, both BaseSprite and Cosmetics objects attached to NPCMask with “every 0.01 sec, set position to” logic

    if npc is walking,

       >if overProfile is “old”

          <start walkOld animation stripe (for NPCBaseSprite)

          >if underProfile is “2”

             <start walkOld2 animation stripe (for NPCCosmetics)

    which will mean on this “Cosmetics” sprite object, i will have 12 whole fuken sets of animations, jumping, crouching punching… seems like im asking for a bad surprise at project end.

    in accordance to expert opinion about performance impact of this method; i might add “ColorReplace” effect on NPCCosmetics, and randomize each hair, skirt etc color at layout start - then ill truly achieve a visually dynamic town

    2 things that seem counter intuitive for performance to me as an amateur:

    1- having 3 objects welded together as NPCs every 0.01 sec, and having 40 of these NPC sets at the same time on “city level” (biggest level on the game) (NPCMask wont be visible in game though, obv)

    2- having loads of animation sprites on a single sprite object, even though only one of the sets will be used per NPC

    i suppose i can also have different masks and event chunks and different sprites for each “overProfile” instead of this singular method, but i dont know which would be more performance friendly

    can someone just tell me “naaah, ur worrying too much my dude! Knock yourself tf out, hell, make 5 underProfile visuals for those NPCs!”

    please

    all wisdom is appreciated

  • when you mirror an object, it's LOS 0 angle turns with it, if thats helpful

  • scared of performance issues later on, i busted my ass trying to put together a single series/sheet of events for different types of NPC's in my game instead of having different sheet and series for different NPC profiles, such as neutral NPC's, aggressive NPC's, policeman NPC's etc.

    bit.ly/2CWHuAW

    as you see it's for just the collision mask of NPC's, and not the visuals for the actual game,

    but now i have an issue of assigning different visuals/animations ON those collision masks

    my questions to the experts is:

    1- do i even need to bother having a singular series of events like this for all NPC types for performance? Can i just split them and go the easy way?

    2- if not, how can i assign different sets of visuals and animations on a singular collision mask?

    I have this issue as well, particularly in adding, deleting or adjusting instance variables, it makes me wait for a second, and software acts like, it's like scanning all objects and properties, then gets what i want done. And i'm only about 20% done in the project - lord have mercy :>

  • I see you fixed that issue with event groups.

    no i hate event groups after you showed me how much better doing stuff with variables is, this neutral NPC sheet is the old one, enemy one is fixed as you taught me and works like a charm

    so does this by the way, thank you so much. I wouldve probably given up a couple of times if it wasnt for you

    thanks guys

  • bit.ly/2CvzV3S

    I bookmarked the spot

    i'm trying to have the red square (which is mask for interaction) to enable the outline effect on the green npc's, but in a way that stays with the first object interaction until it stops overlapping with it (which is easy) - and doesnt interact with any other object while its interacting with the initial one (this is where i hit a wall)

    btw press "O" for god mode in-game

  • You can't disable/enable event groups if something changes about individual NPC instances.

    When one NPC sees your character, you are disabling "eNPC Basics" and "eNPC States" groups. This affects all other NPCs! So this approach is completely wrong.

    Use instance variables, use For Each loops, different timers. But don't disable groups.

    ooooooooooooooooooooooooooooooohhh, of course. I knew this easily done deactivate/activate group thing i did was gonna bite me in the ass later

    thank you for the guidance sempai

    its not an issue using the group activations for player though right? if i manage it more tidily

  • What are you talking about? Which objects, what actions? There are hundreds of events in your capx, what exactly should I look at?

    haha sorry, i edited the original post it but missed u i guess - my problem is "eNPCEvent" which is for the red aggressive npcs, when one of them gets aggro, all of them move the same as original aggravated one - my question is how do i keep them as individuals

  • I used containers to separate their collision masks and visuals, so thats working fine

    i tried to use "for each" in different methods, as a whole or individual for actions/states in many different ways for the last day, i really hit a wall here

    bit.ly/2EQKmkh

    shift to run, hold "e" to hold on to edges

    problem is with my eNPC (enemy npc) sheet, which are red characters and collision masks on right side of the level

  • I saved it as a GIF.

    thats the problem, GIF messes with color depth - instead of save as gif, export it as spritesheet from Aseprite and animate your animation inside C2, your effect will lose no quality then

    before exporting as spritesheet, adjust borders of your animation frames to the minimum, then add one pixel to all sides. It'll make your job easier inside C2

  • weird question my dude, whatever effect you make, you export a png from Aseprite, and that just has RGB and Alpha in it

    just export the normal image and use webGL effects in c2

    oh if your effect looks really weird, maybe you just lost the alpha channel in the image file, make sure you export as a PNG format, that keeps opacity differences