Code Off #2 : Bestiary (Unfinished & Not Entered)

Yin

Veteran
Veteran
Joined
Jul 18, 2012
Messages
133
Reaction score
50
First Language
English
Primarily Uses
N/A
This is a totally unfinished version of my bestiary meant for the code off. I got caught up with something else and was not able to finish or release it in time for the contest.

Mind you this is a raw, uncommented, unpolished, and UNFINISHED version. It is lacking a scan skill and enemies are entered through encounter. Information is released slowly with each kill.

You're free to modify it if you want.

https://www.dropbox.com/sh/8hw6fkdjxbgc90m/AABZ5Cdxs14Fw1xSOZMRATMCa?dl=0

Anyway, I'm leaving it here so I can pick it back up eventually. I'm still working on my game and preparing for something big. I at least hope it helps someone!
 

??????

Diabolical Codemaster
Veteran
Joined
May 11, 2012
Messages
6,513
Reaction score
3,204
First Language
Binary
Primarily Uses
RMMZ
Aww that sucks that you where not able to finish in time. I hope everything is well for you and I'm pleased that you had intended on participating :)
 

Venka

Veteran
Veteran
Joined
Jun 20, 2012
Messages
945
Reaction score
365
First Language
English
Primarily Uses
Me too. I did look at your demo and code ;) my god... we code a LOT a like =P Other then the way you handle your notetags.. I could have sworn it was something I wrote. I only saw a few short hand tips I could show you if you were looking for feedback on the coding.
 

Yin

Veteran
Veteran
Joined
Jul 18, 2012
Messages
133
Reaction score
50
First Language
English
Primarily Uses
N/A
I am looking for feedback on coding. I'd love to know any shorter ways to do stuff and a better way to wrap words because sometimes words still go off screen. I haven't looked at it in a while, but I just looked at it and can't recognize any of it after working CT:DR lol. It is definitely fun to work on though and I will take any feedback that I get and apply it when I get back to it.
 

Venka

Veteran
Veteran
Joined
Jun 20, 2012
Messages
945
Reaction score
365
First Language
English
Primarily Uses
ok here's a few little shorthand things I've picked up:

You have this:

song = Yin::BeastLog::play_Song RPG::BGM.new(song[0], song[1], song[2]).playyou could write it out this way:

RPG::BGM.new(*Yin::BeastLog::play_Song).playthe * will fill in all the info from the array wth "," between the info.

my favorite shorthand..the if statement..and I use more often then I probably should:

if i > 4 ; x_return = x + 120 ; else x_return = x ; endcould reduce to

x_return = i > 4 ? x + 120 : xso your saying if variable = (statement ? do when true : do when false)

The last thing I notices was you checked once if a value was set to true. When you do an if statement, it checks the value of the equation or if you put in just a variable, it'll check if the variable exists or if the value is set to true. So..

if you run this snippet

if test p "test is set to true" else p "test either doesn't exist or isn't set to true" endit should return the second text line.. but if you set test to true then run the snippet again, it should give the first text string.
edit: oh and the best word wrapper I've run across is this one:

http://www.rpgmakervxace.net/topic/6964-word-wrapping-message-boxes/
 
Last edited by a moderator:

Yin

Veteran
Veteran
Joined
Jul 18, 2012
Messages
133
Reaction score
50
First Language
English
Primarily Uses
N/A
Thaaaaaanks! That is really helpful. I always wondered this

my favorite shorthand..the if statement..and I use more often then I probably should:

if i > 4 ; x_return = x + 120 ; else x_return = x ; endcould reduce to

x_return = i > 4 ? x + 120 : xso your saying if variable = (statement ? do when true : do when false)
I always saw that, but never really knew how to use that. I do now though :p thanks!

