Jump to content
New account registrations are disabed. This website is now an archive. Read more here.

Recommended Posts

Scene_Biography
Authors: Bigace360
Version: 3.1
Type: Actor Biography
Key Term: Misc Add-on

Introduction
Features

Shows actors characteristic stats and battler image or imported image. Can also add a background to it now.

Screenshots

biography.png?w=647


Script

DownloadBar.png


Instructions

Insert this script above main, and call it Scene_Biography. Everything is in the module so there’s no need to go any further down unless you know what your doing. Also as default, the script uses the battlers set in the database unless you place a image in the picture folder and place _P at the end of the files name.


Compatibility

Requires Scene_Base

scripts that may conflict with this Engine are stated in the comments in the SECTIONS.


 
Credits and Thanks
  • Bigace360, for the script


[table=Author's Notes]


Enjoy! Edited by bigace

Share this post


Link to post
Share on other sites

Update v1.1

~ Just improved coding

 

I also fixed screenshot (appearently it disappeared). Another update will come later as I have to fix paragraphs with something bliz made.

Edited by bigace

Share this post


Link to post
Share on other sites

Interesting. Too bad that your script lacks flexibility (what if I wish to display additional info like star sign or whatever?). All the same, using constants does not seem like a very wise choice to me (what if I want to modify bio info in-game, for example to unveil things progressively?), even though Ruby allows modifying constants, you should consider using hashes instead. Besides, what's that ACE module? And what does it bring at all?

Share this post


Link to post
Share on other sites

Interesting. Too bad that your script lacks flexibility (what if I wish to display additional info like star sign or whatever?). All the same, using constants does not seem like a very wise choice to me (what if I want to modify bio info in-game, for example to unveil things progressively?), even though Ruby allows modifying constants, you should consider using hashes instead.

As I said in my previous post I'm working on the paragraph script (Bio and History), so there not complete. You make it sound like this is the final script and theres no room for updates. If you want something added I'll add it, but don't try to ack like I don't know what I'm doing, like I'm just sitting here scratching my ass. I'm doing other stuff and upgrading this whenever I update my personal CMS. Don't worry about it to hard.

 

Besides, what's that ACE module? And what does it bring at all?

I'm not going to explain what a module does to a scripter, that just kind of sad don't u agree.

Edited by bigace

Share this post


Link to post
Share on other sites

Ow, sorry for trying and help you improve your scripting at all. I came here to give a hand, not to fight over who writes the better scripts. Anyways...

 

You make it sound like this is the final script and theres no room for updates.

 

That's the whole point. I'm actually making it sound like your script, the way it's written, can hardly be updated at all, unless you rewrite it in depth, that is. I'm not saying this is the final script, i'm saying you could gain much time in the future by working with a more flexible structure. Then again, if you want to spend hours rewriting code while it could just be a matter of minutes to add a new feature, suit yourself.

 

I'm not going to explain what a module does to a scripter, that just kind of sad don't u agree.

 

Of course you're not going to explain to me what a module does, because 1 - I know what a module does, 2 - I use modules myself and 3 - that's not what I'm asking at all. Nevermind though, I'm not going to explain to a scripter what a question about scripts means, either.

Edited by Moonpearl

Share this post


Link to post
Share on other sites

I don't like the hostility I am seeing here.

Moonpearl and Bigace, please smarten up.

 

@moonpearl: Bigace didn't ask for suggestions on the source code itself. There is nothing wrong with making such suggestions, but you should actually give suggestions/ask questions. Cryptic/vague rhetoric makes you sound arrogant.

 

@bigace: Regardless of whatever you felt moonpearl's intentions were, there is no reason to make personal attacks.

 

I think this is all just a big misunderstanding, and I wanted to douse the fires before it got too large.

If either of you feel I am being unfair/wrong, please PM me or another staff member, and keep this topic for discussing the script.

 

Back to discussion:

 

@bigace: Nifty little script. Looks nice. Personally, I would change the way the name, gender, age, etc. are aligned, to make it look a little neater. Probably, the best would be to align the caption (ie. name:, gender:, age:) to the right, then put the data left-aligned next to it, to make all the data aligned at the colon `:`

 

@moonpearl: If the flexibility issue lies within using constants, shouldn't your suggestion be to not use constants (and use instance/class variables), rather than hashes? Hashes can be constants as well -- but arrays have better performance rates and, IMO, conceptually less-confusing to non-scripters.

Just my two cents--in the end, for something like this, I think it's kind of a non-issue (especially if it works). Although, that is an interesting suggestion for dynamic biographies, I have never seen that before.

Share this post


Link to post
Share on other sites
There is nothing wrong with making such suggestions, but you should actually give suggestions/ask questions.

 

Is it not what I did? Need i quote the suggestions I gave and questions I asked?

 

@moonpearl: If the flexibility issue lies within using constants, shouldn't your suggestion be to not use constants (and use instance/class variables), rather than hashes? Hashes can be constants as well -- but arrays have better performance rates and, IMO, conceptually less-confusing to non-scripters.

 

Guess I mixed two suggestions in one. The flexibility issue mainly lies in using fixed names, regardless of them being constants or not. If you ever wish to add new features, this means adding new names, then adding new portions of code to process those new names, then adding portions of code to call those new portions of code, and so on. If you use either arrays or hashes instead, you may expand them at will with no need to tweak the rest. Personally I would prefer using hashes because this way you can easily add new features to the bio with no need for a reference table to know which index refers to which feature. Arrays do have better performance rates but as far as a bio menu is concerned, this would just need a single call here and there, so you wouldn't gain much. As for the conceptually confusing aspect, I don't know, but I bet it would be clearer for me if I saw a table matching a feature name with its value directly, rather than a table of values plus a table of references.

Share this post


Link to post
Share on other sites

If either of you feel I am being unfair/wrong, please PM me or another staff member, and keep this topic for discussing the script.

 

@moonpearl: I see what you are saying, but is adding a new constant array or adding a new key => array and then processing it actually saving any work (note that the current model uses an array, each index points to the actor ID in the database)? You would still need to add the new feature (with unique name and all), and then adjust the processing. Setting up a flexible hash and loop may make it easier for non-scripters to add functionality...but for the scripter it's not THAT much of a time saver. But really, in this scenario; I think neither an array nor a hash is really a good model. A good object oriented structure would probably define a biography as its own specific data structure, one instance for each actor. That would be much more flexible.

 

Also, hashes are easy for you to set up, because you already know how and understand. Explaining the syntax of a ruby hash to someone who isn't even familiar with any programming language syntax can be mind-boggling. Especially if you did something like this:

# Set up actor biographies here:
# Make sure that the feature points => to a list
# that corresponds to the correct actor id in the database
@@biographies = {
 :gender    => [ 'Male',
                 'Female',
                 'Male' ],
 :specialty => [ 'Swords',
                 'Guns',
                 'Spears']
}
# Or
@@biographies = {}
@@biographies[:gender][0] = 'Male'
@@biographies[:gender][1] = 'Female'
# etc.

If you expanded this to fit say 10 actors in the database, I think it would be enough to hurt even a professional programmer's head. With an object-oriented language to the extent of ruby, IMO, one should be careful not to lump everything into a list or table data structure (of course unless, that is the best way to describe the structure)

Share this post


Link to post
Share on other sites
A good object oriented structure would probably define a biography as its own specific data structure, one instance for each actor. That would be much more flexible.

 

I totally agree with that and that's exactly what I have in mind. I'm considering hashes because it seems to me like the best solution unless you go for an actual class. Your example is indeed difficult to read, but actually I would transpose it and rather do something like that:

 

 

$bio = [
 # Actor 0
 {
:name => "Aluxes",
:gender => "male",
:age => 18,
 },

 # Actor 1
 {
:name => "Basil",
:gender => "male",
:age => 20,
 },
]

 

 

Then, calling for a particular actor's feature would be like

 

$bio[actor_id][feature]

 

Properly commented, it seems very clear to me. As for the syntax, if you're not a scripter, you just have to replicate lines and edit the text, like I used to do when i was new to Ruby.

 

Besides, I do not agree that you still have to call features explicitly by their name, because using arrays and hashes, you can enumerate them. Thus, drawing a list of all the features would merely be like:

 

$bio[actor_id].each { |feature, value|
 # Write feature name
 # Write value
}

 

And here you have a tiny portion of code able to process the hashes, whatever they may contain, which allows the script's user to add/remove features from them at will, with no need to tweak the code. You can also manipulate the display order by merely changing the declaration order of the features in the hashes. And you're not even forced to fill all features for each character.

 

So, maybe because I'm a lazy guy, I do think it's THAT simpler for the scripter to do this way.

Share this post


Link to post
Share on other sites

Ah yes, your example would be more readable than my example. However, for a non-scripter, I still think that structure still would be confusing. I know, there's not much you can do about that in the first place (there will always be a certain level of confusion), which is why I believe these kinds of things were not suited for arrays/hashes at all, and creating either a struct or class based around the model would be more efficient...as well as it could be added to the existing actor data structures:

$data_actors[1].gender = 'Male'
$data_actors[2].age = 13

 

With the enumeration, that's what I was referring to, by being easier for non-scripters to add features (then, features are simply added, rather than added, then manually drawn).

The issue with enumeration (in this case), is that you still need some way to handle A) Multi-line features (such as biography/history). B) Features in different columns.

