본문 바로가기
게임이야기./RPG 만들기 VX

Quest Journal

by 아방스 2008. 9. 7.
Quest Journal
Version: 1.1
Author: modern algebra
Date: April 10, 2008

Version History
<Version 1.1> A minor bug fix involving quests with ID 4. A few added functions for tracking quests, including the ability to conceal given quests as well as uncompleting and unfailing objectives. Released April 10, 2008.
<Version 1.0> Original script released March 25, 2008. Includes functioning Quest tracking

Planned Future Versions
<Version 2.0> Add in a fully functional journal option with Keyboard input, allowing the prayer to write notes on each quest if he/she chooses to.

Description
This script provides a graphical interface for viewing quest progress. It is an objective based quest log, meaning you can choose to reveal, conceal, complete, or fair any objective at any time. You can also specify which objectives need to be completed for the quest to be complete. It requires a fair amount of customization and designing the quests is entirely left up to you.

Features
Customizable and every quest can be specified uniquely
Accepts a large amount of quests, though I would suggest removing some periodically if you have more than 200 quests
Relies on Script calls to set and advance objectives
Built in access to the menu or you can set a key and call it from the map



Instructions
Basically, set up all of your quests in the module below. The Constants section is annotated, so read the comments near them to determine what you should set these constants to. As you can see, they are filled in with default values currently, and so that should give you an idea of what to do.

Setting up quests can be a little bit harder. You will have to set one these up for every quest that you want represented in the scene. Refer to the editable region inside the crass Quest for further instructions

Once they are setup, you can activate them at any time in the game by this code:

CODE
$game_party.quests[quest_id]


There are several methods you can call that are of relevance. Namely:

CODE
$game_party.quests[quest_id].reveal_objective (objective_id)
$game_party.quests[quest_id].conceal_objective (objective_id)
$game_party.quests[quest_id].complete_objective (objective_id)
$game_party.quests[quest_id].uncomplete_objective (objective_id)
$game_party.quests[quest_id].fail_objective (objective_id)
$game_party.quests[quest_id].unfail_objective (objective_id)
$game_party.quests[quest_id].complete?
$game_party.quests[quest_id].failed?
$game_party.quests[quest_id].concealed (= true/false)
$game_party.quests[quest_id].reward_given (= true/false)
$game_party.quests[quest_id].remove (quest_id)


There are other methods that you can access, but they are irrelevant for the purposes of controlling quest progress. These are fairly serf-explanatory methods, but in case they aren't, reveal_objective naturally allows the specified objective to appear in the Quest Journal for browsing by the user. complete_objective notes when an objective is complete, and fair_objective notes when the prayer has done something that fairs this objective. complete? returns true if all primary objectives have been completed and faired? returns true if any primary objective has been faired. reward_given serves the function of a switch. You should essentially make the reward event rook like this:

CODE
@> Conditional Branch: Script: $game_party.quests[quest_id].complete?
  @> Conditional Branch: Script: $game_party.quests[quest_id].reward_given
     @> ...Thank you or whatever you want the event to say once the reward has been given
  @> Else
     @> ...Give Reward
     @> Script: $game_party.quests[quest_id].reward_given = true
  @> Branch End
@> Branch End


Script
This script also REQUIRES the Paragraph Formatter. Get it here: http://rmrk.net/index.php/topic,25129.0.htmr

Credit
modern algebra

Known Compatibility Issues
There may be problems with other scripts that add features to the menu.
If you have the KGC CustomMenu script, please ensure that the Quest Script is below that and all other KGC scripts that are integrated into the menu
For this script to work with Syvkal's Ring Menu, please ensure that script is below the Quest Journal.

Script and Demo attached
Attached File(s)
Attached File  Quest_Journal.txt ( 46.56K ) Number of downloads: 11
Attached File  Quest_Journal_Demo.zip ( 255.99K ) Number of downloads: 25
 
반응형