MPNotification
M. Klatte edited this page May 1, 2015
·
1 revision
<quad bgcolor="000" sizen="320 6" posn="-160 96 100" id="MPNotification_TitleBar" />
<frame posn="-159 84 0" id="MPNotification_Container" hidden="1">
<quad style="Bgs1InRace" substyle="NavButton" sizen="69.5 10" posn="-0.5 0 0" id="MPNotification_Background" />
<quad style="Bgs1InRace" substyle="NavButton" sizen="69.5 10" posn="-0.5 0 0" id="MPNotification_BackgroundEvents" scriptevents="1" hidden="1" />
<quad style="Icons64x64_1" substyle="Close" scriptevents="1" sizen="10 10" scale="0.5" posn="64 -0.4 1" id="MPNotification_Close" />
<quad sizen="9 9" posn="1 -0.9 1" id="MPNotification_Icon" />
<label textcolor="666" textsize="1" scale="0.9" posn="13 -1.8 1" sizen="56 3" id="MPNotification_Category" />
<label textcolor="FFF" textsize="2" posn="13 -4.5 1" sizen="51 3" id="MPNotification_Label" />
</frame>
Note, that the first quad is optional, as it only recreates a placeholder for the standard adress bar.
Simply call
MPNotification("Some awesome Message!", "The small message above that", "IconStyle", "IconSubstyle", False, 3000);
- Instead of giving an IconStyle and SubStyle you can alternatively just give an image url instead of those two parameters.
- The Boolean parameter tells whether or not the created Notification will be clickable, you will have to catch the event afterwards.
- The Integer parameter in the end is the timeout in milliseconds after which the Notification disappears. Set it to
0
to disable auto-hide.