Added 4 hours 52 minutes ago
Please help me figure out what the error is in the script:
function demon()
local p1 =GetObjectiveState ('qwert1',PLAYER_1);
local p =GetObjectiveState ('qwert2',PLAYER_1);
local opr = 9
local opr3 = 13
local p2 = GetObjectiveState ('qwert3', 1);
if p2 == OBJECTIVE_COMPLETED then opr= opr+1
if p2 == OBJECTIVE_COMPLETED then opr= opr3+1
if p1 ==OBJECTIVE_COMPLETED and GetDate(DAY_OF_WEEK ) == 6
then
AddObjectCreatures('gar_1', opr, 15);
AddObjectCreatures('gar_2', opr, 15);
AddObjectCreatures('gar_3', opr, 15);
AddObjectCreatures('gar_4', opr, 15);
elseif p ==OBJECTIVE_COMPLETED and GetDate(DAY_OF_WEEK ) == 5
then
AddObjectCreatures('gar_1', opr3, 3);
AddObjectCreatures('gar_2', opr3, 3);
AddObjectCreatures('gar_3', opr3, 3);
AddObjectCreatures('gar_4', opr3, 3);
end;
end;
Trigger(NEW_DAY_TRIGGER, 'demon');
It seems like I wrote everything correctly, but the quest is completed, the 5th day comes, the monks don't arrive, the 6th day comes, and the angels still don't appear.