Jump to content

Question

Posted (edited)

hi sir,i Need help for this

 

you can setting Zeny Penalty on exp.conf

// When a player dies (to another player), how much zeny should we penalize them with?
// NOTE: It is a percentage of their zeny, so 100 = 1%
zeny_penalty: 0

it's work if player killed by another player,but i want Zeny Penalty only work if Player killed by Monster ?

 

sorry for my bad english :D

Edited by croxinuz

6 answers to this question

Recommended Posts

Posted

try this

OnPCDieEvent:
.@zeny_penalty_percent = 10;
if( getmonsterinfo( killerrid,MOB_NAME ) != "null" ){
	.@zeny = (( Zeny / 100 ) * .@zeny_penalty_percent );
	Zeny -= .@zeny;
}
Posted

 

try this

OnPCDieEvent:
.@zeny_penalty_percent = 10;
if( getmonsterinfo( killerrid,MOB_NAME ) != "null" ){
	.@zeny = (( Zeny / 100 ) * .@zeny_penalty_percent );
	Zeny -= .@zeny;
}

doesn't work sir :(

Posted (edited)

Put it in an npc script like

-<tab>script<tab>ZenyPenalty<tab>-1,{

OnPCDieEvent:
.@zeny_penalty_percent = 10;
if( getmonsterinfo( killerrid,MOB NAME ) != "null" ){
	.@zeny = (( Zeny / 100 ) * .@zeny_penalty_percent );
	Zeny -= .@zeny;
}
}

Remember to put tabs on the top of the script and save it inside your "npc" folder located inside your server files and also apply it inside your script_custom.conf as "npc: npc/<folder_name>/<txt_filename>.txt "

 

Good luck matey.. Never tried the script though.

Edited by Spades
Posted

Put it in an npc script like

-<tab>script<tab>ZenyPenalty<tab>-1,{

OnPCDieEvent:
.@zeny_penalty_percent = 10;
if( getmonsterinfo( killerrid,MOB NAME ) != "null" ){
	.@zeny = (( Zeny / 100 ) * .@zeny_penalty_percent );
	Zeny -= .@zeny;
}
}

Remember to put tabs on the top of the script and save it inside your "npc" folder located inside your server files and also apply it inside your script_custom.conf as "npc: npc/<folder_name>/<txt_filename>.txt "

 

Good luck matey.. Never tried the script though.

i have write like this and doesn't work :o

-	script	z_penal	-1,{
OnPCDieEvent:
.@zeny_penalty_percent = 10;
if( getmonsterinfo( killerrid,MOB_NAME ) != "null" ){
	.@zeny = (( Zeny / 100 ) * .@zeny_penalty_percent );
	Zeny -= .@zeny;
}
}
Posted

Make sure you also added it inside your script_custom.conf located inside your npc folder.

 

If the problem persist, please show us the error by taking a screenshot from your map-server while you load the npc. Also make sure you have used @reloadscript

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...