L2Tower Discord Let's keep the community alive with discord. Discussions about plugins and scripts L2Tower Discord

Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
plugins worng ?
Author Message
benbt91 Offline
VIP Member
***

Posts: 694
Joined: Mar 2012
Reputation: 47
Version: 1.4.3.143
Post: #1
plugins worng ?

    LUA Programming
function OnChatSystemMessage(id, msg)
 
		if (id == 3292)  then 	
		Command("@abcd");
 
		end;
		end;



hum i don't know why it isn't work Big Grin someone can help me this ?
thnks for read
07-10-2014 20:07 PM
Find all posts by this user Quote this message in a reply
 Reputed by : jonathan915(+1)
tophersoccer Offline
Expired VIP Member
**

Posts: 422
Joined: Aug 2012
Reputation: 142
Version: 1.4.3.143
Post: #2
RE: plugins worng ?

(07-10-2014 20:07 PM)benbt91 Wrote:  
    LUA Programming
function OnChatSystemMessage(id, msg)
 
 if (id == 3292) then 
 Command("@abcd");
 
 end;
 end;



hum i don't know why it isn't work Big Grin someone can help me this ?
thnks for read


There's alot more code involved than what you have when making a plugin. Here is something that will get you started:

    LUA Programming
start = false;
 
function OnCreate()
	this:RegisterCommand("plugin", CommandChatType.CHAT_ALLY, CommandAccessLevel.ACCESS_ME); 
end;
 
function OnCommand_plugin(vCommandChatType, vNick, vCommandParam)
	if(start == false) then
 start = true;
 ShowToClient("GOD", "Plugin is on.")
 else
 start = false;
 ShowToClient("GOD", "Plugin is off.")
 end;
end;
 
 
function OnChatSystemMessage(id, msg) -- this is what you had
 if (id == 3292) then 
 Command("@abcd");
 end;
end;
 
function OnLTick1s()
 if(start == true)
 --this is where you write what you want to do
 end;
end;

(This post was last modified: 07-10-2014 22:48 PM by tophersoccer.)
07-10-2014 22:36 PM
Find all posts by this user Quote this message in a reply
 Reputed by : jonathan915(+1) , benbt91(+2)
jonathan915 Offline
Porta
*

Posts: 43
Joined: Oct 2013
Reputation: 0
Version: 1.4.2.138
Post: #3
RE: plugins worng ?

maybe its a great help for me... ^^ I try using that--- ^^

U have any way for test a plugin,,, without loguin and crash the game? XD
07-10-2014 22:43 PM
Find all posts by this user Quote this message in a reply
tophersoccer Offline
Expired VIP Member
**

Posts: 422
Joined: Aug 2012
Reputation: 142
Version: 1.4.3.143
Post: #4
RE: plugins worng ?

(07-10-2014 22:43 PM)jonathan915 Wrote:  maybe its a great help for me... ^^ I try using that--- ^^

U have any way for test a plugin,,, without loguin and crash the game? XD

No, not that I know of.
(This post was last modified: 07-10-2014 22:50 PM by tophersoccer.)
07-10-2014 22:49 PM
Find all posts by this user Quote this message in a reply
 Reputed by : jonathan915(+1)
jonathan915 Offline
Porta
*

Posts: 43
Joined: Oct 2013
Reputation: 0
Version: 1.4.2.138
Post: #5
RE: plugins worng ?

I need use a skill when one sysmsg ....

But i cant use command "then Useskill" ...
I use command ("/useshortcut 1 1") -... but not work,
I need use coroutine?? or what is the best way to use a skill when say a systemmsg??

Maybe i can put here my plugin,, i u see what is wrong... ^^
07-11-2014 01:11 AM
Find all posts by this user Quote this message in a reply
tophersoccer Offline
Expired VIP Member
**

Posts: 422
Joined: Aug 2012
Reputation: 142
Version: 1.4.3.143
Post: #6
RE: plugins worng ?

(07-11-2014 01:11 AM)jonathan915 Wrote:  I need use a skill when one sysmsg ....

But i cant use command "then Useskill" ...
I use command ("/useshortcut 1 1") -... but not work,
I need use coroutine?? or what is the best way to use a skill when say a systemmsg??

