The online racing simulator
lfs lapper question
(23 posts, started )
lfs lapper question
hi there ,

im kinda newb with insim and i just edited lfs lapper to make it better for my server

i have some question

1. i use !kick !ban !spec !end !restart !x other command to administrate my server (soo i dont have to change password when i change to another when i have admin)

soo i was wondering if there is any way to hide the command
i mean i dont want to let ppl know that i wrote !kick username

2.i was wondering if i can add something to the insim like a drift angle in the HUD (witch refresh)

3.to complete the question 1 is it possible with lapper to do something like

Quote :Register MsgAction("!kick",MA_kick);
Sub MA_kick()
$allow = "lfs-drift staff";
cmdLFS( "/msg " . $Nickname . "^1 got kicked by " . $Nickname . );
cmdLFS( "/ban " . $argv . " 1" );

EndSub

i mean i want the insim show who got kicked and who kicked him

i also noticed that the msg command line is wrong to show what i want to
bump
1. No it not possible to hide those commands
2. Yes that's possible, look in the original Lapper thread (last page) to see an example of Tim[NL]
3. It's possible but not in the way you wrote it.

Your 3th question could be solved by a global-var that is declared when a certain player logs in to the server. Then this global-var can be read when writing something like a kick action.


####################################
#Event triggered when Lapper starts#
###################################$
Event OnLapperStart()
GlobalVar $admin_name;
$admin_name="";
EndEvent

#################################################
#Connect messages when a player joins the server#
#################################################

Event OnConnect()
IF ($Username == "lfs-drift staff")
THEN
$admin_name=$Username;
ENDIF
EndEvent

#################
#Command actions#
#################

Register MsgAction("!kick",MA_kick);
Sub MA_kick()
$allow = "lfs-drift staff";
cmdLFS( "/ban " . $argv . " 1" );
cmdLFS( "/msg " . $Nickname . " ^8got kicked by " . $admin_name);
EndSub

thx for this answer ill answer back if i get a problem
instead of showing the admin username is it possible to show the nickname ?

and if there is more than one admin using the insim does the insim know witch admin do the admin command i mean
if

me : lfs-drift staff = $admin_name
does another username can be = $admin_name

or if im the first loggued in and a second admin logg in and write !kick xxx it will show

xxx got kicked by lfs-drift staff ?
Quote from lfs-drift staff :instead of showing the admin username is it possible to show the nickname ?

and if there is more than one admin using the insim does the insim know witch admin do the admin command i mean
if

me : lfs-drift staff = $admin_name
does another username can be = $admin_name

or if im the first loggued in and a second admin logg in and write !kick xxx it will show

xxx got kicked by lfs-drift staff ?

Hi,
Try this.

####################################
#Event triggered when Lapper starts#
###################################$
Event OnLapperStart()
PlayerVar $admin_name="";
EndEvent
#################################################
#Connect messages when a player joins the server#
#################################################
Event OnConnect()
IF( $Username == "lfs-drift staff" || $Username == "admin_1" || $Username == "admin_2" )
THEN
$admin_name=$Nickname;
ENDIF
EndEvent
#################
#Command actions#
#################
Register MsgAction("!kick",MA_kick);
Sub MA_kick()
$allow = "lfs-drift staff,admin_1,admin_2";
cmdLFS( "/ban " . $argv . " 1" );
cmdLFS( "/msg " . $Nickname . " ^8got kicked by " . $admin_name);
EndSub

Hmm I wrote an answer for the new questions of lfs-drift, I posted it this afternoon and now it's gone. Anyway, it was mostly the same as Tim his answers execpt for the PlayerVar which was a GlobalVar in my script.
Quote from Yisc[NL] :Hmm I wrote an answer for the new questions of lfs-drift, I posted it this afternoon and now it's gone. Anyway, it was mostly the same as Tim his answers execpt for the PlayerVar which was a GlobalVar in my script.

Hi,

When using a PlayerVar , more admin's can online at the same moment.
Hiding the command must be possible somehow.
Isnt on insim, if something occurs, a list of things that happens?
There you somehow gotta add a hide command to the insim, so that it hides.
(hidin these things is possible on other insim prorams, so why not with that??)
thx alot guys for your help ill try this asap

Quote from Stefani24 :Hiding the command must be possible somehow.

Isnt on insim, if something occurs, a list of things that happens?

There you somehow gotta add a hide command to the insim, so that it hides.

(hidin these things is possible on other insim prorams, so why not with that??)

it may not be possible to hide

like if i write in the chat "!kick xxx" it will show up in the chat area
but if there is no command like $hide! (witch would automatically hide message starting with !)
(just an exemple cuz i dont realy know insim :P)

then there is no way to hide the message

----------------

@tim NL :

