[XP] Victory Points - Script Mode

Started by Sthrattoff, July 01, 2008, 12:46:26 pm

Previous topic - Next topic

Sthrattoff

July 01, 2008, 12:46:26 pm Last Edit: December 05, 2010, 06:18:46 am by Ryex
Victory Points - Script Mode
Authors: Sthrattoff
Version: 1.0
Type: Victory Counter
Key Term: Misc Add-on



Introduction

This script keeps track of battles you have won by placing them in $game_system.victory_pts


Features


  • Keeps track of the battles you have won



Screenshots

NA



Demo

NA



Script

<REQUIRED OR DEMO, ALSO POST WHERE TO PUT YOUR SCRIPT>
Spoiler: ShowHide
#==============================================================================
# Victory Points
#------------------------------------------------------------------------------
# ** Version 2.0
# ** Original by Sthrattoff
#==============================================================================

class Game_System
 
 attr_accessor :victory_pts
 
 alias before_vp_initialize initialize
 def initialize
   before_vp_initialize
   @victory_pts = 0
 end
 
end


class Scene_Battle
 
 alias before_vp_phase5 start_phase5
 def start_phase5
   before_vp_phase5
   $game_system.victory_pts += 1
 end
 
end




Instructions

the victories are stored in
$game_system.victory_pts
you can display the variable in game by assigning a game variable to the value right before displaying it like so
$game_variables[ID] = $game_system.victory_pts


then you can display variable ID is a text box.

alternately you can write a script and use it there, ie. display it in the menu.



Compatibility

No issues know



Credits and Thanks


  • Sthrattoff



Author's Notes

The script version of my Victory Points system: Take a look!

as you my notice this member has had their account deleted, getting help form them is impossible here.


"I would like to thank Ryex for properly applying the template" or at least that is what I would say ~ Ryex



Blizzard

Check out Daygames and our games:

King of Booze 2      King of Booze: Never Ever
Drinking Game for Android      Never have I ever for Android
Drinking Game for iOS      Never have I ever for iOS


Quote from: winkioI do not speak to bricks, either as individuals or in wall form.

Quote from: Barney StinsonWhen I get sad, I stop being sad and be awesome instead. True story.

Starrodkirby86

So is the only thing I really have to do is Plug-and-Play (Above Main obviously) and I'm all set to go? A global variable doing my dirty work of Victories obtained? I like that...

My question is though, how does the second part work, when I insert that in Call Script?

What's osu!? It's a rhythm game. Thought I should have a signature with a working rank. ;P It's now clickable!
Still Aqua's biggest fan (Or am I?).




magic2345

Victory Points huh? Why does that sound familiar?
Is it from GameStation Saga?
"The world is not beautiful, therefore it is." -Kino's Journey

"Hm...What would uncle say?....
Life is like the clouds, it has two sides and a silverlining inbetween...Like a sandwich!! When life is hard, you take a bite out of the silverlining...."
-Zuko
_________________________________
Game I'm currently working on:
Terra Eternity
Story : 1%
Characters : 3%
Mapping : 1%
Graphics : 3%
Scripts : 20%

Blizzard

You can use

$game_variables[ID] = $game_system.victory_pts


to put the value into a variable and mess around with it.
Check out Daygames and our games:

King of Booze 2      King of Booze: Never Ever
Drinking Game for Android      Never have I ever for Android
Drinking Game for iOS      Never have I ever for iOS


Quote from: winkioI do not speak to bricks, either as individuals or in wall form.

Quote from: Barney StinsonWhen I get sad, I stop being sad and be awesome instead. True story.