Jump to content
  • 0
Sign in to follow this  
ThyroDree

[Request] 1 Points ( Daily Points ) - 1 Card

Question

anyone teach me or help me how to make 

Gain 1 Point/s ( Daily Points ) - Per get 1 Normal Card

Gain 10 Point/s ( Daily Points ) - Per get 1 Boss/Mini Boss Card

Share this post


Link to post
Share on other sites

8 answers to this question

Recommended Posts

  • 0

example : gives/gain 1 Point( Daily Points ) everytime i hunt a mob and it drops a card or looted a card.

Share this post


Link to post
Share on other sites
  • 0

Could you please elaborate?

When a certain player kill a mob and that mob drop a card, the player gain points.

Share this post


Link to post
Share on other sites
  • 0

 src/map/mob.c | 3 +++ 1 file changed, 3 insertions(+)diff --git a/src/map/mob.c b/src/map/mob.cindex d504171..35fe37d 100644--- a/src/map/mob.c+++ b/src/map/mob.c@@ -2404,6 +2404,9 @@ int mob_dead(struct mob_data *md, struct block_list *src, int type) 				//MSG: "'%s' won %s's %s (chance: %0.02f%%)" 				intif_broadcast(message,strlen(message)+1,0); 			}+			if ( sd )+				if ( it->type == 6 )+					pc_setglobalreg( sd, "Daily_Points", pc_readglobalreg( sd, "Daily_Points" ) +( ( mob_db(md->mob_id)->status.mode & 32 )? 10 : 1 ) ); 			// Announce first, or else ditem will be freed. [Lance] 			// By popular demand, use base drop rate for autoloot code. [Skotlex] 			mob_item_drop(md, dlist, ditem, 0, md->db->dropitem[i].p, homkillonly);
this one works for rathena

hercules shouldn't be that far off

Edited by AnnieRuru

Share this post


Link to post
Share on other sites
  • 0

 

 src/map/mob.c | 3 +++ 1 file changed, 3 insertions(+)diff --git a/src/map/mob.c b/src/map/mob.cindex d504171..35fe37d 100644--- a/src/map/mob.c+++ b/src/map/mob.c@@ -2404,6 +2404,9 @@ int mob_dead(struct mob_data *md, struct block_list *src, int type) 				//MSG: "'%s' won %s's %s (chance: %0.02f%%)" 				intif_broadcast(message,strlen(message)+1,0); 			}+			if ( sd )+				if ( it->type == 6 )+					pc_setglobalreg( sd, "Daily_Points", pc_readglobalreg( sd, "Daily_Points" ) +( ( mob_db(md->mob_id)->status.mode & 32 )? 10 : 1 ) ); 			// Announce first, or else ditem will be freed. [Lance] 			// By popular demand, use base drop rate for autoloot code. [Skotlex] 			mob_item_drop(md, dlist, ditem, 0, md->db->dropitem[i].p, homkillonly);
this one works for rathena

hercules shouldn't be that far off

if i use this if the player receive o loot a cards gets a daily points?

Share this post


Link to post
Share on other sites
  • 0

yeah

 

now this is the patch for hercules

 src/map/mob.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)diff --git a/src/map/mob.c b/src/map/mob.cindex dab7b99..cd50475 100644--- a/src/map/mob.c+++ b/src/map/mob.c@@ -2367,7 +2367,9 @@ int mob_dead(struct mob_data *md, struct block_list *src, int type) { 				//MSG: "'%s' won %s's %s (chance: %0.02f%%)" 				intif->broadcast(message, strlen(message)+1, BC_DEFAULT); 			}-			+			if ( sd )+				if ( it->type == 6 )+					pc_setglobalreg( sd, script->add_str("Daily_Points"), pc_readglobalreg( sd, script->add_str("Daily_Points") )+( ( md->status.mode & 32 )? 10 : 1 ) ); 			/* heres the thing we got the feature set up however we're still discussing how to best define the ids, 			 * so while we discuss, for a small period of time, the list is hardcoded (yes officially only those 2 use it, 			 * thus why we're unsure on how to best place the setting) */

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.