The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Quest repeat
Author Message
WRWR
Journeyman
*

Posts: 212
Likes Given: 30
Likes Received: 1 in 1 posts
Joined: Mar 2012
Reputation: 1



Post: #1
Quest repeat
What is the best way to avoid repeated accept/performance of a quest?
i mean a best way for sphere and memory Lol
just tags looks heavy if i have about 1000 quests on shard
(This post was last modified: 08-13-2012 03:41 AM by WRWR.)
08-13-2012 03:40 AM
Find all posts by this user Like Post Quote this message in a reply
Shaklaban
Master
**

Posts: 378
Likes Given: 0
Likes Received: 1 in 1 posts
Joined: Mar 2012
Reputation: 8

DOT

Post: #2
RE: Quest repeat
i think best option is mysql.
08-13-2012 04:04 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
WRWR
Journeyman
*

Posts: 212
Likes Given: 30
Likes Received: 1 in 1 posts
Joined: Mar 2012
Reputation: 1



Post: #3
RE: Quest repeat
Ahh, really!
Do you have any examples how to organize it?
08-13-2012 04:06 AM
Find all posts by this user Like Post Quote this message in a reply
Anarch Cassius
Master
**

Posts: 273
Likes Given: 19
Likes Received: 10 in 9 posts
Joined: Mar 2012
Reputation: 2



Post: #4
RE: Quest repeat
Tags aren't heavy, stop worrying. Yes, a lot of them on everything might not be a good idea but 99% of the time you can't really do any harm.

Loops are what you want to be watching out for, not storing bits of data.

Current Projects: Necromancy SCP overhaul. Custom Faction AI/System. Imbuing.
08-13-2012 05:11 AM
Find all posts by this user Like Post Quote this message in a reply
WRWR
Journeyman
*

Posts: 212
Likes Given: 30
Likes Received: 1 in 1 posts
Joined: Mar 2012
Reputation: 1



Post: #5
RE: Quest repeat
Storing 100 tags on each player become a reason of loooooong saves Smile or not?
08-13-2012 05:30 AM
Find all posts by this user Like Post Quote this message in a reply
Wap
Journeyman
*

Posts: 138
Likes Given: 6
Likes Received: 7 in 6 posts
Joined: Mar 2012
Reputation: 3

UORPG.net

Post: #6
RE: Quest repeat
Also, from a TAG you can make a flag variable.
Example (in [] text is placed, there you should write correct functions):
Code:
[DEFNAME QUESTDEFS]
quest_0 01
quest_1 02
quest_2 04
...

TAG0.QUESTS_<[QUESTNUM/32]> |=<def0.quest_<[questnum]>>

IF (<TAG0.QUESTS_<[QUESTNUM/32]>>&<def0.quest_<[questnum]>>)

So, you can store 32 flags in one tag.
(This post was last modified: 08-13-2012 05:33 AM by Wap.)
08-13-2012 05:31 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Extreme
Grandmaster Poster
***

Posts: 1,141
Likes Given: 217
Likes Received: 90 in 77 posts
Joined: May 2012
Reputation: 20

SphereCommunity

Post: #7
RE: Quest repeat
Or you can store the Number ID of all completed quests in only one tag.
And check if the Number ID is in the tag to avoid repeat it.

When complete:
Code:
TAG.COMPLETEDQUESTS .= ",<QUESTNUMBER>"
To check if the quest is already completed:
Code:
[FUNCTION F_QUESTS_CHECKCOMPLETE]
LOCAL.QUESTNUMBER <ARGS>
ARGS <TAG.COMPLETEDQUESTS>
FOR 0 <EVAL <ARGV>-1>
IF STRMATCH(<LOCAL.QUESTNUMBER>,<ARGV[<LOCAL._FOR>]>)
  RETURN 1
ENDIF
ENDFOR
RETURN 0
Usage F_QUESTS_CHECKCOMPLETE <QUESTNUMBER>

STEPS BEFORE CREATE A THREAD
- Check the revisions log;
- Use the search button and use the keywords of your problem;
- Check the WIKI;
- Create a thread.
08-13-2012 11:22 AM
Find all posts by this user Like Post Quote this message in a reply
WRWR
Journeyman
*

Posts: 212
Likes Given: 30
Likes Received: 1 in 1 posts
Joined: Mar 2012
Reputation: 1



Post: #8
RE: Quest repeat
Try to find a better way a storing information about active quests, for example 5 active quests is max
if player push button "quests" he get a list of active quests.
08-14-2012 05:40 AM
Find all posts by this user Like Post Quote this message in a reply
Anarch Cassius
Master
**

Posts: 273
Likes Given: 19
Likes Received: 10 in 9 posts
Joined: Mar 2012
Reputation: 2



Post: #9
RE: Quest repeat
TAG.COMPLETEDQUESTS .= ",<QUESTNUMBER>"

Nobody told me you could do that! I need to edit some scripts.

That's a really nice handling of this. You have my vote for efficiency.

Current Projects: Necromancy SCP overhaul. Custom Faction AI/System. Imbuing.
08-14-2012 07:13 AM
Find all posts by this user Like Post Quote this message in a reply
Extreme
Grandmaster Poster
***

Posts: 1,141
Likes Given: 217
Likes Received: 90 in 77 posts
Joined: May 2012
Reputation: 20

SphereCommunity

Post: #10
RE: Quest repeat
(08-14-2012 07:13 AM)Anarch Cassius Wrote:  TAG.COMPLETEDQUESTS .= ",<QUESTNUMBER>"

Nobody told me you could do that! I need to edit some scripts.

That's a really nice handling of this. You have my vote for efficiency.
Hehehe
I always think more about something to get the best way to do something.
It's like perfectionism.

STEPS BEFORE CREATE A THREAD
- Check the revisions log;
- Use the search button and use the keywords of your problem;
- Check the WIKI;
- Create a thread.
08-14-2012 08:32 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)