[CF-Devel] skip 'run'and 'run_stop' command and 'fire' and 'fire_stop' (read this first)

Michael Toennies mtx93 at tzi.de
Tue Dec 5 15:52:31 CST 2000


Hi

Goal of this is to make on programmer side the cmd structure clearer, on
client side to give him
more potential and on user side to make it easier.

Also, the throw cmd will fit in this easier system. I will describe it
later.

Ok, this here means not to skip run mode, just the single command 'run' and
'run_stop', which is a
client to server command to put the server in run mode (Also a run
<direction> put him in run mode).
You must after every running send a 'run_stop' to the server, if you want
put the server back to normal
move.

The only reason for run mode on server side is, that now the server parse
every <direction>
cmd as a run <direction>. But thats nonsense.

Skip the on server side the run mode. Means, if you get a run <direction>,
all is like the
server do it yet, except he don't stay in run mode. This means, if you get a
run <dir>, <south>
the server runs in <dir> until it gets the <south>, you do one step south
and then stop, like you
send a run_stop before.

The point is, that you can put on client side the client in run mode, or
toggle it with ALT.
But if the client knows if the run mode is on, and he always must know it,
he always can send a
run <direction> (and all client do this) instead of a move <direction>. So,
if you think about it,
there is no need for the run/run_stop cmd.

Ok, but run_stop? Simple, use stay. Thats what the stay command is for, stay
after running or moving!
(also, i wil use it in fire mode as fire_stop, this will work fine).

One problem is, that when you are in run mode AND in fire mode, what happens
with a south cmd?

The idea is, that you put the client with ALT in run mode and with CTRL in
fire mode. 'r' and 'f'
let stay him always in fire/run mode and when you press CTRL/ALT then, it
shut fire/run down until
you release it. Somekind of inverse toggle then.

I test it, and it worked good.

Bad point is, that the clients don't use the run/fire mode flags from the
server, they simply
ignore it. More, they must work around it, because you can't send a single
'run' as run mode
init for the server, because you run then in yourself.

Also, one of top 5 questions of newbies is: 'how can i hit myself?'

For fire, we can do the same.

Ok, how it worked?

Now you thing a started client.

If you go south, you hit numpad key and a command south goes out.
if you toggle run or ALT, the server always send run <dir>. Server runs now
in the same way
as you know it. Release ALT (send 'stay'), <dir> is send, server go one
south and stop then.
It works without any 'run' mode. The server never knows the client status.

In real, it means that we ADD a cmd: a single <dir> is always a go <dir>
now, different from run <dir>.

( that means, we don't need send many run<dir> to run in a single
direction).

Now, what happens, if we hit ALT and run south for example and then we hit
CTRL? Now the fire mode is
on. At the moment, nothing happens. But if you press a num key a fire <dir>
is send. For the server
it means you stop running and fire a single shot in new <dir>. For CF as
action game, this will be
great.

->fire cmd always overrule run cmd

I prefer the single shot in this way. We CAN add mutiple shots, if we handle
the set fire mode with 'f'
as mutiple. What not all knows: In a command we can always send the numbers
of repeats. So we can easily
make a fire many times, and it is handled like the old style. Also, a 'stay'
command skip this mutiple
fire mode.

As you see, we can skip 4 commands, make it all with the cmds we still has.

dir = "north", "south", ...

run <dir>
fire <dir>
stay

The next point is, that 'run north' isn't a valid command, because the
fire/run command use numbers
instead of the strings. Also, this should be removed, to make a clear style
line.

Some words for glitches: the client never can handle all times the run/fire
mode in the old system.
If you toggle run mode, a south cmd in the cmd console will be 'run south'.
Thats bad style, because
it should be a step. Do this interactiv with the num pad is ok, but in the
console, a go should be not
run. You will see, that newbies and not so computer experienced people will
have problems with it.

(If you ever sell games, you will start think about things like this,
because you will encounter
that games magazines for example will talk about issues like this and not
about the great gameplay.
Its like the news in TV: the bad and stupid simple things are the
interesting ones, the big issues
and good things are out).


    
    


More information about the crossfire mailing list