// returns a three digit string usable by other textblitz functions
string RandomColor()
{
string x = "!#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz~<7E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>";
string c1 = "";
string c2 = "";
string c3 = "";
while (c1 == "") c1 = GetSubString(x, Random(251), 1);
while (c2 == "") c2 = GetSubString(x, Random(251), 1);
while (c3 == "") c3 = GetSubString(x, Random(251), 1);
return c1 + c2 + c3;
}
string Colorfy(string s, string color = "random")
{
if (color == "darkred") color = "~ ";
if (color == "lightred") color = "<22> ";
if (color == "darkblue") color = " ~";
if (color == "lightblue") color = " <20>";
if (color == "darkgreen") color = " ~ ";
if (color == "lightgreen") color = " <20> ";
if (color == "white") color = "<22><><EFBFBD>";
if (color == "random") color = RandomColor();
return "<c" + color + ">" + s + "</c>";
}
void ObjectRoleCall()
{
ToAll("*** *** *** OBJECT ROLE CALL *** *** ***");
object oArea = GetArea(GetFirstPC());
object o = GetFirstObjectInArea(oArea);
while(GetIsObjectValid(o))
{
Debug("Here", GetName(o));
o = GetNextObjectInArea(oArea);
}
}
void ItemRoleCall()
{
ToAll("*** *** *** ITEM ROLE CALL *** *** ***");
object oPC = GetFirstPC();
object oItem = GetFirstItemInInventory(oPC);
while(GetIsObjectValid(oItem))
{
Debug(GetAllIPs(oItem), GetName(oItem));
oItem = GetNextItemInInventory(oPC);
}
int i = 0;
for(i=0;i<14;i++)
{
oItem = GetItemInSlot(i, oPC);
if (GetIsObjectValid(oItem)) Debug(GetAllIPs(oItem), GetName(oItem));