PtokaX forum

Archive => Archived 5.0 boards => Help with scripts => Topic started by: Tarot on 27 February, 2005, 21:05:06

Title: Tag by ??????Hawk?????? 05-07-2004
Post by: Tarot on 27 February, 2005, 21:05:06
is it posible to convert to lua 5 fore me i like this script

--====COPY FROM THIS LINE===== ??????Gotham??????


--Description Tag by ??????Hawk?????? 05-07-2004

--===Sets the tag to be shown in reg's descriptions=================

regTagInDescription = "??????Reg??????"      --\\ Tag

--==================================================================
--===Sets the tag to be shown in Vip's descriptions=================

VipTagInDescription = "??????Vip??????"      --\\ Tag

--==================================================================
--===Sets the tag to be shown in op's descriptions==================

OpsTagInDescription = "??????Op??????"         --\\ Tag

--==================================================================
--===Sets the tag to be shown in masters's descriptions=============

MastersTagInDescription = "??????Master??????"      --\\ Tag

--==================================================================
--===Sets the time for the tags to be updated=======================

MastersTagInDescription = "??????Owner??????"      --\\ Tag

--==================================================================

Mins =  1

--==================================================================



timer = 60000 * Mins
function Main()
   SetTimer(timer)
   StartTimer()
end

function OnTimer()
   TagInDescription()
end

