Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Quest Book - version 1.2

Zeriab

Sponsor

Quest Book
Version: 1.2

Introduction

This is a fairly heavy quest book which provides an overview over a number of quests represented by pictures. Each of the quests can be selected and a window with quest specific details will be shown. (The pictures are 80x80)

Features

Quests can have any number of parts. (Only the text for the current part is shown)
The quest book can be applied to a game in progress since whether quests are solved or not depends on variables, switches or a combination of them.
Solved quests kept and can be shown.
The opacity of background of the quest book can be changed and a picture can be shown behind it accordingly to a variable.

Screenshots



Demo

QuestBook version 1.2 (rar)

Script

I really suggest the demo rather than the script since it also contains example pictures.
I have included them for people who just want to take a look at the script.
Quest Book Script

Here is the example usage of the script used in the demo: (I would suggest placing it in a different section)

Installation

Insert the script just above main. (Like so many other scripts)
Insert just below the script a new section. This section will be were you configure the script. Create quests and such.

Instructions

I will try an experiment here. Instead of written a big wall of text explaining everything I want to know where my explanation should be in-depth and where it should be more shallow. I.e. where should I focus.
Please look at the example usage of the script.
What is for you the most confusing parts?
Will you be able to modify the quests?
Will you be able to add another quest?
Will you be able to add/remove a quest part?
Is it clear how the Quest_Criteria works?
Do you understand the top part where you configure the background?
How do you add/remove another background picture?
How do you change the opacity of the quest book? The path?
Can you figure out how to modify, add and remove the actual picture files? (You should probably download the demo for this)

This is a case of help me become better at helping you. I am sorry for the inconvenience.

Compatibility

At the bottom of the script (Binding to Scene_Load section in the demo) you find this code
Ruby:
#==============================================================================

# ** Scene_Load

#------------------------------------------------------------------------------

#  Aliases and uses the on_decision method to reset $game_quests on the proper

#  time.

#==============================================================================

 

class Scene_Load < Scene_File

  # Check if the alias already exists (To avoid F12 errors)

  unless self.method_defined?(:zeriab_questbook_scene_load_on_decision)

    alias zeriab_questbook_scene_load_on_decision :on_decision

  end

  def on_decision(*args)

    # Call the original method

    zeriab_questbook_scene_load_on_decision(*args)

    # Check if the scene has changed

    unless $scene == self

      # Reset quest data

      $game_quests.reset

    end

  end

end

The idea with that snippet is to call a method when you load a save. It is used to preserve consistency in the quest book
Ruby:
$game_quests.reset

Note only do this if there is a problem with the snippet. (You can try putting a " p 'test' " in the reset method in Game_Quests if you want to test that it is called when you load a game)

Credits and Thanks

Credits goes to Zeriab
Special thanks goes to Indinera who requested the script for the game Laxius Force

I would like to thank everyone using their time to try and use my system.
I would like to thank everyone reading this topic.
Thanks.

Terms and Conditions
Copyright (C) 2007  Zeriab

This script is free to use under the condition of Zeriab being credited. (Commercial and non-commercial projects alike)
This script can be freely changed and distributed under the condition of the original author remains in the script.
Verbatim copies of this topic can be freely distributed

This script is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Author's Notes

This script were designed for a game so the visualization is very fixed.

I would be delighted if you report any bug, errors or issues you find.
In fact I would be delighted if you took the time and replied even if you have nothing to report.
Suggestions are more than welcome

And finally: ENJOY!

- Zeriab
 

Zeriab

Sponsor

Thanks for the nice comments ^_^

Only use this if it fits into the game. There are plenty of quest logs and journal scripts out there.
My point is don't mindlessly put it into your game. Also note that this script do require a fair amount of work.

*hugs*
- Zeriab
 
Neat little script there Z. A very simple to use script for anyone, not just scripters.

I notice you do a lot of error catching, so errors cannot be made by developers, which is a pretty good idea.

Good work buddy!
 
I've found a little bug here. When I ran the game for the first time, it worked great. But when I returned to Title Screen and ran a new game, all the quest data is set to the lastest parts. Any idea to fix this?
(English is not my first languge, so... sorry if you don't understand what I'm saying)
 

Zeriab

Sponsor

@Seph:
Thanks a lot :D
Sorry for not noticing your reply before ._.

@jincross:
Try pasting this little snippet at the bottom of the script:
[rgss]#==============================================================================
# ** Game_System
#------------------------------------------------------------------------------
#  Aliases and uses the on_decision method to reset $game_quests on the proper
#  time.
#==============================================================================
 
