ScriptUO
Scripting Resources & Utilities => Stealth Client => Topic started by: sharpie on September 18, 2018, 02:39:06 PM
-
Hi! I've been learning Stealth/Python and I've run into a snag. I can't seem to figure out how to actually make a variable with the current time. Most of the stuff in the API gives me name 'xyz' is not defined. I'm sure there's an easy way!
Ex:
I'm trying to use Now in the WaitJournalLine command.
findMsg = WaitJournalLine(Now(), endMsg + "|" + stopMsg, 25000)
-
import datetime
now = datetime.datetime.now()
findMsg = WaitJournalLine(now, endMsg + "|" + stopMsg, 25000)
from datetime import datetime as dt
findMsg = WaitJournalLine(dt.now(), endMsg + "|" + stopMsg, 25000)
-
Thank you!!