MU Soapbox

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Muxify
    • Mustard

    +repose command for TinyMux

    MU Code
    2
    9
    2242
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • skew
      skew last edited by

      Hi all. I've just finished up my latest project.

      The +repose command will pull the last 30 minutes worth of poses that have happened in a room. This is useful for when you spam your screen (+sheet, mail, jobs, etc) and don't want to scroll back up, or if you get disconnected and lose your buffer, or if you join a scene late and miss the scene set/introduction.

      It allows for you to exclude rooms, turn it off in rooms you own, or temporarily turn it off anywhere. You can also clear the repose log.

      Using the command looks a little like this:

      <----------------<< Recent poses as of 16:25, server time. >>---------------->
      
      Pikachu posed at 16:24:
      	Pikachu says "Hello there my name is Pikachu! What's your name?"
      
      skew posed at 16:24:
      	skew glowers. "Don't talk to me, electric rat."
      
      <---------------------------------------------------------------<< +repose >>>
      

      If anyone's interested, it's here: https://github.com/skewskewskew/MUSHCode/blob/master/Repose Reposer <rr>

      As ever, I'll help install and the like, if you want it on your game.

      Known issue: The code uses secure(), which strips your pose of commas and parentheses. This is likely something I could get around, but a combination of limited coding knowledge and already having coded it all before I noticed an issue means this was the best solution. Plus, if someone just needs a reminder of what they missed, it's not a big deal.

      1 Reply Last reply Reply Quote 2
      • skew
        skew last edited by

        Minor update logged in the github.

        It was failing to capture poses started with semicolons and whacks, cause I'm a dummy. All good now.

        1 Reply Last reply Reply Quote 0
        • skew
          skew last edited by

          Major update. Basically my whole way of capturing + storing poses was wrong and backwards. Now using objeval() and some manual securing via edit() (to remove square brackets) and storing the evaluated pose as an attribute.

          If anyone is actually using this (which, really, I think it's just my games), please just treat it as a reinstall. You don't need to redo the initial setup, but changes were made to 5? 6? attributes. You should be able to just copy+paste into Muxify (on firefox, if you're using Windows) and it should work, but ya know.

          Should.

          1 Reply Last reply Reply Quote 1
          • skew
            skew last edited by

            Updated again... I finally tweaked it so \\ doesn't show up on +repose. I might have went overkill, but it now eats every \. I can't really think of any negatives except that, obviously, you cannot use \ in the displayed text of your pose. Does anyone use that, anyways? Just use a / right?

            If you're already using my reposer, you should be able to put this into Muxify and dump it in.

            &f.capture.pose [v( d.rr )]=
            	strcat(
            		setq( l, loc( %# ) ),
            		if( cor( 
            			match( u( d.exclude.rooms ), %ql ), 
            // check exclude room list
            			match( get( %ql/_REPOSE ), off ), 
            // check setting on local room 
            			), @@( If on the no list do nothing else process rest of this ),
            		strcat(
            			setq( u, u( f.secure.pose, objeval( %#, s( %0 )) ) ),
            // Using objeval will eval the string as if by %# (ie, the invoker).
            // This should filter out MOST nonsense people might try
            // f.secure.pose boggles up [] so that should handle the rest
            			setq( c, strtrunc( %0, 1) ),
            			setq( f, first( %0 ) ),
            			setq( e, switch( %qc,
            				:, u( f.format.repose, rest( %qu, : ), pose ),
            				;, u( f.format.repose, trim( %qu ) , pose.ns ),
            				", u( f.format.repose, rest( %qu, " ), say ),
            				\, u( f.format.repose, rest( %qu, lit( \ ) ), emit ),
            				switch( 1,
            					strmatch( %qf, po* ), u( f.format.repose, rest( %qu ), pose ),
            					strmatch( %qf, sa* ), u( f.format.repose, rest( %qu ), say ),
            					strmatch( %qf, @em* ), u( f.format.repose, rest( %qu ), emit ),
            					strmatch( %qf, @re* ), u( f.format.repose, rest( %qu ), emit ),
            					u( f.format.repose, edit( trim( %qu ), %\, ), emit ) ) ) ),	
            // This long nasty bit tries to figure out how you posed. Ie, " or @em or etc
            			set( %ql, 
            				u( f.format.repose.attribute, %# ):
            				[u( f.format.repose.data, %qe )] )
            // add that you posed 
            				) 
            			)
            	)
            
            1 Reply Last reply Reply Quote 0
            • Derp
              Derp Admin last edited by

              Does the pose alert code where it sends the tone work off of this same system? It would be awesome if you could post that too. I know a few people who could really use it. Not to name names or anything. <. <

              Racism isn't Tinkerbell. It doesn't need you to believe in it for it to exist.

              skew 1 Reply Last reply Reply Quote 0
              • skew
                skew @Derp last edited by

                @derp The function in Tiny (and I think in Rhost and Penn, too) is beep(). The function is usually locked to wiz, surely to avoid abuse (page-spamming beep() at someone would be awful), so using it as a player is mostly not possible. On Fate's Harvest, I put in a command called +beeptest that mostly exists so people can test if their beep() sound is actually playing (a lot of clients block it by default and you need to turn it on). But, with +beeptest it allows players to send it (and, with +beeptest you can input into a custom PoseOrder and make it so each time someone poses you get a beep).

                Anyways, the code for +beeptest is below. As you can see, it's meant to go on SGP global, which is usually #6. Does that help?

                &C.BEEP.TEST SGP - Main Globals=$+beeptest:@pemit %#=This is to see if your beep is working! [beep()] Beep beep!
                
                Derp 1 Reply Last reply Reply Quote 0
                • Derp
                  Derp Admin @skew last edited by

                  @skew

                  Mostly! I was actually more wondering about the +poseorder command with the beep option that I think FH and some other places had set up. Is that a seperate command, or does that work with what +repose uses? I could probably figure out how to code one, but I'm lazy, and it already exists. <.<

                  Racism isn't Tinkerbell. It doesn't need you to believe in it for it to exist.

                  skew 1 Reply Last reply Reply Quote 0
                  • skew
                    skew @Derp last edited by

                    @derp Oh! +poseorder is different code. It can be found here: https://github.com/skewskewskew/MUSHCode/blob/master/Pose Order Machine.txt

                    A lot of people actively dislike +poseorder. Some people feel it rushes people, some people dislike the idea of a "pose order" in general and prefer things to flow freely. Whatever the case, I know some people (Arx, SF MUX) have opted to NOT have +poseorder or something like it, very intentionally.

                    1 Reply Last reply Reply Quote 1
                    • Derp
                      Derp Admin last edited by

                      Thanks, you're the best!

                      Racism isn't Tinkerbell. It doesn't need you to believe in it for it to exist.

                      1 Reply Last reply Reply Quote 0
                      • 1 / 1
                      • First post
                        Last post