Re: GUI snippet
Yes, you could also extract the data from the in-band stream using a regular expression. For example you could use the hp from your prompt to draw the energy bar, but that means that (1) you'd need to have a specific prompt pattern which included your hp, and (2) the energy bar would only update when you received a new prompt.
However the snippet uses MSDP to transmit the data out-of-band. That means you don't need to capture anything from the in-band stream - you can literally sit there with a static text window and watch your energy bars slowly refill, or watch the landscape scrolling past as you walk across the map, etc.
|