Code-Off Challenge #1 [ finished ]

Discussion in 'Code-Off Challenge' started by ??????, Jun 1, 2014.

  1. ??????

    ?????? Diabolical Codemaster Veteran

    Messages:
    6,264
    Likes Received:
    2,312
    Location:
    Your OS
    First Language:
    Binary
    Primarily Uses:
    RMMV
    @BonBon - just copy the system folder from another project into the demo. I encountered that issue as well :p

    @Venka - thanks for the feedback :)

    I think you misunderstand what I meant.

    Its not that you can have more than 1 bitmap per sprite, well you can if you just put them into another variable, but its more that the excess sprites arent needed.

    For an example, you could have done...

    @bitmap_array = []@bitmap_array << Cache.wardrobe("Base Image", hue)@bitmap_array << Cache.wardrobe("Clothes", hue)@bitmap_array << Cache.wardrobe("Hair", hue)# ... and so onand then just blt'd each bitmap into the sprite your actually using.

    Hell, you could go a step further and hold the aforementioned bitmap array (or a hash) in a module somewhere and cache the data so that the bitmap are only refreshed when a character changes outfit and the other bitmaps remain in memory - which is fine as they are constantly getting used anyway.

    ^ that would ensure that the bitmaps are only being created when they need to be.

    ^^ See, I couldn't be bothered with all that, so I kept my entry fairy simple :)

    Also - the face / character images used for each outfit (in my script) are defined in the outfit hash. They can be called whatever you want, I named mine 1,2,3,4,5... for ease of use :)
     
    Last edited by a moderator: Jul 16, 2014
    #81
    Venka likes this.
  2. FenixFyreX

    FenixFyreX Fire Deity Veteran

    Messages:
    434
    Likes Received:
    307
    Location:
    A Volcano Somewhere
    First Language:
    English
    I have to say, this event was fun! I look forward to continuing; my code is definitely not masterful, and I am looking forward to getting criticism on what I can do better and shouldn't do at all.


    Here's my feedback for you guys:


    @Dekita's Entry:

    I really liked the look of your scene. It fits with the defaults really well! The scene was informative and flowed really well.
    As for the system overall, it does what it needs to do, but I can't help notice that there isn't much give. Only one actor has a composited graphic, and they are limited by complete sets of clothing instead of throwing their own outfits together; I feel like it is a more advanced version of the "Change Character Graphic" event command rather than a composite system.


    That being said, your code was definitely the cleanest, nicest I've seen in a while. I like the structure of your script, it keeps it open without much clutter.
    @Venka's Entry:

    I am having a lot of fun with your system. It is definitely robust, but still easy to understand. The options you allow are neat, and oh man are those scenes naise. I wasn't quite sure about how to actually equip the armors / etc until I just hit space after pressing left / right, but I figured it out; it was actually quite simple!
    The code flows well. It's a tad rough here and there, but I guess I can't say anything about rough code now can I? Haha, but I like your style. I actually love how you modularized the sprite layers (getting / setting them) instead of putting it in the default classes. It makes the system accessible by others but not in the way of others either. Good job on that :D


    As for the many sprites per character..while this may reduce lag by removing the need to blit images together, it incurs another separate bit of lag entirely. I think that if the RGSS3 system wasn't so constricting and hidden, your script would have the chance to be absolutely 100% better @the lag aspect. Although I didn't really get the large lag spikes Dekita was talking about, I did see a little lag from your demo, and mine.
    As for the feedback I've gotten; Sorry, my demo should have been a little more clear on how to actually use the scenes! I commented my code, but forgot to display it to the public >.<


    Here's a few tips, if that's okay:

    Armor Stands: To place an armor stand, go into the Armor shop and buy one by selecting the message option Dye (vague, I guess...it should've read "Shop"), buy an armor stand, then face towards a blank tile. Open the menu, go to items, and use the armor stand. It will exit the menu and place the armor stand on the map. Then just press Space while next to and facing the stand, and it'll open the armor stand GUI.
    Changing clothes: In the wardrobe scene (Scene_Clothier), simply select Change for changing your normal equipment, or Social for the actor's social equipment. The Dye command requires you to have gotten some dyes from the Armor shop..try buying a few and then trying that option. Once you've selected what equips to change, press Space.


    The equip you are selecting on the right will fade in to blue. Press up and down to change the slot, then press space to select the slot you wish to change; choose an armor from the list (empty by default; once again, talk to the Armor shop man and you will get some equips automatically).


    Recoloring: I don't know why it isn't working for you Venka, it's working on my end...I bug checked the recoloring pars quite a bit to make sure this wouldn't happen!... As for controls, when the change hue window comes up, you press up / down to select what part of the hue to change (red, green, blue, alpha), and then press left arrow / right arrow to change it slowly. To change it faster, press L / R (which maps to Q and W on your keyboard by default in game). Then press Space / Enter when you are finished choosing the color; don't press B or the hue change will be cancelled.


    Followers not having graphics: Crap...I completely forgot about Ace's default Caterpillar / Follower system again..When I release this script officially, this will defs be fixed. Oops. Literally like 3 lines of code </is_a_dummy>


    Dekita, the lag from my demo is incurred entirely by the recoloring aspect. Should I rip it out or add a config to not use it, the lag *should* disappear (75% sure, 25% wondering if it isn't actually due to RGSS blt method).


    I left the RGSS dll out to conserve space...guess that didn't really matter. Over cautious on my part.


    Sorry that I didn't make it more presentable...the demo was made the day of (yesterday), I was mainly focusing on features...
     
    Last edited by a moderator: Jul 16, 2014
    #82
    Venka likes this.
  3. ??????

    ?????? Diabolical Codemaster Veteran

    Messages:
    6,264
    Likes Received:
    2,312
    Location:
    Your OS
    First Language:
    Binary
    Primarily Uses:
    RMMV
    Hey man, thanks for the feedback :)

    I did try to keep the scene fairly default looking so it would fit into the default looking demo :p

    Also quite happy that you felt my code was the 'nicest you've seen in a while' :D

    I knew that other people would have went the route of the character generator parts which I didnt really want to do; however, after seeing how cool the characters that can be made (instantly) are, I really wish I went that route as well :/

    I kind of felt that if i used the generator parts it would be more of a character creator more than a wardrobe, which was just another reason for me to use fixed images.

    Fixed images are also better if you where using some kind of animated battlers type script (I think :p )

    The color classes... I actually noticed those and spent quite a bit of time investigating what you had done there. If i have got it right... you are basically changing the color of every single pixel one by one? Seems a tad extreme to me, but I am no expert :p

    Personally, I would just have something that holds the hue data for each visible clothing item and disallow the user from inputting R/G/B/A and have them select a hue value instead.

    I suppose you couldn't offer them white/grey/black then though...

    I will have a further think about that one :p
     
    #83
  4. FenixFyreX

    FenixFyreX Fire Deity Veteran

    Messages:
    434
    Likes Received:
    307
    Location:
    A Volcano Somewhere
    First Language:
    English
    I had actually thought of that exact hue option -after- having read Venka's dilemmas with my script...and you're right, that would probably be much better. I had intended to make a bitmap dll down the road to accompany it, and I wrote in compatibility with Copern's recoloring system should it be used, which makes it loads faster and more capable...


    Now that I think about your ideas on the static images, you are kind of right. A wardrobe in its default sense is a grouping of already determined clothes, so your script does do as intended. I guess the whole "I can wear whatever I want" idealism kinda took over for me.
     
    #84
  5. ??????

    ?????? Diabolical Codemaster Veteran

    Messages:
    6,264
    Likes Received:
    2,312
    Location:
    Your OS
    First Language:
    Binary
    Primarily Uses:
    RMMV
    lol things are always easier to notice afterwords :p

    I've always been a bit confused about how to go about writing a dll for RPGM. or writing a dll n general, but that's not really a discussion for this thread :p

    On the issue with the color thing. What is it you think makes the performance loss occur from the color? I mean, your storing all the character images in the cache to its not like the images are being recolored every frame or anything :p
     
    #85
  6. FenixFyreX

    FenixFyreX Fire Deity Veteran

    Messages:
    434
    Likes Received:
    307
    Location:
    A Volcano Somewhere
    First Language:
    English
    Hahahaha, I can't believe it; I was testing the lag out by disabling the cache in the config of the main script. Try setting TASCfg::UseCache = true, I think that may help a bit? FFFUUUUUUU


    Alas, I could send you a PM about the dll thing and a sample dll project if you want, but that's up to you. You would need to learn C or C++ to be able to do anything with it, really.
     
    #86
  7. ??????

    ?????? Diabolical Codemaster Veteran

    Messages:
    6,264
    Likes Received:
    2,312
    Location:
    Your OS
    First Language:
    Binary
    Primarily Uses:
    RMMV
    Lmao you newb !!

    I also assumed the Cache would autorun and had overlooked it being set to false so I guess we are a pair of newbs :D

    I was away searching through the script and couldnt find anything that led me to think that any performance would be lost. The only thing is the recoloring of the image, but once thats done - its done and then cache'd.

    Lol epic fail moment :D

    Yea feel free to send me a pm regarding the whole dll side of things. i have done a little C++ before but nothing worth boasting about. And I'm always willing to learn new things if it means I can control more of my game :D

    I'm curious about this whole color thing that you done. What if I had a white/black image that has a fade. Lets say for example, an image of text (lets pretend it says Code-Off and looks like the image below)

    [​IMG]

    Would I be able to use your colorize method to efficiently change the white within the image to another color?

    Keeping in mind that certain pixels will not be pure white and the new color should also take this into consideration.
     
    #87
  8. FenixFyreX

    FenixFyreX Fire Deity Veteran

    Messages:
    434
    Likes Received:
    307
    Location:
    A Volcano Somewhere
    First Language:
    English
    Absolutely; in fact, targeting specific color ranges / saturation levels and ignoring the rest of the pixels makes the method even faster! I'll send you a PM about all of it in a bit.
     
    #88
  9. ??????

    ?????? Diabolical Codemaster Veteran

    Messages:
    6,264
    Likes Received:
    2,312
    Location:
    Your OS
    First Language:
    Binary
    Primarily Uses:
    RMMV
    omg yes please do :)

    That will save me from having to make two fonts for each one I want to use (one in white and one in a light blue color - to be hue'd to the desired color)

    If I could simply change all the white to another color range that would be epic :D

    Edit:

    And when you have 107 characters for each font image, that can be quite time consuming...

    I knew having a code-off event would lead to me learning something :D
     
    Last edited by a moderator: Jul 16, 2014
    #89
  10. Vexed

    Vexed Malibu Darby Veteran

    Messages:
    790
    Likes Received:
    1,564
    Location:
    Cambridge, UK
    First Language:
    English
    Primarily Uses:
    N/A
    Awesome job guys :D Really cool scripts - all of them! I've had a play about but I'm just going through the process of opening them up and checking the instructions and things.

    I'm a total dunce at anything code that's not event based so this will be a true test - if I can understand and use them, most people should be able to~

    I'll update with in-depth feedback after I've had a proper poke about :]
     
    #90
    Galenmereth and ?????? like this.
  11. Venka

    Venka Veteran Veteran

    Messages:
    945
    Likes Received:
    365
    Location:
    United States
    First Language:
    English
    @FenixFyreX: yep those extra instructions helped a ton. And maybe I was just doing something wrong before.. chop it up to user error ;) The dying worked perfectly when I went back in and tried to use it. And thanks for the tips on sliding the bar faster. I think Yanfly conditioned a lot of people.. so I was trying to use shift + direction keys to slide the color bars faster. And yes.. the armor stand was awesome :) Glad I got to see it.

    @Dekita: thanks for that tip.. that makes a lot more sense and now I'm wondering why I didn't make that connection myself ;) I'll work on updating the script when I get a chance.
     
    #91
    ?????? likes this.
  12. Kes

    Kes Global Moderators Global Mod

    Messages:
    20,801
    Likes Received:
    10,584
    First Language:
    English
    Primarily Uses:
    RMVXA
    From the perspective of a player I think Venka's was the most straightforward to use.  The way to change colours was easy to see, whereas for FenixFyreX it took me ages to work out what to do, and I never did crack the 'Armor stand' thing - yeah, pathetic, I know, but there it is.  I thought Venka's change window was clean and uncluttered, and having the sprite small was actually easier (for me) than the enlarged, and therefore blurred, image in FenixFyreX's.  All the instructions that I, as a player, needed to know where there.  Nice having the animated sprite strutting its stuff.  Dekita's seemed too much like the default generator to rouse much interest in me, but again, very easy to use.

    From the point of view of using them in developing a game, I found Venka's instructions easier to understand than FenixFyreX's.  Dekita's was also straightforward looking.  I didn't actually try and implement any of them, so my impression is based solely on looking at the scripts.

    The only thing with Venka's demo is that I couldn't get the front hair/bangs to change colour.

    Thanks guys for doing these.  To be honest I have always avoided the thought of using something like this; it never appealed.  But having tried these out, I might consider using it in a future game.  

    EDIT

    No comment from me about the quality/nature of the scripting.  I couldn't script my way out of a paper bag, so haven't a clue about that aspect at all.
     
    Last edited by a moderator: Jul 16, 2014
    #92
  13. ??????

    ?????? Diabolical Codemaster Veteran

    Messages:
    6,264
    Likes Received:
    2,312
    Location:
    Your OS
    First Language:
    Binary
    Primarily Uses:
    RMMV
    Looking forward to your in-depth critique :D

    Yea, considering your approach, its surprising that you didnt notice that really :p

    I mean, its just a case of exchanging your sprites for bitmaps :D

    Also - I've been playing around with bitmaps quite alot recently (due to the IGMC) and I've learned a 'butt-load' of stuff relating to them.

    For example, your really dont even need to make any sprites at all. The default engine already does this for you in Sprite_Character.

    Which means, you could so something along the lines of this for handling the bitmap...

    (this is a very rough example)

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

    module Bitmap_Cache

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

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

      #

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

      def self.cache

        @cache ||= {}

      end

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

      #

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

      def self.add_to(path,bitmap_to_add,hue)

        @cache[path] = Cache.whatever(bitmap_to_add,hue)

      end

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

      #

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

      def self.clear

        @cache ||= {}

        @cache.each_value {|b| b.dispose}

        @cache = nil

      end

    end

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

    class Bitmap_Example

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

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

      #

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

      def initialize(char_name)

        width  = Base_Char_Width

        height = Base_Char_Height

        @bitmap = Bitmap.new(width,height)

        blt_all_layers

      end

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

      #

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

      def blt_all_layers

        Bitmap.cache.each do |key, value|

          next unless key && value

          case key

          when :layer_1

            @src_rect = Rect.new(0,0,value.width,value.height)

            @bitmap.blt(0, 0, value, @word_src_rect)

          when :layer_2

            # ...

          end

        end

      end

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

      #

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

    end

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

    class Sprite_Character < Sprite_Base

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

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

      #

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

      def set_character_bitmap

        self.bitmap = Bitmap_Example.new(@character_name)

        sign = @character_name[/^[\!\$]./]

        if sign && sign.include?('$')

          @cw = bitmap.width / 3

          @ch = bitmap.height / 4

        else

          @cw = bitmap.width / 12

          @ch = bitmap.height / 8

        end

        self.ox = @cw / 2

        self.oy = @ch

      end

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

      #

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

    end
    ...

    Just one more way it could be handled I guess :D

    Hey there, thanks for the feedback :)

    Sorry, but I have to ask... Why does mine feel like the default generator, which it doesn't use, and the scripts that do use the generator parts dont feel like the default generator?  That confused me a little lol
     
    #93
    Venka likes this.
  14. FenixFyreX

    FenixFyreX Fire Deity Veteran

    Messages:
    434
    Likes Received:
    307
    Location:
    A Volcano Somewhere
    First Language:
    English
    @ksjp17 - The zoom is configurable; you can change it to the default (1) or up even larger. I thought it was a good feature, to let people configure how they wanted it. I only made it larger in the demo to let you see that aspect. The armor stands work like any other item; you buy one from the shop, and use it in the item's scene like any other item. I thought that part was made clear by it being in the Shop, and in the items database...
     
    #94
  15. The Infamous Bon Bon

    The Infamous Bon Bon Executive Geek Member

    Messages:
    850
    Likes Received:
    409
    Location:
    Wyoming, US of A
    First Language:
    English
    I thought of good uses for all three scripts and I was surprised that there was such different interpretations of the challenge.  That of course made it harder to decide which was best, but that's not necessarily a bad thing.

    Venka's was really user friendly because it had really well done instructions and looked very nice with the large image that changed direction so you could see all sides.

    Dekita's had the unique quality of assigning a specific actor that could change, which could be useful for the right game.  I also liked that faces were included.

    FenixFyreX's was nice in that it included the dyes and changing equipment changed the appearance to.  I didn't really try the social armor function, but if I understood it correctly the ability to have your appearance different than what was equipped is a nice feature that could be really good in the right game.

    You all did very well and I'm looking forward to the next challenge.
     
    #95
    Venka and ?????? like this.
  16. Adellie

    Adellie NPC Veteran

    Messages:
    340
    Likes Received:
    480
    Location:
    Canada
    Hey guys,

    I played the demos, took a quick gander at the configs/scripts, and generally poked around for about 5~10 minutes each. I did not try adding categories, or check out further customization. I did not read instructions. <_<;;; *braces for incoming tomatoes* I also only skimmed the comments above so if i'm repeating something, apologies.

    So yeah, this is crappy front-end review (more useful for someone choosing a script), but i wanted to leave a post here anyway because you guys deserve bumps for the time you spent on these scripts, especially during the igmc.

    --

    [​IMG] [​IMG]

    Venka:

    Clean and simple UI that players can fully utilize in seconds. Quickly switches between actors. Any actor can wear any piece, and you can immediately see the character at all angles. The config looks very, very inviting. I love how all you need to do in order to add pieces is just dumping images into the folder.

    [​IMG] [​IMG]

    Fenix FyreX:

    You can name the pieces, which is a big plus if you have a lot of different composites for the player to sort through. Distinguishes between male and female parts. Unlimited colors for both hair and armor. You can easily change the appearance of npcs = whaaaaaa ;DDD! Add hair pieces without touching the script. Adding armor pieces seems to take a little more since they're associated with actual equipment.

    Good for players that want to go all-out in customizing their characters, but it takes a while to get used to the ui, and RGB sliders are slow. I don't really understand what purpose the armor stand serves.

    I ran into an issue where when you use a dye and then go back to changing equipment, the list of armor options doesn't show up, although you can still change armors.

    [​IMG]

    Dekita:

    Navigating the ui is simple so it requires no instructions. Config looks tidy as well. Changes portrait as well as the character sprite.

    What was unexpected is that the script doesn't use pieces, but rather prepared character graphics and portraits. At first, I thought, 'huh that's not what the contest voters really wanted', but quickly realized that I actually prefer this. In a story rpg, the actors aren't your avatars and realistically won't undergo tons of changes. Since you won't have tons of outfits, you can spend time perfecting the appearances of the ones you do have, without worrying that x piece doesn't go with y piece doesn't go with z colour.

    As is, the wardrobe is only for one actor. Also, I feel like the extra stats aren't necessary at all. I can see someone appreciating that feature, but for myself, it actually weakened the script's appeal.

    Not sure if this an issue, or just incomplete. I think the wardrobe is supposed to restrict the weapon types you're able to equip?... but i'm still able to use/equip an axe with a spear wardrobe.

    --

    Great work. They were all unique entries!  :thumbsup-left:
     
    Last edited by a moderator: Jul 17, 2014
    #96
    ?????? and Venka like this.
  17. ??????

    ?????? Diabolical Codemaster Veteran

    Messages:
    6,264
    Likes Received:
    2,312
    Location:
    Your OS
    First Language:
    Binary
    Primarily Uses:
    RMMV
    Thanks for the feedback :)

    The main reason I added the stats was to fill up the scene :p

    I really dislike it when a scene doesn't utilize every possible pixel of space :D

    Equip types shouldn't get restricted at all. The current outfit simple enables the equip types, rather than disabling all the other ones :)

    If you wanted that feature simply remove the ability for the actor to equip all weapon types and then they are required to wear the appropriate outfit for their desired equipment ;)
     
    #97
    Adellie likes this.
  18. Shaz

    Shaz Veteran Veteran

    Messages:
    37,715
    Likes Received:
    11,421
    Location:
    Australia
    First Language:
    English
    Primarily Uses:
    RMMV
    Just want to say that the quality of feedback is really good, and probably indicates that we don't need to go to the trouble of setting up surveys for future challenges. The kind of feedback we were considering putting into a survey is being given by just about everyone in their posts. Thanks for taking the time to elaborate on what you liked, what you didn't, and what you found a bit confusing, as well as all the other things you're all providing :)
     
    #98
    ?????? likes this.
  19. Venka

    Venka Veteran Veteran

    Messages:
    945
    Likes Received:
    365
    Location:
    United States
    First Language:
    English
    I have to say.. I was a bit scared to enter the contest cause I thought my script would get ripped to shreds and make me want to cower in the corner. I'm glad I did do it and that all the critics are constructive. All the scripts are done in different ways that it's kind of hard to judge them as it'd kind of apples on oranges to an extent. They all have unique twists that make them stand out.
     
    #99
    FenixFyreX likes this.
  20. ??????

    ?????? Diabolical Codemaster Veteran

    Messages:
    6,264
    Likes Received:
    2,312
    Location:
    Your OS
    First Language:
    Binary
    Primarily Uses:
    RMMV
    Well there is no real need to be harsh about anything. We all want to learn a bit more at the end of the day, and being overly-critical can be a demotivate a lot of folk - which aint want anyone wants  (i dont think):/

    Of course, if something was outright unnecessary, then it would be best to know about that, and who better to give accurate feedback than other script writers :D
     
    FenixFyreX likes this.

Share This Page