function TagInDescription()
   local aux,usr
   for aux, usr in GetUsersByProfile("vip") do
      if (GetItemByName(usr) ~= nil) then
         local userToShow = GetItemByName(usr)
         if (userToShow.sMyInfoString ~= nil) then
            local s,e,name,desc,speed,email,share = strfind(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
            SendToAll( "$MyINFO $ALL "..name.." "..VipTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
         end
      end
   end
   for aux, usr in GetUsersByProfile("operator") do
      if (GetItemByName(usr) ~= nil) then
         local userToShow = GetItemByName(usr)
         if (userToShow.sMyInfoString ~= nil) then
            local s,e,name,desc,speed,email,share = strfind(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
            SendToAll( "$MyINFO $ALL "..name.." "..OpsTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
         end
      end
   end
   for aux, usr in GetUsersByProfile("master") do
      if (GetItemByName(usr) ~= nil) then
         local userToShow = GetItemByName(usr)
         if (userToShow.sMyInfoString ~= nil) then
            local s,e,name,desc,speed,email,share = strfind(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
            SendToAll( "$MyINFO $ALL "..name.." "..MastersTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
         end
      end
   end
      for aux, usr in GetUsersByProfile("reg") do
      if (GetItemByName(usr) ~= nil) then
         local userToShow = GetItemByName(usr)
         if (userToShow.sMyInfoString ~= nil) then
            local s,e,name,desc,speed,email,share = strfind(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
            SendToAll( "$MyINFO $ALL "..name.." "..regTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
         end
      end
   end
end
Title:
Post by: ??????Hawk?????? on 27 February, 2005, 21:49:39
--Description Tag by ??????Hawk?????? 27-02-2005 LUA 5

--===Sets the tag to be shown in reg's descriptions=================

regTagInDescription = "??????Reg??????" --\\ Tag

--==================================================================
--===Sets the tag to be shown in Vip's descriptions=================

VipTagInDescription = "??????Vip??????" --\\ Tag

--==================================================================
--===Sets the tag to be shown in op's descriptions==================

OpsTagInDescription = "??????Op??????" --\\ Tag

--==================================================================
--===Sets the tag to be shown in masters's descriptions=============

MastersTagInDescription = "??????Master??????" --\\ Tag

--==================================================================
--===Sets the time for the tags to be updated=======================

MastersTagInDescription = "??????Owner??????" --\\ Tag

--==================================================================

Mins = 1

--==================================================================



timer = 60000 * Mins
function Main()
SetTimer(timer)
StartTimer()
end

function OnTimer()
TagInDescription()
end

function TagInDescription()
local aux,usr
for aux, usr in GetUsersByProfile("vip") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..VipTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
for aux, usr in GetUsersByProfile("operator") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..OpsTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
for aux, usr in GetUsersByProfile("master") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..MastersTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
for aux, usr in GetUsersByProfile("reg") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..regTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
end





BTW   above Script is a Feature In  Xsthetic Netserver  :P  :P


??????Hawk??????
Title:
Post by: Tarot on 27 February, 2005, 22:00:16
great work Hawk and a fast service

i like the script it is great
Title:
Post by: LILLITH on 09 March, 2005, 12:34:47
Is it possible to add NetFounder and Moderator profiles in this GREAT script?

Thanx in advance! :)
Title:
Post by: 6Marilyn6Manson6 on 09 March, 2005, 12:53:38
QuoteOriginally posted by LILLITH
Is it possible to add NetFounder and Moderator profiles in this GREAT script?

Thanx in advance! :)

Yeppa:

--Description Tag by ??????Hawk?????? 05-07-2004
--Add Description For Moderator And NetFounder by 6Marilyn6Manson6
--===Sets the tag to be shown in Vip's descriptions=================

VipTagInDescription = "{ViP}"   --\\ Tag

--==================================================================
--===Sets the tag to be shown in op's descriptions==================

OpsTagInDescription = "{OP}"   --\\ Tag

--==================================================================
--===Sets the tag to be shown in masters's descriptions=============

MastersTagInDescription = "{MaSTeR}"   --\\ Tag

--==================================================================
--===Sets the tag to be shown in moderators's descriptions==========

ModeratorTagInDescription = "{MoDeRaToR}"   --\\ Tag

--==================================================================
--===Sets the tag to be shown in NetFounder's descriptions==========

NetFounderTagInDescription = "{NetFounder}"   --\\ Tag

--==================================================================
--===Sets the tag to be shown in reg's descriptions=================

regTagInDescription = "{ReG}"   --\\ Tag

--==================================================================
--===Sets the time for the tags to be upos.dated====================

Mins =  1

--==================================================================



timer = 60000 * Mins
function Main()
SetTimer(timer)
StartTimer()
end

function OnTimer()
TagInDescription()
end

function TagInDescription()
local aux,usr
for aux, usr in GetUsersByProfile("vip") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..VipTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
for aux, usr in GetUsersByProfile("operator") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..OpsTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
for aux, usr in GetUsersByProfile("master") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..MastersTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
for aux, usr in GetUsersByProfile("Moderator") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..ModeratorTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
for aux, usr in GetUsersByProfile("NetFounder") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..NetFounderTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
for aux, usr in GetUsersByProfile("reg") do
if (GetItemByName(usr) ~= nil) then
local userToShow = GetItemByName(usr)
if (userToShow.sMyInfoString ~= nil) then
local s,e,name,desc,speed,email,share = string.find(userToShow.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll( "$MyINFO $ALL "..name.." "..regTagInDescription.." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
end

bye bye
Title:
Post by: LILLITH on 09 March, 2005, 13:01:40
What would i do without you? :D
Title:
Post by: 6Marilyn6Manson6 on 09 March, 2005, 13:16:51
No prob ;)
Title:
Post by: night_hawk on 18 April, 2005, 04:37:24
i just used the new lua5 verion you had when i added it to my hub it will not show me as netfounder...moderater, operater, master vip or reg...what am i doing wrong..what the tags to show up in discriptsions i am useing robocop10 and new ptokax 16.09...i really need this set up for me
Title:
Post by: bastya_elvtars on 18 April, 2005, 04:49:19
Hmmm, this script is one of those which need rewriting IMHO... I have no time, but gonna give hints to others:

Title: thank you
Post by: night_hawk on 18 April, 2005, 05:06:05
i hope this will not take long i really can not wait to stop using test drive 4 and start the new one up just i really need so much done at this time..
Title: Tag Script
Post by: osse on 22 October, 2005, 10:43:51
Very good script......

UnReg Tag can you add to the script???


Thnx...
Title:
Post by: Markitos on 22 October, 2005, 11:00:51
QuoteOriginally posted by osse
Very good script......

UnReg Tag can you add to the script???


Thnx...
You can do it manually...take a good look in the script.

Cheers...
Title:
Post by: Optimus on 22 October, 2005, 11:35:03
----------------------------------------------------------------------------
-- Description Tag by ??????Hawk?????? 05-07-2004
-- Add Description For Moderator And NetFounder by 6Marilyn6Manson6
-- Totaly rewriten by Optimus 22-10-2005
-- Only works for registerd profiles, otherwise it takes to much bandwidth
----------------------------------------------------------------------------

-- Sets the time for the tags to be updated
Minutes =  1

-- Set Profile Tags
tProfileTag = {
[1] = "{OP}",
[2] = "{ViP}",
[3] = "{ReG}",
[4] = "{MoDeRaToR}",
[5] = "{NetFounder}",
[0] = "{MaSTeR}",
}

Main = function()
SetTimer(60000 * Minutes)
StartTimer()
end

OnTimer = function()
for id,usr in pairs(frmHub:GetOnlineRegUsers()) do
if usr.sMyInfoString then
local s,e,name,desc,speed,email,share = string.find(usr.sMyInfoString, "$MyINFO $ALL (%S+)%s+([^$]*)$ $([^$]*)$([^$]*)$([^$]+)")
SendToAll("$MyINFO $ALL "..name.." "..tProfileTag[usr.iProfile].." "..desc.."$ $"..speed.."$"..email.."$"..share.."$")
end
end
end
summ like this ;)
Title:
Post by: bastya_elvtars on 22 October, 2005, 15:28:01
Then what's the use of MyINFO stripping? I hope you see how stupid this script is.
Title:
Post by: 6Marilyn6Manson6 on 22 October, 2005, 15:37:08
I love this script but version of ??????Hawk?????? or 6Marilyn6Manson6 :p. C ya
Title:
Post by: ??????Hawk?????? on 22 October, 2005, 16:40:09
QuoteOriginally posted by bastya_elvtars
Then what's the use of MyINFO stripping? I hope you see how stupid this script is.

if theres a better way of adding a tag on to a users description then please feel free to post it ...

scripts are not always " Ideal "  BUT its what ppl want..


??????Hawk??????
Title:
Post by: Optimus on 22 October, 2005, 16:51:59
QuoteThen what's the use of MyINFO stripping? I hope you see how stupid this script is.
bastya_elvtars has allways something to complaine about. It's not really positive feedback

- Optimus
Title:
Post by: bastya_elvtars on 22 October, 2005, 16:54:13
I don't complain, but you are spitting the greatest feature of PtokaX in the eye, and not use but abuse LUA.
Title:
Post by: Optimus on 22 October, 2005, 16:55:57
thats your opinion. the old script looked liked shit so it was time for a rewrite. Nothing more nothing less

;)
Title:
Post by: bastya_elvtars on 22 October, 2005, 17:59:49
QuoteOriginally posted by Optimus
thats your opinion. the old script looked liked shit so it was time for a rewrite. Nothing more nothing less

;)

OK, then here is some warning:

If you use this script, PtokaX will use more CPU and 2.5-3 times more bandwidth.

I miss this from the script's initial comments.

No offence meant, these are facts.
Title:
Post by: Optimus on 22 October, 2005, 18:18:37
QuoteIf you use this script, PtokaX will use more CPU and 2.5-3 times more bandwidth.
That problem was allready there with the old version. i thought you allready knew
Title:
Post by: ??????Hawk?????? on 22 October, 2005, 19:18:12
QuoteOriginally posted by bastya_elvtars
QuoteOriginally posted by Optimus
thats your opinion. the old script looked liked shit so it was time for a rewrite. Nothing more nothing less

;)

OK, then here is some warning:

If you use this script, PtokaX will use more CPU and 2.5-3 times more bandwidth.

I miss this from the script's initial comments.

No offence meant, these are facts.


CPU usage (60 sec avg): 0.17%   Runnin Terminator with this option enabled......   OUCH didnt realise my CPU was soooo  High   :P


??????Hawk??????
Title:
Post by: bastya_elvtars on 22 October, 2005, 19:32:28
Hehe, what are your computer specs? How many users? What is your Internetg connection like?
The number 0.17% is not evaluable in itself without this information (only serves masturbation purposes), sorry to disappoint you, I thought it does not have to be told to a developer.
Anyway it can be considered a good progress to see non-compiled code from both of you.
Title:
Post by: Optimus on 22 October, 2005, 19:48:36
Quoteonly serves masturbation purposes
why such stupid comments. Are you some kind of wanker??

1.) i don't use this code myself in robocop just helping others. I'm hating the script asswell in mater of speaking of bandwidth/resources but hey if others like it go ahead

2.) you gave the hints so your guilty asswell

3.) I checked your script and it's full of loops at to many places i tested it in test hub. and it takes why to much memory and bandwidth. So you can say your script really sucked. I can go on for many hours if you would like to

