Crime and Punishment event: This event will allow you to implement law and order into your game, Which appon
comiting a crime or misdeed your character has the choice of resisting arrest, going to jail or paying a fine (if the player has no money he will become in debt to the town and certain NPC characters will not interact with said player untill his fine is repayed)
Event includes such features as: a wanted level, a prison system, a pardon letter item and other features
Right lets kick things off
first lets make some variables:
Make a variable call it Wanted level
Make a variable call it Theft
Make a variable call it Murder
Make a variable call it Vandalism
Make a variable call it Tresspasing
Make a variable call it Current bounty
Make a variable call it Serve Your Time
Make a variable call it Which Jail Cell?
Now for a state:
Call it debt
make it never release
Now an item:
Call it Pardon letter
Do not make it consumeable
Now make a map for the jail:
Make sure the cells cant be broken out of!
Place a guard outside one of the jail cells
in his event box write:
First event page, no condition, Action Button
@>Text: Graphic
: : Guard: Behave yourself!
@>
: Branch End
@>
Next event Page, Condition: Variable: Current Bounty 1 or above, Parallel Process
@>Text: Graphic
: : Guard: This town will no longer talk with
: : you untill your bounty is repaid! You will
: : hence forth be referd to as Criminal!
@>Change Actor Name: [Actor 1], 'Criminal'
@>Change State: [Actor 1], + [Debt]
@>Control Variables: [Wanted level] = 0
@>Control Switches: [Bounty Payment] = ON
@>
Next event Page, Condition: Switch: Bounty Payment is ON, Action Button
@.Text: Graphic
: : Guard: Have you come to pay off your
: : bounty?
@>Conditional Branch: [Pardon Letter] in Inventory
@>Text: Graphic
: : Guard: Whats that a pardon letter? let me
: : see that... Ok fine your bounty is repaid!
@>Change Items: [Pardon letter], -1
@>Change State: [Actor 1], - [Debt]
@>Change Actor Name: [Actor 1], 'Actor 1'
@>Control Variables: [Current Bounty] = 0
@>Control Switches: [Bounty Payment] = OFF
@>
: Else
@.>Show Choices: Yes, No
: When [Yes]
@>Text: Graphic
: : Guard: Thats \v[Current Bounty] Gold Then!
@>Control Variables: [Current Bounty] - = Gold
@>Change Gold: -Variable [Curreny Bounty]
@>Conditional Branch: Variable [Current Bounty] > = 1
@>Text: Graphic
: : Guard: You still owe \v[Current Bounty].
@>
: Else
@>Text: Graphic
: : Guard: Your Bounty is repaid!
@>Change State: [Actor 1], -[Debt]
@>Change Actor Name: [Actor 1], 'Actor 1'
@>Control Variables: [Current Bounty] = 0
@>Control Switches: [Bounty Payment] = OFF
@>
: Branch End
@>
: When [No]
@> Text: Graphic
: : Guard: Get lost then criminal!
@>
: Branch end
Now inside one of the cells on the bed make an event,
inside its event box write:
Event Page 1, Condition: None, Action Button
@>Text:-,-, Normal, Bottom
: : Serve your time?
@>Show Choices: Yes, No
: When [Yes]
@>Control Variables: [Serve your time] = Random No. (1...7)
@>Conditional Branch: Variable [Serve your time] == 1
@>Fadeout Screen
@>Transfer Player:[Jail] (Outside of the jail cell)
@>Fadein Screen
@>Change Level: [Actor 1], - 1
@>Text:-,-, Normal, Bottom
: : Actor 1 Lost one level!
@>Control Variables: [Serve your time] = 0
@>Control Variables: [Wanted Level] = 0
@>Control Variables: [Current Bounty] = 0
@>
: Else
@>Conditional Branch: Variable [Serve your time] == 2
@>Fadeout Screen
@>Transfer Player:[Jail] (Outside of the jail cell)
@>Fadein Screen
@>Change Parameters: [Actor 1], MaxHP -20
@>Text:-,-, Normal, Bottom
: : Actor 1's Max Hp decrease by 20
@>Control Variables: [Serve your time] = 0
@>Control Variables: [Wanted Level] = 0
@>Control Variables: [Current Bounty] = 0
@>
: Else
@>Conditional Branch: Variable [Serve your time] == 3
@>Fadeout Screen
@>Transfer Player:[Jail] (Outside of the jail cell)
@>Fadein Screen
@>Change Parameters: [Actor 1], MaxmP -20
@>Text:-,-, Normal, Bottom
: : Actor 1's Max Mp decrease by 20
@>Control Variables: [Serve your time] = 0
@>Control Variables: [Wanted Level] = 0
@>Control Variables: [Current Bounty] = 0
@>
: Else
@>Conditional Branch: Variable [Serve your time] == 4
@>Fadeout Screen
@>Transfer Player:[Jail] (Outside of the jail cell)
@>Fadein Screen
@>Change Parameters: [Actor 1], Attack - 2
@>Text:-,-, Normal, Bottom
: : Actor 1's Attack decreased by 2
@>Control Variables: [Serve your time] = 0
@>Control Variables: [Wanted Level] = 0
@>Control Variables: [Current Bounty] = 0
@>
: Else
@>Conditional Branch: Variable [Serve your time] == 5
@>Fadeout Screen
@>Transfer Player:[Jail] (Outside of the jail cell)
@>Fadein Screen
@>Change Parameters: [Actor 1], Defense - 2
@>Text:-,-, Normal, Bottom
: : Actor 1's Defense decreased by 2
@>Control Variables: [Serve your time] = 0
@>Control Variables: [Wanted Level] = 0
@>Control Variables: [Current Bounty] = 0
@>
: Else
@>Conditional Branch: Variable [Serve your time] == 6
@>Fadeout Screen
@>Transfer Player:[Jail] (Outside of the jail cell)
@>Fadein Screen
@>Change Parameters: [Actor 1], Spirit - 2
@>Text:-,-, Normal, Bottom
: : Actor 1's Spirit decreased by 2
@>Control Variables: [Serve your time] = 0
@>Control Variables: [Wanted Level] = 0
@>Control Variables: [Current Bounty] = 0
@>
: Else
@>Conditional Branch: Variable [Serve your time] == 7
@>Fadeout Screen
@>Transfer Player:[Jail] (Outside of the jail cell)
@>Fadein Screen
@>Change Parameters: [Actor 1], Agillity - 2
@>Text:-,-, Normal, Bottom
: : Actor 1's Agillity decreased by 2
@>Control Variables: [Serve your time] = 0
@>Control Variables: [Wanted Level] = 0
@>Control Variables: [Current Bounty] = 0
@>
: Else
@>
: Branch End
@>
: Branch End
@>
: Branch End
@>
: Branch End
@>
: Branch End
@>
: Branch End
@>
: Branch End
@>
: When [No]
@>
: Branch End
@>
Example of how debt can be used to deny the player
the rights of the law abiding:
This example is of an armor shop:
@>Conditional Branch: [Actor 1] is [Debt] Inflicted
@>Text: Graphic
: : Shopkeeper: Get lost, I dont deal with criminals!
: Else
@>Shop Processing:
@>
: Branch End
@>
Now to place some guards in your town. inside there event box write:
First event page, no condition, Action Button
@>Conditional Branch: [Actor 1] is [Debt] Inflicted
@.Text: Graphic
: : Guard: Get lost criminal!
: Else
@.Text: Graphic
: : Guard: Hello There!
@.
: Branch End
@>
Next event Page, Condition: Variable: Wanted level 1 or above, Player Touch, Movement: Approach, ajust speed to level you require.
@.Text: Graphic
: : Guard: Come with me lawbreaker!
@.>Show Choices: Resist Arrest, Pay Bounty, Ok then
: When [Resist Arrest]
@>Battle Processing: Guard
@>Control Variables: [Wanted level] + = 1
@>Control Self Switch: A =ON
: When [Pay Bounty]
@.Text: Graphic
: : Guard: Come with me then..
@>Fadeout Screen
@> Transfer Player:[Jail] Place the player next to the guard we made above (not in a cell)
@>Fadein Screen
@>
: When [Ok then..]
@>Fadeout Screen
@>Control Variables: [Current Bounty] = 0
@>Control Variables: [Which Jail Cell?] = Random No. (1.. however many cells you put inside your jail)
@>Conditional Branch: Variable [Which Jail Cell?]== 1
@>Transfer Player:[Jail] MAKE SURE TO PUT THE PLAYER INSIDE THE JAIL CELL WITH THE BED EVENT IN!
@>Fadein Screen
@>
: Else
@>Conditional Branch: Variable [Which Jail Cell?]== 2
@>Transfer Player:[Jail] MAKE SURE TO PUT THE PLAYER INSIDE THE JAIL CELL WITH THE BED EVENT IN!
@>Fadein Screen
@>
And so on for however many jail cells you want.
Next event Page, Condition: Self Switch A is ON, No character graphic as this is for when you beat the guard in battle!
How about making some elite guards appear when wanted level is higher than say 5?
Just make a new event with the condition of Variable [wanted level] is higher than 5
and wack in that elite guard or merc.
Say you want to show how wanted the player is?
@>Text: -,-, Normal, Bottom
: : Your wanted level is \v[wanted level]
@>
Now for some examples of how to commit crimes:
This one is of a murder of an NPC
@>Text: Graphic
: : Bloke: Watch it loser!
@>Show Choices: Shut it!, Die!
: When [Shut it!]
@>Text: Graphic
: : Bloke: Sorry...
@>
: When [Die!]
@> Fadeout Screen
@> Wait: 70 frame(s)
@> Show Animation: This event,[Slash/Physical]
@> Fadein Screen
@> Wait: 5 frame(s)
@> Show Animation: This event,[Die]
@> Wait: 30 frame(s)
@> Control Variables: [Wanted Level] + = 1
@> Control Variables: [Murder] + = 1
@> Control Variables: [Current Bounty] + = 100
@>Control Self Switch: A =ON
How about making murders of children and old people cost loads?
And scumbag characters could drop a key when killed that opens their house and inside is a chest with
a Pardon Letter in?
This the robbing of an NPC
@>Show Choices: Talk, Rob!
: When [Talk]
@>Text: Graphic
: : Bloke: Hi there!...
@>
: When [Rob!]
@> Show Animation: This event,[Theft]
@> Wait: 30 frame(s)
@>Change Items: [Potion], + 1
@>Text:-,-, Normal, Bottom
: : Stole a potion!
@> Control Variables: [Wanted Level] + = 1
@> Control Variables: [Theft] + = 1
@> Control Variables: [Current Bounty] + = 20
@>Control Self Switch: A =ON
How about adding in a random variable that determines detection rate of the theft?
Or even a variable based off the characters level?
As you can tell the Murder, Theft and Vandalism, Tresspasing variables are completely optional
the important ones are the wanted level, current bounty, Serve your time and which jail cell?.
I have the optional ones in for skills and such... quick example:
theres a nice little script: YERD_DmgFormula
which allows you to add variable to damage calulation... such as multiplying the damage by say.. murders, or thefts
all you have to do is insert the tag in the skill box: <mulvar x>, <divvar x>, <addvar x>, <subvar x>, x = ID of variable
you can also do this via a common event:
@>Control Variables: [Murdering Git] =Variable [Murder]
@>Control Variables: [Murdering Git] * = 100
@>Show Battle Animation: Entire Troop, [Animation]
@>Change Enemy HP: Entire Troop, -Variable [Murdering Git]
@>Text: -,-, Normal, Bottom
: : Enemies took \v[Murdering Git] Damage!
@>
Then just add that into the common event box on a skill.
The only downside of not having the above mentioned script is the skill attacks all enemies
I have purposley left all the variable numbers blank so insert what you wish for the number.
Feedback would be great! If you have any ideas on how to improve this event let me know, or if you have any
questions do not hesitate to ask..
DEMO v.2: Here,
http://www.mediafire.com/?83yusc9i87bfjxs4 ways of breaking the law are now present in the latest demo, if you guys think
of anymore let me know.. Now has Stealing (based of actors level)
Vandalism and treaspasing, murders and NPC owned chests