Enable/Disable !help
 

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

Enable/Disable !help

Started by Janyn, 06 November, 2003, 18:31:54

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Janyn

hello

A want to disable !help i main
Anybody can help me?

Thank you!

[ES]latinmusic

Any script who have the command !help inside will disable the built in help. And for next version the stuf will be in the following way:
1. scripting commands have higher priority than textfiles
2. textfiles have higher priority than built-in commands
3. built-in commands take place if none of above overides it.
This is the only way to deactivate built in help.

Janyn

#2
you can take all scripts away, this !help is inside PtokaX hubbsoft. And a wanted Off

my problems is that error to krasch oDC++:

Runtime Error!

Program: C:\oDC\oDC.exe

This application has requsted the Runtime to terminate it in an unusual way.
Please contact the application's support for more information,

and that command really work's on other hub's not my :(

Thx....

Skrollster

I know this is more then what is nessisery to stop !help, but it is a good start for a script..

function DataArrival(tUser, sData)
	if (strsub(sData, 1, 1) == "<" ) then
		-- create a table
		local tArgs = {}
		-- Save sData in an array
		tArgs = tHelpFunctions:GetArgs(sData)
		-- Check if the user has used any of the hubprefixes
		tArgs = tHelpFunctions:CheckIfHasPrefix(tArgs)
		-- add sData as a variable to tArgs
		tArgs.sData = sData
		if tArgs.sPrefix then
			tUser.SendMessage = tUser.SendData
			local returnvalue = call(UserCommands[tArgs.sCmd],{UserCommands,tUser,tArgs}, "x", nil)
			if returnvalue then
				return returnvalue
			else
				return 0
			end
		else -- messages that isn't commands ends up here
		end
	end
end
tSettings = {
	tCmdPrefixes = {"!","+","gs:","?","#","?"},
}

tHelpFunctions = {
	CheckIfHasPrefix = function(self,tArgs)
			sToCheck = tArgs.sCmd
			local i
			local err
			for i = 1, getn(tSettings.tCmdPrefixes) do
				if strsub(sToCheck, 1, strlen(tSettings.tCmdPrefixes[i])) == tSettings.tCmdPrefixes[i] then
					tArgs.sCmd = strsub(sToCheck, strlen(tSettings.tCmdPrefixes[i])+1, strlen(sToCheck))
					tArgs.sPrefix = tSettings.tCmdPrefixes[i]
					break
				end
			end
			return tArgs
		end,
	GetArgs = function(self,sData)
			local tArgs = {}
			_,_,sData = strfind(sData, "%b<>%s+(.+)|")
			tArgs.sMessage = sData
			sData = strlower(sData)
			gsub(sData, "(%S+)", function (w) tinsert(%tArgs,w) end)
			tArgs.sCmd = tArgs[1]
			tremove(tArgs, 1)
			return tArgs
		end,
}

UserCommands = {
			help = function(self, tUser, tArgs)-- for all users
					-- Do your own help function here :)
					return 1
				end,
		}

OpiumVolage

Nice one Skrollster, just a little hard to read ;)

Janyn

alert:
Microsoft Visual C++ Runtime Library

You Wright !help in main in oDC++ and the client crasch!!!!

Somebody some have the same problems?

thx....

Troubadour

this is a client error, better ask around at the oDC++ forum or homepage (mail the creators)
Regards,

Troubadour

** Guardian Forum **

hubaddy:   nederfun.no-ip.com

SMF spam blocked by CleanTalk