I had a word wrapper made for my game by a friend, but Dekita said I had to write my own code :( so I didn't really seek out any word wrappers and I just followed DP3's tutorial to make my own.

Another thing I had no clue about the star thing! That will really come in handy! Thanks so much Venka for the support & help!
 

??????

Diabolical Codemaster
Veteran
Joined
May 11, 2012
Messages
6,513
Reaction score
3,204
First Language
Binary
Primarily Uses
RMMZ
Hey, so I finally managed to get time to look through the COC entries and I figured, I would give yours a look too. Even thought it cant be couted officially, I know that the intent was there, so I will try give you a good feedback.

Things I really liked:
The radial blur on the sprites was a genius idea. I noticed this even before I looked at the code and i thought it was done very well.

Informational display was very very neat and overall, didnt look squashed in any way (unlike my info) ;)

This line (within your script) : "I plan to do some compatibility with scripts that I use all the time such as Dekita's Stats/Elem Control." < Cant ask for better promotion than in someone elses scripts :D

Things I think could be improved:

The script customization section could have used a little more information. Certain things I couldnt understand from the documentation alone and had to go reading the code to see what it done. Not everyone has that particular skillset :p

The use of arrays in the customization section was nice, but I feel it would have benefited from most information being stored in a hash. Like the settings for the menu command etc.

I really disliked this "$data_troops << bestiary_troop". imo that could have been carried out in a much better way, like creating a game object to simply handle the custom troop, or even a game temp object. You could look into how i handled custom troops within my bestiary. imo that is much more friendly. )

you can quite a few "if this && this&& this&& such else". I used to do that, but have since realized putting all those 'ifs' in their own method is much nicer, when simply calling the method.

not sure why you done this "(100 - 24) / 2" rather than just putting 38 :p
your draw params method could have been significantly shortened or split into separate methods :)
 

Seems I have more dislikes than likes, but thats not the case. Overall your script was pretty easy to read and flows fairly nicely. A little more organization would be nice, but there is ALOT more good points than bad about the code, I have just mentioned what I picked up on to help you improve, so please dont take my criticism to heart :)
I think its a real shame that you missed the deadline. this would have been a very nice addition to the other entrants :)
 

Sixth

Veteran
Veteran
Joined
Jul 4, 2014
Messages
2,162
Reaction score
822
First Language
Hungarian
Primarily Uses
RMVXA
I can't help you with coding, but you certainly helped me in it, so thanks a lot for this Bestiary, even if it is not finished yet!

Thanks to you, I now know what I need to alias if I want to trigger something when an enemy dies. :)

I really like the kill count defining the info shown, that is a feature I seek for a long time by now.

The scene itself looks nice too.

I wonder what happens when an enemy got more elements, not just one. :D

Wanted to try it, but noticed that there was something wrong with the element icons displaying, so I left it spinning in my head for now. 

Ima subscribe here and wait patiently for you to finish this bestiary, especially because you wrote that you plan to make some compatibility patches too. :)

 

not sure why you done this "(100 - 24) / 2" rather than just putting 38  :p
I do this all the time. I modify/make a lot of scenes, and in order to know what I just changed, I keep the default value and just add the values to that one.

Sometimes I end up with things like '140+2+6+4' or 'Graphics.width/2/3', etc.

But most of the times when I finish all my edits, I just merge them to make a cleaner code.
 
Last edited by a moderator:

BoluBolu

Veteran
Veteran
Joined
Apr 24, 2014
Messages
452
Reaction score
117
Primarily Uses
That bestiary is nice.

The radial blur on the sprites was a genius idea
I agree with Dekita, it's inspiring.

And I just know that Euphemia Font is pretty good too :) .
Well, I don't think I can give you an advice or suggestion about the code, because I myself is still a noob and me too can't finish my script in time because I'm real busy back then, even though my script is way more simple than yours -__-a. But I think if you can add a help window it will be nice?(or just eating space?), though I believe it's not really needed, so that is, nice bestary Yin :)
 
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

so hopefully tomorrow i get to go home from the hospital i've been here for 5 days already and it's driving me mad. I miss my family like crazy but at least I get to use my own toiletries and my own clothes. My mom is coming to visit soon i can't wait to see her cause i miss her the most. :kaojoy:
Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD

Forum statistics

Threads
105,868
Messages
1,017,070
Members
137,577
Latest member
SadaSoda
Top