- 20
- Posts
- 1
- Years
- Seen today
I'm looking for a way to have a script/event that depend on the time.
I looked in crystaldust scripts and found this :
I hope that my question is clear and hope I'll get some help.
Regards
I looked in crystaldust scripts and found this :
So I tried to implement the gettime function in my code, but it doesn't assemble in the end. I do have the following error :script Route35_EventScript_Dirk {
lock
faceplayer
gettime
if (var(VAR_0x8002) == TIME_NIGHT)
{
trainerbattle_single(TRAINER_DIRK, Route35_Text_DirkIntro, Route35_Text_DirkDefeated)
msgbox(Route35_Text_DirkPostBattle)
}
else
{
msgbox("Your POKéMON look pretty tough.\n"
"You could go anywhere safely.")
}
release
}
This makes me wondering if the gettime function is well used this way, or if there is another way to run a script/event based on the time.data/maps/Mossdeep_SeaGate2/scripts.inc: Assembler messages:
data/maps/Mossdeep_SeaGate2/scripts.inc:9: Error: non-constant expression in ".if" statement
I hope that my question is clear and hope I'll get some help.
Regards