####################################
#Event triggered when Lapper starts#
###################################$
Event OnLapperStart()
PlayerVar $admin_name=[COLOR="red"]""[/COLOR];
EndEvent

do i add username of admin between " " like "lfs-drift staff,xxx,xxxx" ? just want to be sure lol

EDIT: ok i tryed several thing and when i kick it show:

"my nickname" got kicked by "my nickname" (it also kick the one i want but show my nickname instead of his nickname)
i tryed to find where that was comming from but ... i found nothing


EDIT2:
Quote from Yisc[NL] :

2. Yes that's possible, look in the original Lapper thread (last page) to see an example of Tim[NL]


i searched and the only thing i found is :
Quote from Tim NL :Hi,

Small question and a request for the future.



Is it posible to use



- Loop methods

WHILE ... ENDWHILE

FOR ... STEP ... NEXT



And CASE Select is that posible ( maybe in future version)?

is it what you was talking about ?
Quote from Tim NL :
##################
#Drifting options#
##################
.
.
.
Event OnDriftScore()
openPrivButton( "drf0",99,1,22,10,4,-1,16," " );
IF( $AngleVelocity < 0 )
THEN
$Angle_drift=($AngleVelocity)*(-1);
openPrivButton( "drf1",100,2,20,4,4,-1,32,"Score: ^7" . $DriftScore . " ^3" . $LastDriftScore );
openPrivButton( "drf2",100,6,20,4,4,-1,32,"Drift Angle: ^7" . $Angle_drift . "^2>" );
ELSE
openPrivButton( "drf1",100,2,20,4,4,-1,32,"Score: ^7" . $DriftScore . " ^3" . $LastDriftScore );
openPrivButton( "drf2",100,6,20,4,4,-1,32,"Drift Angle: ^2<^7" . $AngleVelocity . " " );
ENDIFEndEvent


Hi,
It's not posible to show the driftangle with refresh (in LFSLapper) only the (last) driftscore and the last driftangle.
$DriftScore -> Drift score
$AngleVelocity -> Last Angle velocity in degrees
$LastDriftScore -> Last drift score
ok thx

-------

if you can find something to fix my problem with this

Quote :"my nickname" got kicked by "my nickname" (it also kick the one i want but show my nickname instead of his nickname)
i tryed to find where that was comming from but ... i found nothing

Please post your code so we can see what's wrong.
####################################
#Event triggered when Lapper starts#
###################################$
Event OnLapperStart()
PlayerVar $admin_name="";
EndEvent


#################################################
#Connect messages when a player joins the server#
#################################################
Event OnConnect()
IF( $Username == "lfs-drift staff" || $Username == "superpower" || $Username == "rocawork" )
THEN
$admin_name=$Nickname;
ENDIF
EndEvent


#################
#Command actions#
#################
Register MsgAction("!kick",MA_kick);
Sub MA_kick()
$allow = "lfs-drift staff,superpower,rocawork";
cmdLFS( "/kick " . $argv );
cmdLFS( "/msg " . $Nickname . " ^8got kicked by " . $admin_name);
EndSub

Hello,

$NickName is the nickname of the player doing action. In this case You. You can display argv to show username. But for now, what you want it's not possible ( $NickName of the banned user ). For now

Gai-Luron
ok thx for answer
Ah stupid me
I'm glad Gai has switched the light back on and cleared up my mistake.
Quote from lfs-drift staff :thx alot guys for your help ill try this asap it may not be possible to hide

like if i write in the chat "!kick xxx" it will show up in the chat area
but if there is no command like $hide! (witch would automatically hide message starting with !)
(just an exemple cuz i dont realy know insim :P)

then there is no way to hide the message


Gai-Luron, can you add that function to your next version please?
Thanks in advance
Quote : Originally Posted by lfs-drift staff
thx alot guys for your help ill try this asap it may not be possible to hide

like if i write in the chat "!kick xxx" it will show up in the chat area
but if there is no command like $hide! (witch would automatically hide message starting with !)
(just an exemple cuz i dont realy know insim :P)

then there is no way to hide the message

Hi,
I have maked a new script to kick user's without to show the command.
Only !kick the first time.
It's for 24 player's for this time, if you want more it's up to you (copy and past work's fine with some small changes).

A other solution is to join your server with the admin password then you can kick and ban direct from the connectionbox (N).

PS. i did't had the time to test it but i think it work's.
Attached files
kick with buttons (24 players).txt - 13 KB - 169 views
thx look like interesting ill try this and ill give you news
Quote from Tim NL :
A other solution is to join your server with the admin password then you can kick and ban direct from the connectionbox (N)

i know that but i run 3 server and i hate to switch admin pw each time i go on an other one soo i work with insim its way faster

lfs lapper question
(23 posts, started )
FGED GREDG RDFGDR GSFDG