Jump to content
  • 0

[Done]How dissable some @ command by event?


anacondaq

Question


  • Group:  Members
  • Topic Count:  42
  • Topics Per Day:  0.01
  • Content Count:  1096
  • Reputation:   345
  • Joined:  02/26/12
  • Last Seen:  

[solved

First of all, sorry for my bad english.

1.) I want ask here about my some problem. I have some high rate server with enabled by default for all players @warp command.

This command very usefull, but sometimes give a lot of troubles. But i wont to disable it. I need find different way for solve my problem.

My problem is: i have some quest, where need come to npc to talk (many npc around of world), best way to get fun and "happyness" from this quest, thats "running" read and do that quest without @warp command. So, how to disable @warp command for players for time when they do that quest?

I have few ideas about my trouble.

In npc script put some variable what disable @warp for current player forever. But when this player finish this quest (what he start to do). he get again come back his @warp command to use that.

My logic: add to npc when quest started some variable for disable @warp

do quest without @warp only for this player what do quest

In end part of script come back his @warp command to him

Edited by neqste
Link to comment
Share on other sites

3 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  382
  • Reputation:   38
  • Joined:  01/17/12
  • Last Seen:  

You could create a group with the same rights as the group id 0 but without @warp and then use:

atcommand "@adjgroup <your new group id>";

But this will only work until the next relog.

You could make it work forever by 2 ways.

  1. Use a SQL query to set the group id forever. I don't think there is a command for it. atleast i found none:
    *query_sql "your MySQL query", <array variable> {,<array variable>, ...};


  2. Or check if the quest variable is set on login then use the atcommand:
    OnPCLoginEvent:
    if (que_Test >= 1) atcommand "@adjgroup <your new group id>";
    end;


  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  42
  • Topics Per Day:  0.01
  • Content Count:  1096
  • Reputation:   345
  • Joined:  02/26/12
  • Last Seen:  

You could create a group with the same rights as the group id 0 but without @warp and then use:

atcommand "@adjgroup <your new group id>";

Sorry please, with my english2russia barrier i have some problem) can you "as like for idiot" talk about what you say.

P.S. Sorry i understand. but dont understand logic how that work.

Ok, i createin atcommand group of commands what need for server, but without @warp command right?

and when someone do quest, he have from START no warp before doing quest right? but i need "@warp before quest too"

only for time when this player do quest @warp must be disabled

P.P.S. UNDERSTAND! first group with all needest commands without @warp, else group with all needest commands with @warp!!??

i am right???

Edited by neqste
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  382
  • Reputation:   38
  • Joined:  01/17/12
  • Last Seen:  

Here is an example:

prontera,146,174,4 script Example Quest 727,{
if (que_Test == 1) goto L_QuestEnd;
mes "[Quest Example]";
mes "here quest";
close2;
set que_Test,1;
atcommand "@adjgroup 2"; // 2 is just an example
end;

L_QuestEnd:
 mes "[Quest Example]";
 mes "finish quest";
 close2;
 set que_Test,0;
 atcommand "@adjgroup 0"; // Reset rights
 end;


OnPCLoginEvent:
 if (que_Test == 1) atcommand "@adjgroup 2"; // 2 is just an example
 end;
}

  • Upvote 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...