part12studios's Forum Posts

  • So I've had mixed results and I can't seem to figure out how to make it consistent.

    what i'm trying to do is simply spawn a new object and pin some text to that object.. sometimes it seems to stick.. but other times what i'm seeing is all of the text objects bind to the first object in the scene, even though the item spawns ON each of the unique objects.

    I just can't wrap my head around how when something is spawned it knows to grab THAT copy of a thing and associate with it reliably.

    I tried families but families don't seem to see text objects. I'm using pin and it works, but in this case it's like the second text object pins to the wrong copy.

    and disregard the numeric values.. that's unrelated.

  • yea i'll do that soon. I really want to understand this better and need to to make a proper chat room eventually.

    I think for now i'm going to do away with the peer list for my needs. it's nice but not required for the bbs look.

    just have a big chat room. the only thing i need to work out is how to send a "username" has left the chat room only when leaving, not disconnecting..

    even this is kinda optional, but this would do be a nice finishing touch to the most basic..

    Thanks for the perspective and insight! I didn't realize what i was jumping into. it looks so simple regarding the basic events, but i can see it has more under the surface.

  • oosyrag ok I did some work in here for a bit.. definitely making more sense.. but i'm still having some trouble navigating the proper order of things.

    how do you get the user's peerid? as a host i just see their username in the peer list, not their peerid.. i can get my peerid (thanks for that clarity) so i got that far, but stuck.

    what i'd like to do is something like click the user name and extract the peerid to then be able to successfully kick that person by their peerid as you said..

  • oooo ok peerid.. i'll have to research that. that makes sense.. have to figure out how to find this peerid info..

    as for the other stuff.. it's just confusing as it seems like the terms kinda get interwoven.. but ok thanks for the insight! I'll read up on it and see if i can better understand how to properly call on these things.

    Thanks!

    Caleb

  • Hi everyone, so I'm working on a chat room and I have a few things that are probably easy but just not clicking for me. I'm attaching the project here for anyone who wants to take a look. i'm not changing much about the project.. the big change is simply to allow users to leave the chat room and come back in. This is working great.. but i have two major issues I'm trying to work out.

    1. When a user leaves the room.. others don't see the user leave.. but if the leaving user refreshes their browser, THEN the user disappears for everyone else. I can't find where the logical difference is.

    2. How do you properly use kick feature? I tried to use it and none of my efforts resulted in the user being ejected from the room. The multiplayer options all seem really straight forward so I must be missing something more subtle perhaps?

    It seems like you could simply grab the name of the person you need to kick and kick "username" and it would remove them.. but i feel like maybe there is further logic needed for it to work.

    here is a working example of it. you can actually join multiple times in the same browser with multiple tabs. https://part12studios.com/games/rd_bbs/rd_bbs_62/

    here is the file i'm working from right now.

    dropbox.com/s/g2ixbgaucqa6u21/BBS_Text%20%28updated%20original%29%20with%20exit%20button%203.zip

    I just don't get it.. it does seem like a "peer leaving room" is missing.. vs. "peer disconnected".. but also I just can't see what's going on that a peer refreshing their browser will register a "remove this guy" but my other conditions won't.

    And for the life of my, can't see how i could do it differently to insure any time a person leaves a room, their name disappears for everyone else.

  • Hi there, I have a chat room i'm working on and it's going pretty well thanks to help I have received, but i'm at one of the last important features for it to work right.. gracefully exiting the server and then the ability to come back into it..

    As it is I have a keyboard event and when that's triggered it fires off:

    {"is-c3-clipboard-data":true,"type":"actions","items":[{"id":"disconnect-signalling","objectClass":"Multiplayer"}]}

    I have tried a few other combinations, but it just seems like the only situation that triggers a true "disconnect" is if the peer closes the browser tab the chat is in.. any other attempt to leave exits, but fails to update the signalling server that the person has left on their own and to remove them from the list AND insure they can get back in.

    Anyone know if this is even possible? even the example from Scirra doesn't have a means to gracefully quit. Only to close the browser or navigate out of it.. or refresh..

  • basically could anyone explain / show how i could "roll my own" peerlist object but have it rely on text object instead to insure it can blend with other webgl effected objects in the same layout?

  • ok good to know about that. so if I need a "peerlist" in effect but one that could be managed with a text input or text object, is that feasible? I really need it to blend stylistically with the rest of the page

    part12studios.com/games/rd_bbs/rd_bbs_24

    i'm using the multiplayer example which relies on the peerlist but i'm not sure i understand under the hood how it works.

    Thanks,

    Caleb

  • what's also weird is that while looking at the peer list object in the developer view, it's effected.. it's only at runtime does it seem to ignore the webgl effect on it.

  • I have a layout with layers of webgl effects that are effecting various text boxes, but for some reason it seems that the peerlist object is unaffected by webgl effects that are affecting the other objects on the same layer fully.

    Are lists somehow excluded? i'm using css stylesheet. maybe this disabled the effect and i need to explicitly enable webgl effects to work on it? if so, how?

    Thanks!

    Caleb

  • Ok figured it out. for anyone wanting to do this, the key is using a CSS style sheet. don't let it intimidate you. it's not that bad.. basically:

    1. import your ttf font

    2. add a stylesheet in the file area

    3. past something like this in there (in my case i had a list i wanted to customize and it not be clickable

    #mypeerlist {

    text-align: left;

    font-size: 30px;

    font-family: Perfect_DOS_VGA_437;

    user-select: none;

    cursor: default;

    pointer-events: none;

    }

    4. watch this video, he explains it mostly. the only thing he leaves out is actually showing the font importing part. youtube.com/watch

    5. just make sure the #mysheet matches the tag in the object you want to effect (without the #)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I'm trying to use a custom font. these work fine in other things like the text object, but i am trying to get this same font into the peerlist (list) object which has to be customized with CSS properties.

    i'm wondering if that is exposed to the peerlist object.. i tried to just call on the font name but no dice..

    I'm so close to getting this chat room looking totally sweet. thanks in advance for any insight you might have.

  • yes that was a great suggestion! i didn't think of that.. never change orientation.. perfect!

    now to figure out how to apply CSS values to lists..

  • oh ok yea good thought! ok trying that out..

  • origin point with a text object? are you saying somehow move the text box? i know origin points are good for spawning objects..

    maybe you're suggesting to spawn a individual text reply to a new text object with each entry? that might work actually, though i'd like to avoid engineering that kind of work around..

    another thought was just that every new entry adds an extra line (blank) after each entry..