Add MSDP status bar and protocol negotiation to mud.tin
This commit is contained in:
parent
bcf8ae28d1
commit
7ba4ab90fb
1 changed files with 18 additions and 0 deletions
18
mud.tin
18
mud.tin
|
|
@ -2,6 +2,24 @@
|
||||||
#NOP usage: tt++ mud.tin
|
#NOP usage: tt++ mud.tin
|
||||||
#split 0 1
|
#split 0 1
|
||||||
|
|
||||||
|
#NOP initialize MSDP variables for status bar (before connection)
|
||||||
|
#variable {MSDP_HEALTH} {-}
|
||||||
|
#variable {MSDP_HEALTH_MAX} {-}
|
||||||
|
#variable {MSDP_STAMINA} {-}
|
||||||
|
#variable {MSDP_STAMINA_MAX} {-}
|
||||||
|
|
||||||
|
#NOP protocol negotiation: tintin++ does NOT auto-negotiate MSDP or
|
||||||
|
#NOP GMCP. CATCH intercepts before the default DONT response, and
|
||||||
|
#NOP #line raw bypasses IAC escaping so the DO bytes arrive intact.
|
||||||
|
#EVENT {CATCH IAC WILL GMCP} {#line raw #send {\xFF\xFD\xC9}}
|
||||||
|
#EVENT {CATCH IAC WILL MSDP} {#line raw #send {\xFF\xFD\x45}}
|
||||||
|
|
||||||
|
#NOP store incoming MSDP variables and refresh status bar
|
||||||
|
#EVENT {IAC SB MSDP} {
|
||||||
|
#variable {MSDP_%0} {%1};
|
||||||
|
#showme {[HP: $MSDP_HEALTH/$MSDP_HEALTH_MAX] [ST: $MSDP_STAMINA/$MSDP_STAMINA_MAX]} {-2}
|
||||||
|
}
|
||||||
|
|
||||||
#NOP reconnect after disconnect. defined before #session so it
|
#NOP reconnect after disconnect. defined before #session so it
|
||||||
#NOP persists in the startup session when the mud session dies.
|
#NOP persists in the startup session when the mud session dies.
|
||||||
#alias {reconnect} {#session mud localhost 6789}
|
#alias {reconnect} {#session mud localhost 6789}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue