07.04.2017, 16:13
(
Последний раз редактировалось danielpalade; 18.04.2017 в 21:42.
)
This code has been deleted.
|
Код:
if(hour >= 21 && hour <= 00) |
if(hour >= 21 && hour <= 24) // 00:00 = 24:00
if(hour >= 21)
|
A number can't be higher than 21 and lower than 0, it's not logically possible. I think what you're trying to achieve is this:
Код:
if(hour >= 21 && hour <= 24) // 00:00 = 24:00 Код:
if(hour >= 21) |
|
Your data structure (the array) is very confusing. Can you show me some more code so I can figure how the data is stored?
|
enum p_quests
{
questID,
questTitle[64],
questType,
questObject[10],
Timer: questTimer
}
new E_QUEST[MAX_QUESTS][p_quests];
stock OnQuestsLoad()
{
new x, hour;
gettime(hour);
x = 1;
E_QUEST[x][questID] = x;
format(E_QUEST[x][questTitle], 64, "The Chilliad Mystery");
E_QUEST[x][questType] = 1;
if(hour >= 21 && hour <= 00)
{
E_QUEST[x][questObject][OBJECT_GHOST] = CreateActor(55, -2255.3076,-1749.2554,487.6301,213.9964);
E_QUEST[x][questObject][OBJECT_SMOKE] = CreateDynamicObject(18735, -2255.370605, -1749.652343, 485.269836, 0.000000, 0.000000, 0.000000);
}
x = 2;
E_QUEST[x][questID] = x;
format(E_QUEST[x][questTitle], 64, "The Collector");
E_QUEST[x][questObject][OBJECT_VEHICLE] = INVALID_VEHICLE_ID;
E_QUEST[x][questType] = 2;
x = 3;
E_QUEST[x][questID] = x;
format(E_QUEST[x][questTitle], 64, "The Racer");
E_QUEST[x][questObject][OBJECT_NPC] = CreateActor(55, -2127.6614,-452.7275,35.5313,272.9914);
E_QUEST[x][questType] = 3;
return 1;
}