Time Length On Quests

Place for questions and answers for all newcomers and new coders. This is a free for all forum, no question is too stupid and to noob.

Time Length On Quests

Postby Epiales » Wed Oct 08, 2014 8:07 pm

I've watched the quest system from the older videos and have one setup now. I was wondering if there was a way, when someone finishes a quest, that you can put a time limt on when they can begin another quest? I might could figure this out with just a regular php variable, but the quests are in a while loop to echo them out in the game and I have no idea how I would implement such a thing when it's calling the quests from the database.
Nothing fancy, but a work in progress!

User avatar
Posts: 1119
Joined: Wed Aug 14, 2013 8:38 pm
Has thanked: 62 times
Been thanked: 6 times

Re: Time Length On Quests

Postby MikuzA » Thu Oct 09, 2014 12:49 am

Hello, why not just store a 'last_quest_finished' timestamp and during the loop,
add an if to the quest echos by checking the timestamp if its enough old to allow the player to start another quest..
Why so serious?

Business Intelligence, Data Engineering, Data Mining
PHP, HTML, JavaScript, Bash/KornShell, Python, C#, PL/SQL
MySQL, DB2, Oracle, Snowflake
Pentaho, DataStage, Matillion, Unity3D, Blender
User avatar
Posts: 395
Joined: Thu Aug 08, 2013 3:57 am
Location: Helsinki, Finland
Has thanked: 0 time
Been thanked: 21 times

Return to Beginner Help and Support

Who is online

Users browsing this forum: No registered users and 2 guests