Monday, March 16, 2015

Introducing how events are written 2: let's go working!

Hi,

here's the second lessons on how the events are written.
Today let's see how to put up a simple working event. This way we can see some new event steps.


So, how a slave in a fantasy hentai world could make money?
What did you say? By being an astronaut? Well, thats... unexpected.

Anyway okay.
So we start with something basic:

<Event Name="work_as_astronaut">
        <SetTitle>To infinity... and beyond!</SetTitle>
        <SetText>!$trainee worked as an astronaut! WIIII!</SetText>
</Event>

Yeah, very basic...
Anyway here there's already something new.
Have you spotted it?
It's the !$trainee. Okay le'ts start by saying that when you see something that starts with !$ it's called an Alias and inside the game will be replaced with something more meaningfull. For example our !$trainee will be substituted with the name of your slave.


Now, during events your slave stats improve/degrade as a consequence of what she do.

    <Event Name="work_as_astronaut">
        <SetTitle>To infinity... and beyond!</SetTitle>
        <AddBody>Wear +++++ Being in space is tiring</AddBody>
        <AddBody>Fitness ----- There's no way to train in space</AddBody>
        <AddMind>Wear +++++ Being in space is tiring</AddMind>
        <AddMind>Happiness +++ Being in space is a wonderful experience</AddMind>
        <SetText>!$trainee worked as an astronaut! WIIII!</SetText>
    </Event>

There are 2 kind of stats: body stats and mind stats.
The body stats represent phisical trait of the girl while mind stats represent mental traits.
Anyway <AddBody> is used to modify body stats while <AddMind> is used to modify mind stats.
A stat that is common to both is Wear. The higher it is the more fatigued the girl is, phisically and mentally.

Both <AddMind> and <AddBody> have the same sintax:
<AddMind>Wear(1) ++++(2) Being inbla bla(3)</AddMind>

  1. The first part is the name of the stat being modified.
  2. The second part is the amount the stat will be modified. +++++ mean it will increase a lot, using less plus will increase it but less. ----- will decrease the stat a lot and using less minus will still decrease it but less.
  3. The third part is the reason the stat changed. This will be displayed to the player.
Now let's add another event step.


    <Event Name="work_as_astronaut">
        <SetTitle>To infinity... and beyond!</SetTitle>
        <AddBody>Wear +++++ Being in space is tiring</AddBody>
        <AddMind>Wear +++++ Being in space is tiring</AddMind>
        <AddMind>Happiness +++ Being in space is a wonderful experience</AddMind>
        <AddMoney>
            <Reason>Worked as astronaut</Reason>
            <Amount>2000</Amount>
        </AddMoney>
        <SetText>!$trainee worked as an astronaut! WIIII!</SetText>
    </Event>

Guess, what <AddMoney> do?
Exactly, it make the game crash.
No, I mean it add a given amount to the player money.
The <Amount> is how many money will be added (or removed if it's negative) from the player finance.
The <Reason> is the same as the reason for <AddMind> and it is used to display info to the player.



Now let's fire this bad boy, shall we?


As you can see:
  •  !$trainee is changed and is now Jeane
  • The money are added to player finance as can be seen in the screen.
  • You can't see the stats but I assure you they had been added to trainee stats (I would have shown you the stat panel too but currently it doesn't display the reason so let's wait a little)

Okay, hope I have been clear enough.



No comments:

Post a Comment