Jump to content

Gerz

Members
  • Content Count

    59
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by Gerz


  1. @@AnnieRuru how about this?

     

    /** * pcblock <account_id>, <value>, <type> * <value>: 1 = on, 0 = off * <type> can be: *     0 = block move *     1 = block attack *     2 = block skill *     3 = block chat *     4 = immune attack **/BUILDIN(pcblock) {	int id, flag, type;	TBL_PC *sd = NULL;	id = script_getnum(st,2);	flag = script_getnum(st,3);	type = script_getnum(st,4);	if( id )		sd = map->id2sd(id);	else		sd = script->rid2sd(st);	switch( type ) {		case 0: sd->state.blockedmove = flag > 0; break;		case 1: sd->state.blockedattack = flag > 0; break;		case 2: sd->state.blockedskill = flag > 0; break;		case 3: sd->state.blockedchat = flag > 0; break;		case 4: sd->state.monster_ignore = flag > 0; break;	}	return true;}
    BUILDIN_DEF(pcblock,"iii"),

  2. prontera,100,100,4	script	Zeny Ranking	100,{	mes "[Zeny Ranking]";	mes "Top " + .MaxShow + " richest in the server:";	query_sql "select `name`,`zeny` from `char` where `zeny` > 0 order by `zeny` desc limit " + .MaxShow + "", .@name$, .@zeny;	for( .@i = 0; .@i < getarraysize(.@zeny); .@i++ )		mes "~ [.@i + 1] ~ " + .@name$[.@i] + " | Zeny: " + .@zeny[.@i] + "";	close;OnInit:	.MaxShow = 5;	end;}

  3. @ firstly, in case you're using wrong function :v, do not work like a machine, just view code!

     

    second, you want to make bonus script to add bonus to extract item id or to all healing sp items?

     

    my code work to increase % sp healing for all healing items :v

     

    bonus bAddItemSpRate,n;				Increases SP recovered by n% for healing items.

    Update ver2 :v

     

    bAddItemSpRate_v2.diff

     

    bonus to extract item id:

     

    bonus2 bAddItemSpRate,id,n;			Increases SP recovered by n% for item id/ig

  4. or you can use my scriptcommand :v

     

    BUILDIN(getguildlvl){	int guild_id;	struct guild* g;	guild_id = script_getnum(st,2);	if( ( g = guild->search(guild_id) ) != NULL )		script_pushint(st,g->guild_lv);	else		script_pushint(st,0);	return true;}
    BUILDIN_DEF(getguildlvl, "i"),

    Usage:

    getguildlvl(guild_id)

  5. first error:

     

    extra_bonus[count].script = script->parse(str, path, lines, 0, NULL); 

    2nd:

                if(pc_readglobalreg(sd,script->add_str("extra_bonus")) && extra_bonus[pc_readglobalreg(sd,script->add_str("extra_bonus"))].script)               script->run(extra_bonus[pc_readglobalreg(sd,script->add_str("extra_bonus"))].script,0,sd->bl.id,0); 

     

×
×
  • Create New...

Important Information

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