(Otherwise, you are absolutely correct about the enumeration, although the current design *may* need to change in order to fit enumeration better...unless you want to write some algorithms to correctly determine/split up multiple lines, as well as add a way to customize which column the feature is placed in, and auto-sizing/positioning, etc.)

 

But really, in the end, it's difficult to design scripts for non-scripters to work with. There isn't really a "best" model, in those terms. Which is why *I personally believe* that a structured, object model is the best...after all, ruby is object oriented.

 

My personal preference, for customizable, list-based data structures would be:

# Pretend we have the user modify a text file that defines an actor's
# Biography:
def biography(id)
 case id
 when 1 then "aluxes_bio.txt"
 when 2 then "basil_bio.txt"
 end
end

I believe, that "when x then y" is easier to comprehend, than "= [ { key => value } ]" for non-scripters. But, that's what I believe...and that would depend on the user as well.

This also means, performance-wise, that no array/hash/string/objects are even instantiated/stored in memory, until used and they definitely, do not persist in memory for the entire running-time of the game.

 

EDIT: Oh yea, forgot to mention, being a lazy programmer, to an extent (especially in the context you are referring to it) is a good thing. The number one philosophy in the Ruby community (and with most languages as well) is DRY (Don't Repeat Yourself), which I am sure you have heard a lot. It's easier to do this with duck-typing...which is why Ruby is really focussed around these concepts.

Share this post


Link to post
Share on other sites

I get your point. If your concern is about non-scripters, though, I believe that no matter what structure you may choose, there will always be people who find it obscure. So, if a script is meant to be modified by potentially non-scripter users, I think the scripter should rely on comments rather than any kind of seemingly clear syntax (which is what I personally do). Thus, why not write an efficient script with proper commenting, rather than sacrifice a good structure to transparent syntax? After all, since non-scripters cannot script by definition, they should be able to use scripts without requiring to read them in the first place.

Share this post


Link to post
Share on other sites

Yea that's the problem ... you can't satisfy everyone :( . Which is my issue for creating public scripts - when I create for non-scripters I always want to remove as much programming specific things from the customization as possible, which performance-wise is usually not efficient.

 

Any way, I think we both are getting a bit off topic now (thanks to my innate ability to derail threads)

Share this post


Link to post
Share on other sites

Pointless Rant

 

Ow, sorry for trying and help you improve your scripting at all. I came here to give a hand, not to fight over who writes the better scripts. Anyways...

That's the whole point. I'm actually making it sound like your script, the way it's written, can hardly be updated at all, unless you rewrite it in depth, that is. I'm not saying this is the final script, i'm saying you could gain much time in the future by working with a more flexible structure. Then again, if you want to spend hours rewriting code while it could just be a matter of minutes to add a new feature, suit yourself.

Of course you're not going to explain to me what a module does, because 1 - I know what a module does, 2 - I use modules myself and 3 - that's not what I'm asking at all. Nevermind though, I'm not going to explain to a scripter what a question about scripts means, either.

Why your arguing with me when I told you that this script isn't really that complex to begin with is a mystery. I can except a suggestions, but as I said before I'm working on a whole bunch of stuff right now that updating to what you said won't happen soon. So as I said, what are you so pissed about? Hopefully this stupid argument as ceased as I never said I wouldn't take your things into consideration. Just told you'll fix the stuff on the next update. Just want to let you know that theres no hard feelings from my side that is. Sitll learning to script myself so, I'll think about it on the next update.

 

I don't like the hostility I am seeing here.

Moonpearl and Bigace, please smarten up.

 

@moonpearl: Bigace didn't ask for suggestions on the source code itself. There is nothing wrong with making such suggestions, but you should actually give suggestions/ask questions. Cryptic/vague rhetoric makes you sound arrogant.

 

Thank you, the thing is I don't like it when people try to tell me things like I'm doing nothing but scratching ass all day (like Atoa thinks I do back on RRR and HBgames). As I said before I'll get to it when I get to it. Not trying to create hosility.

 

@bigace: Regardless of whatever you felt moonpearl's intentions were, there is no reason to make personal attacks.

 

I think this is all just a big misunderstanding, and I wanted to douse the fires before it got too large.

If either of you feel I am being unfair/wrong, please PM me or another staff member, and keep this topic for discussing the script.

 

Other then the last thing I said in that post, I wasn't trying to make hostility just answering his question. And to be honest, I think my silence and ignoring that second post ended that conversation as I didn't have time for that ignorance. from a mods stand point it's fine what your doing compare to some mods I know on a Bleach forums. They'll just ban or give you a warning without figuring out the problem and then they were hacked. Reason for jumping back in this converstion was because I'm not home.

 

@bigace: Nifty little script. Looks nice. Personally, I would change the way the name, gender, age, etc. are aligned, to make it look a little neater. Probably, the best would be to align the caption (ie. name:, gender:, age:) to the right, then put the data left-aligned next to it, to make all the data aligned at the colon `:`

 

VERY SWEET SCRIPT!! I'll credit you...

I appricient it.happy.png , I'll take what happened here into my next update.

Edited by bigace

Share this post


Link to post
Share on other sites

Update: v2.0

- The code has been rewriten so it's easier to read and takes up less lines.

- Added "slice_text" method by Blizzard, which automatically break to next line when needed

- Can now easily change/remove/add what type of stats are shown

Edited by bigace

Share this post


Link to post
Share on other sites

@F0: Ya, I should probably credit you as well. since I based it off your Journal script with this new update. The old verison had more lines and I had meaning to use Blizzard's slice method for the paragraphs earlier and then I saw how both you guys did it and rewrote this script again.

Edited by bigace

Share this post


Link to post
Share on other sites

Its not a problem. I noticed you based much of the configuration from it, but you didn't copy-paste the whole script or anything, just used the base as a starting point for your own version of it.

Share this post


Link to post
Share on other sites

Update v2.3

~ You can align your paragraph's in the module [Right, Center, Left]

~ You can now add a custom layount to your Biography screen.

~ Improved coding

Share this post


Link to post
Share on other sites

Update: v2.4 (Apr. 26, 2012)

● Added an option in the module that adds the Biography into the Menu for you

Share this post


Link to post
Share on other sites

Update: v2.5 (June, 2 2012)

● Added Scene_Base to remove unnecessary lines

● Removed Outlines, Download Warrior Core Engine for Outlines

Share this post


Link to post
Share on other sites

This is excellent, Really easy to import and lucky my Battle System is okay with it. No run script errors *w* Thank you very much

Share this post


Link to post
Share on other sites

Update: v2.6 (June 29, 2012)

● Added moving Background

● Improved coding

● Fixed compatibility with my Bestiary and Scene_RowChanger

Edited by bigace

Share this post


Link to post
Share on other sites

Updated: January 22, 2013 (v3.1)
â— Overworked System and Improved Coding

â— Fixed command menu issues with ACE Menu System

â— fixed a selection issue in the main menu
â— I change the way you add the actors name, encase the game has renaming
â— Fixed command menu issues with ACE Menu System

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By Fcrlovem
      Hello friends🐿️, I'm immersed in the project of a videogame "The Gymkhana of the Treasure" I've been working for months now but I still have a long way to go, I've reached the point where I need help to create more sprites and their respective images with emotions (manga style) , and on the other hand I also needed the support of someone who understands the RGSS to help me with the creation of SCRIPTS that improve the project.
       
      It is a long project, with 4 seasons, and events depending on it, and above all it is about exploration. I have the idea of undertaking with it, therefore I will do marketing courses once we finish it to try to take it to the top, trading it internationally if the players give it a pleasant welcome, translating it into English and Spanish, and later investing profits for it. translate it into more languages and reach more people.
       
      I offer 20% of the profit for each collaborator (I need two people) I look for transparency and good teamwork. I am putting all my heart into this project.
       
      Although I offer 20%, remember that in entrepreneurship, it does not always work out and that failure exists, therefore I do not promise that it will give benefits, but I will give 100% trying to overcome the obstacles that arise.
       
      If you are interested, I would be delighted to see your works to see if they adapt to the style of the video game, especially graphically.
       
      Thank you very much 💖
       
      Postscript: my native language is Spanish, and my English is from Google (warning 😪). 
    • By Bob423
      Title screen by Kevin.ds
      (you've been replaced shiny :P)
       
      Story

      2000 Years ago a huge city covered nearly all of the world. It was a thriving city where everyone was happy. Scientists discovered something that could make life so much easier. Not that it wasn't easy already. The energy gave the people the ability to summon water, or fire out of thin air, control earth, and wind, as well as heal the injured instantly. This power was in limited supply, however. People began to get greedy, and keep this energy to themselves. It was stored in glass containers, and released for a brief moment when used. The greed was slowly weakening the energy, and the people eventually ran out. They blamed each other for this.
      Then one day, the sky turned black. The city began to sink into the ground, taking most of the people with it. Some people made it out alive. The people began to restart their society. For hundreds of years, everything was fine. There wasn't even any trace of the city.
      One day an unlimited supply of that energy was found. The energy, which the people began to call magic, had been passed down; from generation to generation, through the peoples' souls, but lay dormant until then. Children now had the ability to use magic whenever they wanted. As the children aged, they learned to control their magic, and built schools to teach their children. Schools where the student were able to learn about the kind of magic they wanted to study.
       
      The 3 types of magic are: Attack Magic, Healing Magic, and
      Status Magic.
       
      One particular 16 year old boy named *Bob starts his first day at a school in his hometown of Silverwood Village. His best friend, *Joe happens to be in his first class. Over the course of their first year at the school, they meet a girl named *Cathy, who becomes their friend eventually. Finally, at the end of the year, they take the Final Exam together, and pass. Not long after being informed of their achievement, the wooden training dummies, brought to life by magic, get out of control, and attempt to burn the school down. They all make it out alright, and the teachers use water spells to douse the flames. When they reach the village, they find that their entire home town is on fire! They find a way to escape the flames by jumping over a broken part of a fence. While escaping the flames, they get separated, and Bob falls unconscious. Bob wakes up in a house south of Silverwood Village, and meets an old man, who only says to call him Brian, and that he found Bob unconscious, but not the others. He directs Bob toward the village, and hands him a sword and shield as he sets off to find his friends.
       
      after finding his friends, Bob, with the help of his friends, must save the world from an ancient, corrupted power formerly sleeping under the earth's crust.
       
      *Player can name this character


       
      contents
      places
      features
      characters
      screenshots
      videos
      credits
      download
       
      [/anchor]
       
      Places
       
       

       
      Features
       
       
       

       
      Characters
       
       
       


       
      Screenshots
       
      here's an album of them http://imgur.com/a/6TGnQ








       

      First 19 minutes of the demo
      [media]http://www.youtube.com/watch?v=TSO1x_sagtQ[/media]

       

      Credits
       
       
       
       

       
      Here's a banner made by Kevin.ds

       
      [anchor=download]
       
      UPDATE: Added difficulty levels and made it so the player is forced to chose one of each class.
      this prevents the player from getting stuck on certain parts and forced to restart the game.
      Expert mode is how the game was before i added the difficulty levels.
      Hopefully the game is easier now :D
       
      DOWNLOAD 
      (About 120mb)

      If the above link doesn't work, I'm probably fixing something.
       
       
      Known Bugs
      (That I can't fix, or not without making parts of the game too easy.)
       
       
       
      Tips for stuck people:
       
       
       
      If something seems weird and isn't explained in game,
      (e.g. Caeli Temple being really high in the air when you're inside, but on a mountain when outside, or the Mana Temple seeming less old, and some rooms being different from the rest of the temple)
      it can usually be explained by saying "It's magic"
       
      sorry if the game is broken. Alternatively, you can watch this:
      http://www.youtube.com/playlist?list=PLmZjr8BajltKjHOZWMbmTdl7mpNDzMDyI&feature=mh_lolz
       
      The Hidden City of Arcatis is more of a prequel then an actual beginning...if that makes sense. I've written out what happens in the game as another alternative to playing it. http://pastebin.com/07Ns42cG
    • By BiddyAuthor
      I've been trying for months for RMXP to work on my laptop. I have Windows 7 64-bit and I always come across mixed reactions whenever I search it online. I have heard that RMXP DOES in fact work with 64- bit, so I was wondering if there was something I need to do for it to work. The problem is whenever I try to activate, it does not go through the system and is left saying "connecting to server" for hours on end. (I left it for two days straight one time). So...help?
    • By Heretic86
      If you have spent any decent amount of time in the Editor, you have probably encountered this bug. Game just STOPS, reason is not apparently obvious. It doesnt CRASH, but just STOPS.
       
      What I found was that if you "Force" an Event to have a Repeating Move Route, then later call in ANY EVENT to "Wait for Move's Completion", the game goes into an Infinite Loop of Waiting, due
      to the Repeated "Forced" Event. So the game basically waits Forever.
       
      A "Forced Move Route" is when you change an Events Move Route by using the "Set Move Route" button. The Custom Move Routes were not affected. An easy work around would be to use different Pages, each Page having a different Move Route. This prevents that bug from occuring PERIOD. Its only a One Line Fix, but probably a NIGHTMARE for anyone new to RMXP to understand.
       
       
       
       
      DO NOT USE IN VX OR VX ACE - RMXP (RPG Maker XP) Only!
       
      It didnt look like there was an easy way to Alias the Def, so I just did a total Redefinition of the original with the fix.
       
      Comments?
×
×
  • Create New...