But hey your were probably bored and wanked your self to much today. so you started critisising others on this board for none positive purposes.

Did ya like my message, naaa i don't think so. Go clean up your act wise guy
Title:
Post by: Northwind on 22 October, 2005, 20:25:26
hey, stop fighting :-)

I personally respect ya all... and everyone has he's weaknes and strongness... i try to learn lua and best way to learn is see difrence kind of scripts and many many mods of them.
Title:
Post by: ??????Hawk?????? on 22 October, 2005, 20:39:22
QuoteOriginally posted by Northwind
hey, stop fighting :-)

I personally respect ya all... and everyone has he's weaknes and strongness... i try to learn lua and best way to learn is see difrence kind of scripts and many many mods of them.

Yes  maby  but  how many  noobs to LUA  will be posting their code after reading this  ..  only to be SHOT DOWN.

it is good for developement to have comments  good and bad  ..  but the bad ones should be posted with either Better code or a hint as to how to improve.

This thread  is  yet  Another reason for the use of  LUAC.EXE


??????Hawk??????
Title:
Post by: 6Marilyn6Manson6 on 22 October, 2005, 20:44:09
Stop :D
Title: LOL
Post by: Markitos on 22 October, 2005, 21:46:56
QuoteOriginally posted by ??????Hawk??????
This thread  is  yet  Another reason for the use of  LUAC.EXE


