Shoutbox (Disabled)

Project: Amorous Clone

Discussion in 'General Discussion' started by Joshua, May 28, 2015.

  1. Joshua

    Joshua Member Dark Army Enthusiast

    Messages:
    36
    Likes Received:
    19
    For those of you who don't know, I've been working on a little project to clone Amorous. The reason I'm doing this is purely as a learning exercise. I don't have much to show at the moment, since I haven't made as much progress as I would have liked.

    What I've got so far is a tech demo for Amorous' dialogue system, which currently allows me to support an unlimited number of characters and lines of dialogue without needing any further modifications to the code. It has been implemented in two different ways; using XML and using a plain text file.

    But before I continue, let me show you what the tech demo itself looks like:

    [​IMG]

    As you can see, nothing fancy. Just some text. When you click on a button with a character's name on it, the program will find that character from the source file and display their first line of dialogue. When you click on the text area, the program will progress to the next line of dialogue.

    Now for the source code for the two different implementations. First, for the XML file, this is what the XML file itself looks like:

    Code:
    <?xml version='1.0' ?>
    <characters>
        <coby>
            <talk id='talk1'>Good morning, bro!</talk>
            <talk id='talk2'>How are you doing?</talk>
            <talk id='talk3'>I'll be in the shower if you need me.</talk>
            <talk id='talk4'>See ya soon!</talk>
            <multi>
                <choice>Join Coby in shower.</choice>
                <choice>Alright, see you in a bit.</choice>
                <choice>Ask if Coby wants to hang out later.</choice>
            </multi>
        </coby>   
        <seth>
            <talk id='talk1'>Hey, it's good to see you.</talk>
            <talk id='talk2'>I just finished another short story.</talk>
            <talk id='talk3'>Want to read it?</talk>   
            <talk id='talk4'>Hope you like it.</talk>       
        </seth>
    </characters>
    And here's the source code:

    [​IMG]

    Now for the text version. Here's the source file:

    Code:
    coby
    |
    Good morning, bro!;
    How are you doing?;
    I'll be in the shower if you need me.;
    |
    multi
    |
    Join coby in shower;
    Ask coby if he wants to hang out;
    |
    seth
    |
    Hey, it's good to see you.;
    I just finished another short story.;
    Want to read it?;
    Hope you like it.;
    And here's the source:

    [​IMG]

    They both do the exact same thing, but in different ways. And in case you're wondering why I did it two different ways, I started out using an XML file, but ran into a snag when trying to implement multiple choice options. Then I learned about the text file method, which seemed more simple at first, but proved itself to be even more difficult to implement than the XML file. Going forward, I'm going to focus on just one method of implementation, but would love any input from any experienced coders here on which method would be "better" to pursue.

    Here are some of the features I have planned for this clone, as of now:
    • Add support for multiple source files, for better organization
    • Add support for multiple choice options (which I'm having a hard time figuring out right now)
    • Add ability to change background/character image based on dialogue location
    • Add character customization system once dialogue system is finished
    That's all from me, I hope you found this post interesting, at least, and I'll hopefully be updating this thread soon.
     
  2. OKTrite

    OKTrite Member

    Messages:
    48
    Likes Received:
    31
    Damn.

    You did all of this on your own? For a guy who's just doing this as a learning exercise (and from a fellow programmer) this is actually quite impressive, and I can't wait to see how you flesh this out.
     
    Joshua likes this.
  3. Joshua

    Joshua Member Dark Army Enthusiast

    Messages:
    36
    Likes Received:
    19
    Thank you! Yes, I did do this by myself, by pulling together bits and pieces from various tutorials I found online that had anything to do with this project at all. And let me tell you, every step so far has been an ordeal. I probably spent anywhere from 5-10 hours on this thing so far (not sure exactly, as I stopped tracking my time), but the only reason it's taking me so long is because I have no clue what I'm doing! :D
     
  4. Zel Rai

    Zel Rai New Member

    Messages:
    22
    Likes Received:
    3
    For a learning project this is quite impressive. Also as for your trouble branching with XML, it is a scripting language not a core language, it's main function is to store data in a human and machine readable format .

    It's niche use is as supplemental code that can be easily edited with out being recompiled.
    ie: static/dynamic configuration packages to be loaded a certain times that you may be working on and don't want to have to to compile every time somethings changed or arrays/variables/strings that you may want to tweak while the program is running assuming you have code that periodically updates it's internal variables from said files.

    An example of the first is Sims 3, almost all the packages have XML files with static configurations and information in them that can be updated with out touching the binary code. This is how the plethora of non core mods work.

    Alternatively to just making a clone, once you flesh out the engine you should start working on your own game content, I'd hate to see all that work go to waste written off as copycating by the fandom.
     
    Joshua likes this.
  5. Joshua

    Joshua Member Dark Army Enthusiast

    Messages:
    36
    Likes Received:
    19
    Thanks for your input, Zel. I'm not really planning on fleshing this out into its own game, I'm just trying to replicate Amorous' core mechanics.
     
  6. Weird Kitty

    Weird Kitty Active Member

    Messages:
    119
    Likes Received:
    149
    I love coding. Being able to put things together like that is very nice because then you're gonna have a very nice base to get going once you decide to work on your ideas :3
     
  7. Nekumiho

    Nekumiho Member

    Messages:
    52
    Likes Received:
    23
    such intelligence... much skill.. i couldn't even reach that skill of coding :confused::amsurprised:
     

Share This Page