Usenet.com

www.Usenet.com

Group Index

Rec Thread Archive from Usenet.com

<-- __Chronological__ --> <-- __Thread__ -->

Re: my speed system



"Fu, Ren-Li" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Here's what I did.. let me know if anyone finds this useful. I'd also be
> interested in hearing how other people have done speed systems for their
> roguelikes.
>
> Every mobile has three variables:
> a) last_tick
> b) turns_this_tick
> c) turns_per_tick (defaults to 1)
>
> Then, you can make the player "twice as fast" by setting his turns per
tick
> to 2, 3x as fast by setting it to 3, etc. In Nethack, "speed" would
convert
> to 1.333 moves per turn, extra speed 1.67 (as I remember from the nh 342
> code). So, those are approximately the numbers I will be using barring any
> other discoveries.
>
> If you set the turn variables to floats, you can make a monster or player
> 10% faster by multiplying his speed by 1.1. Don't worry about the
> mathematics of percentages over +/-, simply divide the percentages when
you
> remove the effect and it will work out properly.
>
> If you wish to have attack and movement speed separate, simply cost
attacks
> with movement - require that an attack will cost differently from movement
> that is. With an attacks_per_tick variable, attack speed could remain
> separate from moves_per_tick.
>
> Example, a player wearing two rings of speed rated at 10% would have 1.21
> movement points. If you then add boots of speed 20%, (x1.2) his turns per
> tick will be 1.452. If he then removes the two rings of speed, you would
> divide by 1.1 twice and arrive back at 20% (1.2) due to the boots of
speed.
> Remove the BoS and you would have normal time (1 turn per tick).

Is what I've settled on is using energy costs for different actions and also
using a Speed Factor that is divided into the speed costs. (Thus, a higher
speed factor is better).  This way, all actors (players, monsters, whatever)
advance in the "queue" at the same speed.  Another plan is to never allow a
player to obtain a speed factor over... say... 1.4 or even 1.2.  I may end
up calculating this using some kind of point system with quadratic growth
much like, say, levels.  1.3 may cost 1000 "points", while haste gives 500
points, a ring of speed gives 100, ect.  Skill will reduce the cost of
actions, and thus provide an alternative to gaining speed.

When an actor acts, it has 0 time before, and some negative time after.
When it reaches 0 again, it gets to act again.

I'm very tempted to make movement much cheaper with respect to most other
actions, perhaps to represent a smaller scale.  Furthermore, making weapons
use much different speeds to allow more diversity than merely different dice
damage.  Moving (orthagonally) would take 1 standard unit (1000 units of
time, since that seems like a good number), a sword attack would consume
2-2.5 SU of time, an axe 4-5 SUs of time, a bow 2.5 SUs of time, a dagger 1
SU of time... And so on, all reduced with high skill.  A side effect of
making movement cheaper will be to increase vision range so players won't be
sneaked up on simply by swinging an axe.





<-- __Chronological__ --> <-- __Thread__ -->


Usenet.com



Please check out one of the premium Usenet Newsgroup Service Providers below for access to Usenet.