right click
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

right click

Started by ((KMN))Gazza-95, 25 July, 2006, 21:39:00

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

((KMN))Gazza-95

how do u add a right click function i lua 5.1

plz help

bastya_elvtars

Everything could have been anything else and it would have just as much meaning.

((KMN))Gazza-95


bastya_elvtars

If you search the forum, you will find a discussion on this here (IIRC).
Everything could have been anything else and it would have just as much meaning.

((KMN))Gazza-95

soory m8 i dint make it clear enough my mestak i men what is the function to add a right click command into a script

sorry m8 my bad

bastya_elvtars

user:SendData("$UserCommand 1 3 Help$!help|")
Everything could have been anything else and it would have just as much meaning.

((KMN))Gazza-95

thx m8 i will try it
Posted on: 2006-07-25, 23:16:38
i cant ger it to work

bastya_elvtars

Everything could have been anything else and it would have just as much meaning.

Psycho_Chihuahua

well try something more like this
function NewUserConnected(user)
		user:SendData("$UserCommand 1 3 Help$!help|")
end

OpConnected = NewUserConnected
PtokaxWiki ?PtokaX Mirror + latest Libs

01100001011011000111001101101111001000000110101101101110011011110111011101101110001000000110000101110011001000000101010001101111011010110110111101101100011011110111001101101000

bastya_elvtars

Cannot help write-only users, sorry. :-P
Everything could have been anything else and it would have just as much meaning.

((KMN))Gazza-95

thx all i eventually got it working

thx again

bastya_elvtars

Quote from: ((KMN))Gazza-95 on 07 August, 2006, 22:57:02
thx all i eventually got it working

thx again

Care to share your work with us?
Everything could have been anything else and it would have just as much meaning.

((KMN))Gazza-95

not finished yet m8 lol soz but will wen finished kk

The_ArchitecT

function NewUserConnected(user)
		user:SendData("$UserCommand 1 3 Help$<[%mynick]>!help&#124;")
end

OpConnected = NewUserConnected


<[%mynick]>  indicates that the command is coming from you

i.e. if my nick is Billy, then the result, when I type !help would normally be shown as <Billy> !help in the hub...

speedX

#14
function NewUserConnected(user)
   user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart#124;|")
end


i made this right click for my trivia script.....ut works fine but after clicking on it....i have type some thing in main chat....thn only it shows trivia started by speedX......adn the game starts....wat error is there??
Thanking You,

speedX

Thor

Use this format:
function NewUserConnected(user)
   user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
end

So not two endpipe, first will be &#124;
Btw: http://dcpp.net/wiki/index.php/%24UserCommand

speedX

#16
thank u guys...1 last request...
Quote
function NewUserConnected(user)
   user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
end

OpConnected = NewUserConnected

i want to add one right click only for ops and masters.... i.e
Quote
user:SendData("$UserCommand 1 3 Registration\\Add User$<%[mynick]> !addreguser %[line:Nick] %[line:Pass] Reg&#124;")

Where and how to put this command???


Thanking You,

speedX

6Marilyn6Manson6

#17
Quote from: speedX on 06 October, 2006, 10:42:17
thank u guys...1 last request...
i want to add one right click only for ops and masters.... i.e
Where and how to put this command???




Change:

function NewUserConnected(user)
   user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
end

OpConnected = NewUserConnected


with:

function NewUserConnected(user)
	user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
end

function OpConnected(user)
	if user.bOperator and (user.iProfile ==  0 or user.iProfile ==  1) then
		user:SendData("$UserCommand 1 3 Registration\\Add User$<%[mynick]> !addreguser %[line:Nick] %[line:Pass] Reg&#124;")
		user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
	end
end


C ya

Rincewind

Quote from: 6Marilyn6Manson6 on 06 October, 2006, 11:50:19
Change:

function NewUserConnected(user)
   user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
end

OpConnected = NewUserConnected


with:

function NewUserConnected(user)
	user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
end

function OpConnected(user)
	if user.bOperator and (user.iProfile ==  0 or user.iProfile ==  1) then
		user:SendData("$UserCommand 1 3 Registration\\Add User$<%[mynick]> !addreguser %[line:Nick] %[line:Pass] Reg&#124;")
		user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
	end
end


C ya
Much better to do
function NewUserConnected(user)
   user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
   if user.bOperator then
      user:SendData("$UserCommand 1 3 Registration\\Add User$<%[mynick]> !addreguser
   end
end

OpConnected = NewUserConnected


6Marilyn6Manson6

Quote from: Rincewind on 06 October, 2006, 18:26:06
Much better to do
function NewUserConnected(user)
   user:SendData("$UserCommand 1 3 Triva\\Start Trivia$<%[mynick]> !trivstart&#124;|")
   if user.bOperator then
      user:SendData("$UserCommand 1 3 Registration\\Add User$<%[mynick]> !addreguser
   end
end

OpConnected = NewUserConnected



Mmm I agree  ;D

speedX

#20
Hi guys...
Quote
   user:SendData("$UserCommand 1 3 HOPS\\IP Help\\Nick From IP$<%[mynick]> +ip %[line:IP]&#124;|")
   user:SendData("$UserCommand 0 3 ")
   user:SendData("$UserCommand 1 3 HOPS\\Alerts\\Add Alert$<%[mynick]> +addalert %[line:nick]&#124;|")

I would like a separator between IP help and Alerts......but the codes wich i have entered makes a separator after Nick frm IP.....wat is the error ??  i tried to go through the link above.......but didn get it.....plzzz help...
Thanking You,

speedX

Rincewind

I believe the separator would be
curUser:SendData("$UserCommand 0 3 |")

Give that a try and let me know how you get on

speedX

nope not workin......it is showing me the following error....
Syntax ...PtokaX & Scripts\test 0.3.5.1\scripts\rightclick.lua:12: attempt to index global 'curUser' (a nil value)
Thanking You,

speedX

Herodes

Quote from: speedX on 07 October, 2006, 18:08:12
nope not workin......it is showing me the following error....
Syntax ...PtokaX & Scripts\test 0.3.5.1\scripts\rightclick.lua:12: attempt to index global 'curUser' (a nil value)

what is the script you are running,..?
Because as I searched the thread I didn't find 'curUser' anywhere,
I assume that you copy-pasted some code.
Post up the script that you are trying to code in the developing problems forums (look at the board index.)

speedX

no....it is not a script or thread......i am just making my own right.....first i disable teh right click of all my scripts and thn cuztomizing my own right click.......in making my own right click i faced a porb while making a separator.......read my above post.....
Thanking You,

speedX

SMF spam blocked by CleanTalk