void main()
{
    if ((GetLocalInt(OBJECT_SELF, "nGoingToFarmDoorFlag") == 1) && (GetLocalInt(OBJECT_SELF, "nFarmDoorOpenedFlag") == 0))
    {
        // Didn't make it to the door because got interrupted by PC
        // Try again
        object oFarmDoor =  GetObjectByTag("dt_TownToFarm");
        ActionForceMoveToObject(oFarmDoor);
        ActionDoCommand(SetLocked(oFarmDoor, 0));
        ActionSpeakString("Go on in, and be nice!", TALKVOLUME_TALK);
        ActionForceMoveToObject(GetObjectByTag("JHR_WP_FARMER"));
        ActionDoCommand(SetLocalInt(GetModule(), "nFarmDoorOpenedFlag", 1));
    }
}
