Jump to content
  • 0

AnniRuru Limit skull drop need help and changing


Diss

Question


  • Group:  Members
  • Topic Count:  67
  • Topics Per Day:  0.02
  • Content Count:  207
  • Reputation:   1
  • Joined:  05/01/13
  • Last Seen:  

/*
create table last_pvp_kill (
id int(11) unsigned primary key auto_increment,
killercid int(11) unsigned not null,
killedcid int(11) unsigned not null,
count smallint(6) unsigned,
key (killercid),
key (killedcid)
) engine = innodb;
*/

-	script	jfhdksfjhsk	-1,{
OnClock0000:
	query_sql "truncate last_pvp_kill;";
	end;
OnPCKillEvent:
	if ( killedrid == getcharid(3) ) end;
	if ( query_sql( "select count from last_pvp_kill where killercid = "+( .@killercid = getcharid(0) )+" and killedcid = "+( .@killedcid = getcharid( 0, rid2name( killedrid ) ) ), .@count ) ) { // check if the user is in the list
		if ( .@count == .max_skull ) {
			dispbottom "you have reach the max amount of skull for that player today";
			end;
		}
		query_sql "update last_pvp_kill set count = count +1 where killercid = "+ .@killercid +" and killedcid = "+ .@killedcid;
	}
	else
		query_sql "insert into last_pvp_kill values ( null, "+ .@killercid +", "+ .@killedcid +", 1 )"; // insert into table
	getitem2 7420, 1,1,0,0, 254, 0, .@killedcid % ( 1 << 16 ), .@killedcid >> 16;
	end;
OnInit:
	.max_skull = 3;
	end;
}

hi this anniruru script limiting skull drop anyone can help me  i want this script on designated map only to avoid feeding by dueling 

 

thnks to anniruru for very nice script .

 

thnks for helping in advance

Link to comment
Share on other sites

4 answers to this question

Recommended Posts


  • Group:  Developer
  • Topic Count:  10
  • Topics Per Day:  0.00
  • Content Count:  2407
  • Reputation:   616
  • Joined:  07/05/12
  • Last Seen:  


OnPCKillEvent:

- if ( killedrid == getcharid(3) ) end;

+ if ( killedrid == getcharid(3) || strcharinfo(3) != "<map name>" ) end;

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  67
  • Topics Per Day:  0.02
  • Content Count:  207
  • Reputation:   1
  • Joined:  05/01/13
  • Last Seen:  

OnPCKillEvent:
-	if ( killedrid == getcharid(3) ) end;
+	if ( killedrid == getcharid(3) || strcharinfo(3) != "<map name>" ) end;

thanks sir its works 

 

i've try to add some map like this

 

if ( killedrid == getcharid(3) || strcharinfo(3) != "prontera,geffen" ) end; or

if ( killedrid == getcharid(3) || strcharinfo(3) != "prontera","geffen" ) end;

 

but its not works

 

and the script if i killed the char x3 for today after 2 days its say 

 

"you have reach the max amount of skull for that player today"

 

anyone can helpme in this script

 

thanks

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  50
  • Topics Per Day:  0.01
  • Content Count:  1702
  • Reputation:   241
  • Joined:  09/05/12
  • Last Seen:  

Multiple maps : 

OnPCKillEvent:
-    if ( killedrid == getcharid(3) ) end;
+    // || strcharinfo(3) != "<map name>"
+    if ( killedrid == getcharid(3) || strcharinfo(3) != "<map name>" || strcharinfo(3) != "<map name>" ) end;
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  67
  • Topics Per Day:  0.02
  • Content Count:  207
  • Reputation:   1
  • Joined:  05/01/13
  • Last Seen:  

Multiple maps : 

OnPCKillEvent:
-    if ( killedrid == getcharid(3) ) end;
+    // || strcharinfo(3) != "<map name>"
+    if ( killedrid == getcharid(3) || strcharinfo(3) != "<map name>" || strcharinfo(3) != "<map name>" ) end;

 

hi sir can you help me again

 

the script if i killed the char x3 for today after 2 days its say 

 

"you have reach the max amount of skull for that player today"

 

anyone can helpme in this script

 

thanks

sir patskie multiple map not working

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...