StendhalDesign: Difference between revisions
Content deleted Content added
imported>MiguelAngelBlanchLardin No edit summary |
imported>Hendrik Brummermann m Reverted edit of Eitdkesww, changed back to last version by Slady |
||
| (133 intermediate revisions by 5 users not shown) | |||
Line 1:
This small doc tries to create an agreement on what stendhal is about and what it needs to include. It considers the existing [[
Please use the Discussion tab (found in the menu at the top of the page) to query about things or make suggestions.
Line 26:
It is split in to 4 different areas to test the multizones feature of Arianne.<br>
Players need to change zone in order to accomplish their task.
Our world is made of several entities: players, wolves, rats, sheeps, NPC. By describing each entity with use cases we will simplify later the coding stage.
== Use cases description ==
We need to use several use cases to describe our game.
===Player's user case===
Player is an entity that play the game, it can move, chat, attack, heal.
Line 95 ⟶ 98:
If listen "Sell Sheep" from Player:
Estimate Sheep value related to Sheep weight
Seller says "Do you want to sell
If listen "yes" from Player:
set Player money=Player money + <estimated price>
set Player XP=Player XP + 100 * Sheep Weight / 100
Destroy Sheep
Line 132 ⟶ 136:
Wolf attacks Attacker
</pre>
===Rat's user case===
Rat and Cave rats are creatures that will attack player to make it harder to grow the sheep up.
<pre>
Rat moves
If Rat sees Player:
Rat attacks Player
If Rat is attacked:
Rat attacks Attacker
</pre>
Line 140 ⟶ 156:
* Sheep buyer
* Wolf
* Rat
* Cave rat
* Player
* Food
Line 154 ⟶ 172:
* <b>dy</b> is the y-speed of the sheep
* <b>hp</b> is the life indicator of the sheep, when it reach 0 the sheep dies.
* <b>atk</b> is the RP attack value. See [[StendhalDesign#RP|RP rules]]
* <b>def</b> is the RP defense value. See [[StendhalDesign#RP|RP rules]]
* <b>xp</b> is the RP experience value. See [[StendhalDesign#RP|RP rules]]
* <b>weight</b> is the weight indicator of the sheep, the more weight, the more expensive it is.
Line 162 ⟶ 183:
The sheeps behaviour is mainly to follow its owner and look for food.<br>
If the Sheep finds food, it will eat.<br>
Sheep will runaway if attacked
=== Creatures: Wolf, rat and Cave rat ===
Wolves, rats and cave rats have the following set of attributes:
* <b>x</b> is the x-position of the wolf
* <b>y</b> is the y-position of the wolf
Line 172 ⟶ 193:
* <b>hp</b> is the life indicator of the wolf, when it reach 0 the wolf dies.
* <b>atk</b> is the RP attack value. See [[StendhalDesign#RP|RP rules]]
* <b>def</b> is the RP defense value. See [[StendhalDesign#RP|RP rules]]
* <b>xp</b> is the RP experience value. See [[StendhalDesign#RP|RP rules]]
Wolf ( and rat and cave rat ) tasks should be:
* <b>follow</b> means that wolf follows an object using the shortest way to reach it.
* <b>attack</b> means that wolf will try to damage the attacked object until its hp reach 0<br>Another action will cancel attack task.
Line 179 ⟶ 202:
* <b>chat</b> means that wolf will start to shout 'auuuuuuu!'. Wolves will often understand this as a call.
Wolf ( and rat and cave rat ) behaviour consists of patrolling some assigned areas.<br>
If the Wolf finds a Sheep, it will attack Sheep.<br>
If the Wolf finds a Player, it will attack player.<br>
If the Wolf is attacked, the Wolf returns the attacks.<br>
If the Wolf is severly injured, the Wolf will runaway.<br>
=== Sheep seller
The buyer and seller have the following set of attributes:
* <b>x</b> is the x-position of the NPC
Line 190 ⟶ 214:
* <b>dx</b> is the x-speed of the NPC
* <b>dy</b> is the y-speed of the NPC
* <b>hp</b> is the life indicator of the NPC, when it reach 0 it is reset back to full.
* <b>atk</b> is the RP attack value. See [[StendhalDesign#RP|RP rules]]
* <b>def</b> is the RP defense value. See [[StendhalDesign#RP|RP rules]]
* <b>xp</b> is the RP experience value. See [[StendhalDesign#RP|RP rules]]
* <b>attending</b> is the object_id of the player that is actually attending.
seller, buyer and
* <b>patrol</b> means that NPC will move around a specified path.
Line 204 ⟶ 232:
* <b>dx</b> is the x-speed of the player
* <b>dy</b> is the y-speed of the player
* <b>hp</b> is the life indicator of the
* <b>atk</b> is the RP attack value. See [[StendhalDesign#RP|RP rules]]
* <b>
* <b>xp</b> is the RP experience value. See [[StendhalDesign#RP|RP rules]]
* <b>money</b> is the quantity of money the player has.
Line 214 ⟶ 243:
* right hand
* backpack
Player tasks should be:
Line 301 ⟶ 329:
There are some limitations for combat right now:
* No PvP ( Player versus Player )
* Can't attack yourself
* Can't attack NPC
Line 314 ⟶ 341:
The attack action has the implicit meaning of following the target.
====Equipment and Inventory====
This action is very important as it handles most of the complexity and the fun of a RPG: getting new stuff and use items to solve quests.
'''TODO'''
=RP=
Line 339 ⟶ 371:
===Entity Attribute values===
The hardest part of any RP is to give balance to the values different entities has.
We need to give RP(atk, def and hp) values to:
====Player====
Let's make our starting player to be:
* <b>ATK</b> - 2
* <b>DEF</b> - 2
* <b>HP</b> - 100
These values have been set randomly.
====Sheep====
A sheep can't attack, so it has to be weaker than player.
* <b>ATK</b> - 0
* <b>DEF</b> - 1
* <b>HP</b> - 30
These values have alse been set randomly according to player values.
Killing a sheep won't report you any experience.
====Rat====
A rat is the simplest enemy you can find in Stendhal, so it has to be simple enought for a Level 1 player to kill.
* <b>ATK</b> - 3
* <b>DEF</b> - 2
* <b>XP</b> - 5
* <b>HP</b> - 10
To set these values we have run a simulation until we have get the right look in the graphs.<br>
http://arianne.sourceforge.net/wiki_images/rat.gif
====Cave Rat====
A cave rat is a stronger version of a rat, so it has to be simple enought for a Level 2-3 player to kill.
* <b>ATK</b> - 6
* <b>DEF</b> - 2
* <b>XP</b> - 10
* <b>HP</b> - 20
To set these values we have run a simulation until we have get the right look in the graphs.<br>
http://arianne.sourceforge.net/wiki_images/caverat.gif
====Wolf====
A wolf is a common creature on plains and forest, it has to be simple enought for a Level 4-5 player to kill.
* <b>ATK</b> - 6
* <b>DEF</b> - 4
* <b>XP</b> - 18
* <b>HP</b> - 35
To set these values we have run a simulation until we have get the right look in the graphs.<br>
http://arianne.sourceforge.net/wiki_images/wolf.gif
== Experience and levels ==
Line 361 ⟶ 433:
<table border=1 align=center>
<tr bgcolor=black><td><font color=white>Level</font></td><td><font color=white>Experience needed</font></td><td>HP value</td></tr>
<tr><td>
<tr><td>
<tr><td>
<tr><td>
<tr><td>
<tr><td>
<tr><td>
<tr><td>7</td><td>3712</td><td>170</td></tr>
<tr><td>8</td><td>5504</td><td>180</td></tr>
<tr><td>9</td><td>7808</td><td>190</td></tr>
<tr><td>10</td><td>10624</td><td>200</td></tr>
</table>
As you can deduce the HP grows at a rate of 10 per level, and ATK and DEF values are increased one on each new level.
The formula to calculate XP is:
exp = (10*level+5*level^2+10*level^3+80)
== Combat ==
Combat is a fight between two or more players.
The combat is round based. Each round takes
The risk to strike a player can be written as:
<pre>
Attacker.attack
</pre>
If player is hit we need to compute the wound that has been done:
<pre>
result = Attacker.
if result > 0:
Defender.hp = Defender.hp - result
Line 396 ⟶ 472:
Death happens when hp reachs 0.
A critical hit happens when both die rolls are 6. And the damage is equal to Attacker.attack
===Shields===
Line 405 ⟶ 481:
<tr><td>Small shield</td><td>+2</td></tr>
<tr><td>Medium shield</td><td>+3</td></tr>
<tr><td>Large shield</td><td>+4</td></tr>
<tr><td>Tower shield</td><td>+5</td></tr>
<tr><td>Green Scale shield</td><td>+6</td></tr>
<tr><td>Black Scale shield</td><td>+7</td></tr>
</table>
* black/green scale shields are dropped from the black/green dragon.
===Armour===
Line 419 ⟶ 499:
<tr><td>Field plate armour</td><td>+6</td></tr>
<tr><td>Full plate armour</td><td>+7</td></tr>
<tr><td>Green Scaled armour</td><td>+8</td></tr>
<tr><td>Black Scaled armour</td><td>+9</td></tr>
</table>
* black/green scaled armour are dropped from the black/green dragon.
===Weapon===
Line 431 ⟶ 514:
<tr><td>Long sword</td><td>+6</td></tr>
<tr><td>Two hand sword</td><td>+7</td></tr>
<tr><td>Green Scaled sword</td><td>+8</td></tr>
<tr><td>Black Scaled sword</td><td>+9</td></tr>
</table>
* black/green scaled swords are dropped from the black/green dragon.
== Dead ==
The result of combat is usually dead.
When you kill a creature a corpse will appear. If you open it, you will be able to get whatever it has inside, usually food, gold, weapons, shields or armors.<br>
Each time you kill a monster you are rewarded XP.
When you are killed you reappear on city and you lose your sheep if you have one.<br>
Also to penalize dead, you are remove 10% of exp points and if it is the case you are removed HP, ATK and DEF increases because of level up.
| |||