??????Hawk??????
Title:
Post by: bastya_elvtars on 22 October, 2005, 22:24:13
QuoteOriginally posted by Optimus
Quoteonly serves masturbation purposes
why such stupid comments. Are you some kind of wanker??

1.) i don't use this code myself in robocop just helping others. I'm hating the script asswell in mater of speaking of bandwidth/resources but hey if others like it go ahead

Yes, I made similar scripts but warned others.

QuoteOriginally posted by Optimus
2.) you gave the hints so your guilty asswell

I am helpful. Sorry 'bout that, I am really guilty.

QuoteOriginally posted by Optimus
3.) I checked your script and it's full of loops at to many places i tested it in test hub. and it takes why to much memory and bandwidth. So you can say your script really sucked. I can go on for many hours if you would like to

Which script of mine? I have 4 main projects and written countless small scripts.

QuoteOriginally posted by Optimus
But hey your were probably bored and wanked your self to much today. so you started critisising others on this board for none positive purposes.

I just tried to tell you to warn users about the side-effects. I would not criticise others to please myself. You can create statistics of my offensive posts if you would like to.

I finish now as well, because sooner or later I would take over your 'intelligence' and I want to avoid it here, because this is a really nice place. Sorry for saying 'stupid', I will not use such words in the future, but your reaction isn't even worth criticising, plus you should know what I meant when I said 'masturbation purposes', really no offence meant with that.

!me marks the topic read only for himself...
Title:
Post by: Optimus on 23 October, 2005, 12:01:10
QuoteI finish now as well, because sooner or later I would take over your 'intelligence' and I want to avoid it here, because this is a
Well my english is verry bad so it hard to defend myself against your well writtenn passages. Has nothing todo with intelligence.

So for me there is nothing more left to say that your a big wanker and i will allways see it like that. Your ego has outgrown your self

Adios wanker
Title:
Post by: bastya_elvtars on 23 October, 2005, 13:01:57
Ehh, I have to break my promise. I meant your 'kind' words, not your English, I would never criticise people for bad English, I am not Sulan. :D
I wanted to start a discussion, not a battle, it was not me who lit the flame.

You should not feel aggrieved, the one who should is ??????Hawk??????.

Regarding my script, you are always welcome to post suggestions to the development section of my forum. On the other hand, this was somewhat shameless attack because I cannot hit back.

Please, close the thread. I won't open another, I promise.
Title:
Post by: 6Marilyn6Manson6 on 23 October, 2005, 13:02:33
QuoteOriginally posted by Mutor
This is hilarious.

I'm not kidding I'm Antichrist Superstar :p
Title:
Post by: Optimus on 23 October, 2005, 13:57:24
Well i suppose this was ment tobe.

- thread closed -