Maybe i can put here my plugin,, i u see what is wrong... ^^


Jonathan, i saw your private message and i tried to private message you back but it says your private messaging is disabled. And also, could you describe your issue a little bit better?

Also Jonathan. I advise you to make your code as a script instead of a plugin because it is easier and WAY faster to troubleshoot. Therefore, once you can verify that your code is working as a script then you can convert it to a plugin.
(This post was last modified: 07-11-2014 02:25 AM by tophersoccer.)
07-11-2014 02:21 AM
Find all posts by this user Quote this message in a reply
jonathan915 Offline
Porta
*

Posts: 43
Joined: Oct 2013
Reputation: 0
Version: 1.4.2.138
Post: #7
Wink RE: plugins worng ?

NO,, im trying make a plugin... i can put here....

Code:
tart = false;

function OnCreate()
    this:RegisterCommand("plugin", CommandChatType.CHAT_ALLY, CommandAccessLevel.ACCESS_ME);
end;

function OnCommand_plugin(vCommandChatType, vNick, vCommandParam)
    if(start == false) then
start = true;
ShowToClient("Sign ","Auto Fish Mode on.");
else
start = false;
ShowToClient("Sign ","Auto Fish Mode off.");
end;
end;


function OnLTick1s()
if(start == true) then --this is where you write what you want to do

function OnChatSystemMessage(id, msg)
    if (id == 1449) then -- bit
      Command("/useshortcut 10 3"); -- Reeling
    end;
end;

function OnChatSystemMessage(id, msg)
    if (id == 1467) or (id == 1464) or (id == 1466) then -- caused o resisi
      Command("/useshortcut 10 3"); -- Reeling
    end;
end;
function OnChatSystemMessage(id, msg)
    if (id == 1468)or(id == 1465) then -- faikl
      Command("/useshortcut 10 4"); -- Pumping
    end;
end;
function OnChatSystemMessage(id, msg)
    if (id == 1469) or (id == 1450) or (id == 1458) or (id == 1451) or (id == 1452) then -- caused
      Command("/useshortcut 10 2"); -- Fishing
    end;
end;

end;
end;

I need use skills,, but UseSkill not work in plugin,, Ans i use Cmmand /shortcut 1 1 ex:.. And put my skills in shortcut bar... i read something about a coroutine... but i dont know how to use that-... PLs givme the way... ^^ thnkz

NOw,, i hv active the PM... sry,, i dont remember that....
(This post was last modified: 07-11-2014 02:32 AM by jonathan915.)
07-11-2014 02:27 AM
Find all posts by this user Quote this message in a reply
TheQQmaster Offline
Trolling the Trolls
*****

Posts: 1,532
Joined: Jun 2012
Reputation: 642
Version: 1.4.2.133
Post: #8
RE: plugins worng ?

search id in
.zip  sysmsg.zip (Size: 423 bytes / Downloads: 49)

    LUA Programming
AlarmStatus = false;
 
CheckSound = GetDir() .. "\\path_to_wav";
 
 
function OnCreate()
	this:RegisterCommand("alarm", CommandChatType.CHAT_ALLY, CommandAccessLevel.ACCESS_ME);
end;
 
 
 
function OnCommand_alarm(vCommandChatType, vNick, vCommandParam)
	if (AlarmStatus == false) then
 AlarmStatus = true;
 ShowToClient("ALARM","Plugin ON");
	else
 AlarmStatus = false;
 ShowToClient("ALARM","Plugin OFF");
	end;
end;
 
 
 
function OnChatSystemMessage(id, msg)
	if (AlarmStatus == true) then
 if id==503 then
 Command('@i am pro');
 PlaySound(CheckSound);
 end;
	end;
end;


PUSH [Image: knUu53] IF HELPED
07-11-2014 03:56 AM
Visit this user's website Find all posts by this user Quote this message in a reply
 Reputed by : benbt91(+2) , jonathan915(+1) , diegol(+2)
benbt91 Offline
VIP Member
***

Posts: 694
Joined: Mar 2012
Reputation: 47
Version: 1.4.3.143
Post: #9
RE: plugins worng ?

