PDA

View Full Version : Trailing???


Shakaraja
12-03-2007, 09:37 PM
im just new to this scripting stuff
im trying to make a sick script (desease)
but i need to add a trail i seen it on a few servers eg: graal legacy, interitus and in a AEON event. i wondered how i create the trail
could anybody help me on this please? thank you ^^

Shakaraja
12-03-2007, 09:54 PM
btw its also used for earthquakes and stuff

napo_p2p
12-03-2007, 10:13 PM
I'm not sure what you mean by 'trail'... elaborate?

Pimmeh
12-03-2007, 11:24 PM
I think he means particles that slowly fade after the player leaves a spot, like the remnants of an aura.

Crow
12-03-2007, 11:29 PM
Maybe also something like the blood on Era?

Shakaraja
12-04-2007, 03:29 PM
none of those..
i meen like a special trail part of a person its like when u get hit on era with a bottle my a NPC in some quest thing then u go drunk or something like that,
then when u walk everything slowly fades like
instead of instant moving (---->) it goes trailed (----> ---> --> -> >)
do i need to create a video to show what i meen xD?

Crow
12-04-2007, 04:04 PM
I know what you mean. You call that motion blur. Its actually a bug with the tile layers alpha value. Well, Stefan once said its not a bug, I still think it is. Basically, what you do is change the alpha value of the default tile layer.

//#CLIENTSIDE
function onCreated() {
tilelayers[0].alpha = .5;
player.gmap.tilelayers[0].alpha = .5;
}

It has to be set below 1 and above 0. How strong the motion blur is depends on the alpha value. Smaller = stronger.

Shakaraja
12-04-2007, 04:09 PM
alright thats exactly what i ment, thank you crow :)
but how do i reset it putting it back to 1?

DustyPorViva
12-04-2007, 04:09 PM
Actually, you have to do so in a timeout, I believe.
//#CLIENTSIDE
function onCreated() {
onTimeout();
}

function onTimeout() {
tilelayers[0].alpha = .5;
player.gmap.tilelayers[0].alpha = .5;
setTimer(0.05);
}

Shakaraja
12-04-2007, 04:14 PM
thx dusty but i already have iti n a timeout :)
good tip tough :)

Crow
12-04-2007, 04:17 PM
I just tried that right now, and the timeout isnt needed :D Thats what I like about this.

Shakaraja
12-04-2007, 04:30 PM
and i fixed the blur thank you all :)