Battledale_PRC8/_module/nss/jw_sundial_use.nss
Jaysyn904 7b9e44ebbb Initial upload
Initial upload.  PRC8 has been added.  Module compiles, PRC's default AI & treasure scripts have been integrated.  Started work on top hak for SLA / Ability / Scripting modifications.
2024-03-11 23:44:08 -04:00

39 lines
630 B
Plaintext

void main()
{
object oPC=GetLastUsedBy();
if (GetAbilityScore(oPC,ABILITY_INTELLIGENCE)<10)
{
FloatingTextStringOnCreature("*confused*",oPC);
SendMessageToPC(oPC,"You are not clever enough to use that");
}
else
if (!GetIsDay())
{
SpeakString("It is too dark for the sundial to be much use.");
}
else
if (GetTimeHour()<=12)
{
SpeakString("The time is "+IntToString(GetTimeMinute())+" past "+IntToString(GetTimeHour())+" in the morning.");
}
else
{
SpeakString("The time is "+IntToString(GetTimeMinute())+" past "+IntToString(GetTimeHour()-12)+" in the afternoon.");
}
}