class Game_System
  # Check if the alias already exists (To avoid F12 errors)
  unless self.method_defined?:)zeriab_questbook_game_system_initialize)
    alias zeriab_questbook_game_system_initialize :initialize
  end
  def initialize(*args)
    # Call the original method
    zeriab_questbook_game_system_initialize(*args)
    # Reset quest data
    $game_quests.reset
  end
end
[/rgss]

@woratana:
Thanks :3
It is a bit over commented, but does the job anyway ^^

*hugs*
- Zeriab
 
Well, I don't know if I put it at the right place or not, but I got this:
errortut.jpg
and this:
error1j.jpg
 

Zeriab

Sponsor

Ah yeah. Use instead:
[rgss]#==============================================================================
# ** Scene_Title
#------------------------------------------------------------------------------
#  Aliases and uses the command_new_game method to reset $game_quests on the proper
#  time.
#==============================================================================
 
class Scene_Title
  # Check if the alias already exists (To avoid F12 errors)
  unless self.method_defined?:)zeriab_questbook_scene_title_command_new_game)
    alias zeriab_questbook_scene_title_command_new_game :command_new_game
  end
  def command_new_game(*args)
    # Call the original method
    zeriab_questbook_scene_title_command_new_game(*args)
    # Reset quest data
    $game_quests.reset
  end
end
[/rgss]

*hugs*
 
Unless thats already implemented into his script, this should work...

Code:
#===============================================================================

# ** Game_Player

#===============================================================================

 

class Game_Player < Game_Character

  #-----------------------------------------------------------------------------

  # * Alias Listings

  #-----------------------------------------------------------------------------

  alias_method :openquestbook_gmplayer_update, :update

  #-----------------------------------------------------------------------------

  # * Update

  #-----------------------------------------------------------------------------

  def update

    openquestbook_gmplayer_update

    unless moving? or $game_system.map_interpreter.running? or

    @move_route_forcing or $game_temp.message_window_showing

      if Input.trigger?(Input::A)

        $game_system.se_play($data_system.decision_se)

        $scene = Scene_Questbook.new(Scene_Map.new)

      end

    end

  end

end

You can change Input::A to whatever you want, but basically (unless you reassigned the keys with RM's F1 menu) you'd have to press SHIFT to open the Quest Book. With default assignment, I'd set it to Input::L, that means the "Q" button would open it and it'd be easy for players to remember ;)

Hey Z, the screenies of the Quest Book look awesome, and your coding work is beautiful as always! Everything from the format and data structure, windows and scenes is awesome! Not only that, but it is commented well enough that a non-scripter should have an easy time with this, but enough of the nerdy scripter-to-scripter admiration.

I normally don't pay the attention to other peoples' work as much as I should, but this looks like a gem in the fire! Great job, I'm gonna check out the demo right now! :thumb:

EDIT: The only thing I don't like, its cool that you can scroll up/down the Quest window but it bugs me that when you reach the bottom and keep pressing down it brings you back to the top... that and the demo was kinda generic, but whatever this still looks pretty cool :P
 
What if one of my quests were like this:

*Campaign Mission: Rogue Shell
> Kill 50 Galimura+ Automatons
> Take down 5 Automaton Generators by Hacking [mini-game]
> Get the Automaton Blueprints


*Example quest title
 

Scuff

Member

@Kain, Which script should I post this in (I.E. The script is multiple scripts. Which one should I paste it in? And where should I paste it at?)

EDIT: Nevermind, I figured it out. If anyone else wants to know, put the script at the bottom of Scene_Questbook.
 
Great script, best one i've found so far.

Is there a way of adding a button to the menu called Quests to access the quest menu?

Thanks in advance.
 

Zeriab

Sponsor

Sorry for not noticing the replies to this thread before :blush:

@Kain:
Thanks for the snippet and kind words. :3
I am proud of this script and I did an effort to make it complete with comments and stuff.
It is a bit over commented, and there are some stuff I would like to change when I look at it now. (I don't do it for compatibility reasons)
I warms my heart that you call it a gem :cute:

The scrolling up and down was totally on purpose since the project I wrote it for uses my Warped Movement for Window Selectable script.
You can always just press up and go back down, so I don't really see the loss, but it is of course a matter of taste.
I totally agree that the demo is a bit generic and maybe doesn't do the script glory, but I think it's sufficient.

Fun fact: I have seen some of my quest pictures working its way into a commercial game XD

@Dung Beetle:
Should it show it all at the same time? Or should it progress by first you have to kill, then take down the generators and finally getting the blueprints?
You can perfectly fine write > in the quest description.

@Scuff:
Kain's snippet can be placed anywhere below Game_Player and above Main

@jasonorme:
There definitely is.
Do you have the default menu system or do you have a custom one?

*hugs*
- Zeriab
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top