include ai.ai_combat; include library.ai_lib; include library.badge; include library.buff; include library.chat; include library.corpse; include library.create; include library.factions; include library.groundquests; include library.holiday; include library.hue; include library.instance; include library.pet_lib; include library.pgc_quests; include library.prose; include library.skill_template; include library.static_item; include library.storyteller; include library.sui; include library.trial; include library.township; include library.utils; include library.vehicle; trigger OnAttach() { if ( hasObjVar(self, "idiot_testing") ) { sendSystemMessage(self, "mfarone_test script attached.", ""); } else { sendSystemMessage(self, "Attaching script failed.", ""); detachScript(self, "test.mfarone_test"); } return SCRIPT_CONTINUE; } void areaDebugMessaging(obj_id self, string message) { obj_id[] players = getAllPlayers(getLocation(getTopMostContainer(self)), 35.0f); if ( players != null && players.length > 0 ) { for( int i=0; i -1 ) { for( int i = 0; i < commands.length; i++ ) { sendSystemMessage(self, commands[i], ""); } } stringCheck = text.indexOf("idiot_pgc_grant_all_tasks"); if ( stringCheck > -1 ) { for ( int i = 0; i < pgc_quests.ALL_PGC_COLLECTION_TASK_NAMES.length; i++ ) { string collectionName = pgc_quests.ALL_PGC_COLLECTION_TASK_NAMES[i]; string[] collctionSlots = getAllCollectionSlotsInCollection(collectionName); if ( collctionSlots != null && collctionSlots.length > 0 ) { for ( int j = 0; j < collctionSlots.length; j++ ) { string slotName = collctionSlots[j]; if ( slotName != null && slotName.length() > 0 ) { if ( getCollectionSlotValue(self, slotName) <= 0 ) { modifyCollectionSlotValue(self, slotName, 1); } } } } } return SCRIPT_OVERRIDE; } stringCheck = text.indexOf("idiot_pgc_revoke_all_tasks"); if ( stringCheck > -1 ) { for ( int i = 0; i < pgc_quests.ALL_PGC_COLLECTION_TASK_NAMES.length; i++ ) { string collectionName = pgc_quests.ALL_PGC_COLLECTION_TASK_NAMES[i]; string[] collctionSlots = getAllCollectionSlotsInCollection(collectionName); if ( collctionSlots != null && collctionSlots.length > 0 ) { for ( int j = 0; j < collctionSlots.length; j++ ) { string slotName = collctionSlots[j]; if ( slotName != null && slotName.length() > 0 ) { while ( getCollectionSlotValue(self, slotName) > 0 ) { modifyCollectionSlotValue(self, slotName, -1); } } } } } return SCRIPT_OVERRIDE; } return SCRIPT_CONTINUE; }