why i can't donwload system.zip Sad ... just Loading and Loading Big Grin

Ty All for help Big Grin

(07-11-2014 03:56 AM)TheQQmaster Wrote:  search id in

    LUA Programming
AlarmStatus = false;
 
CheckSound = GetDir() .. "\\path_to_wav";
 
 
function OnCreate()
	this:RegisterCommand("alarm", CommandChatType.CHAT_ALLY, CommandAccessLevel.ACCESS_ME);
end;
 
 
 
function OnCommand_alarm(vCommandChatType, vNick, vCommandParam)
	if (AlarmStatus == false) then
 AlarmStatus = true;
 ShowToClient("ALARM","Plugin ON");
	else
 AlarmStatus = false;
 ShowToClient("ALARM","Plugin OFF");
	end;
end;
 
 
 
function OnChatSystemMessage(id, msg)
	if (AlarmStatus == true) then
 if id==503 then
 Command('@i am pro');
 PlaySound(CheckSound);
 end;
	end;
end;


hum it's nothing happens too ! when i try to login or logout char added in friendlist ! him just do nothing Smile!
i did search right id with log out and log in sysmessage in system Sad

(07-10-2014 22:36 PM)tophersoccer Wrote:  
(07-10-2014 20:07 PM)benbt91 Wrote:  
    LUA Programming
function OnChatSystemMessage(id, msg)
 
 if (id == 3292) then 
 Command("@abcd");
 
 end;
 end;



hum i don't know why it isn't work Big Grin someone can help me this ?
thnks for read


There's alot more code involved than what you have when making a plugin. Here is something that will get you started:

    LUA Programming
start = false;
 
function OnCreate()
	this:RegisterCommand("plugin", CommandChatType.CHAT_ALLY, CommandAccessLevel.ACCESS_ME); 
end;
 
function OnCommand_plugin(vCommandChatType, vNick, vCommandParam)
	if(start == false) then
 start = true;
 ShowToClient("GOD", "Plugin is on.")
 else
 start = false;
 ShowToClient("GOD", "Plugin is off.")
 end;
end;
 
 
function OnChatSystemMessage(id, msg) -- this is what you had
 if (id == 3292) then 
 Command("@abcd");
 end;
end;
 
function OnLTick1s()
 if(start == true) then
 Command("@abcd");
 end;
end;

after use this ... him spam non-stop Big Grin hix hix T_T
(This post was last modified: 07-11-2014 06:23 AM by benbt91.)
07-11-2014 05:18 AM
Find all posts by this user Quote this message in a reply
TheQQmaster Offline
Trolling the Trolls
*****

Posts: 1,532
Joined: Jun 2012
Reputation: 642
Version: 1.4.2.133
Post: #10
RE: plugins worng ?

it works, yesterday before posted, I tested, but only for party joining, faund id, u just neeed to find correct id, use good editor and all be good

PUSH [Image: knUu53] IF HELPED
07-11-2014 09:44 AM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
WTS help plugins Augment Interlude blackzer01 0 3,440 01-18-2016 17:01 PM
Last Post: blackzer01
  how do get Daily Mission item for script or plugins? king200527 0 2,336 10-26-2015 17:03 PM
Last Post: king200527
  WTB Auto accept mail scripts or plugins king200527 0 2,385 07-07-2015 11:39 AM
Last Post: king200527
  cant see unstuck plugin on /cfg plugins after infinite odysey drake182 0 2,294 05-13-2015 16:23 PM
Last Post: drake182
  Do you use PVP scripts/plugins? Vinter 2 3,821 11-07-2014 17:54 PM
Last Post: Vinter
  How do plugins work? erwin004 3 2,882 02-04-2014 04:17 AM
Last Post: erwin004
  Lindvior new classes problem in plugins and scripts tuxevil 15 11,349 05-31-2013 00:03 AM
Last Post: infernum
  How use Plugins ? szakal161 1 2,762 12-15-2012 15:16 PM
Last Post: Fox
  Party in plugins horato 0 2,058 12-05-2012 22:21 PM
Last Post: horato
  Plugins Everest 8 6,636 10-02-2012 12:42 PM
Last Post: Everest



User(s) browsing this thread: