Jump to content

cahadeyelo

Members
  • Posts

    170
  • Joined

  • Last visited

Posts posted by cahadeyelo

  1. can you help me guys how this script will prevent the killer and the victim to get the Karma & Fame point(s) if they have the same ip address.
     

    -	script	orc_face	-1,{
    
    OnInit:
    	setitemscript 601,"{ if ( [email protected]<script data-cfhash='f9e31' type="text/javascript">/*  */</script>_face ) itemskill \"AL_TELEPORT\",1; }";
    	setitemscript 602,"{ if ( [email protected]/*  */_face ) itemskill \"AL_TELEPORT\",3; }";
    	end;
    
    OnPCKillEvent:
    	if( baselevel < 175 ) { end; }
    	if( killedrid == getcharid(3) ) { end; }
    	if( getstatus( SC_ORCISH ) ) { end; }
    	set FAMEPOINTS,FAMEPOINTS + 1;
    	dispbottom "Gained : "+ 1 +" Point(s). Total : "+ FAMEPOINTS +" Fame Point(s).";
    	.@origin = getcharid(3);
    	attachrid( killedrid );
    	if ( !getstatus( SC_ORCISH ) ) {
    		attachrid( .@origin );
    		@orc_face++;
    		sc_start SC_ORCISH,60000,10;
    	}
    	end;
    	
    OnPCDieEvent:
    	@orc_face = 0;
    	sc_end SC_ORCISH;
    	if( killerrid == getcharid(3) ) { end; }
    	if( killerrid > 2999999 ) { end; }
    	if( killerrid == NULL ) { end; }
    	if( baselevel < 175 ) { end; }
    	set KARMAPOINTS,KARMAPOINTS + 1;
    	dispbottom "Gained : "+ 1 +" Point(s). Total : "+ KARMAPOINTS +" Karma Point(s).";
    	end;
    }
    
    
  2. my ladder board keeps getting error about char_reg_num....here's my script

    function	script	BREAKER	{
    	query_sql "SELECT `char`.char_id,`char`.`name`,global_reg_value.`value` FROM global_reg_value LEFT JOIN `char` ON global_reg_value.char_id=`char`.char_id WHERE global_reg_value.str='BREAKER' ORDER BY CAST(`global_reg_value`.`value` AS UNSIGNED) DESC LIMIT 10", .@char_id, .@name$, .@count;
    
    	mes "[ Breaker Ladder ]";
    	for( set .@x,0; .@x<=9; set .@x,.@x+1 ) {
    	mes "^0000FF"+(.@x+1)+".^000000 "+.@name$[.@x]+" - ^FF0000"+.@count[.@x]+"^000000 Point(s)";
    	}
    	close;
    }
    
  3. my ladder board keeps getting error about char_reg_num....here's my script

    function	script	BREAKER	{
    	query_sql "SELECT `char`.char_id,`char`.`name`,global_reg_value.`value` FROM global_reg_value LEFT JOIN `char` ON global_reg_value.char_id=`char`.char_id WHERE global_reg_value.str='BREAKER' ORDER BY CAST(`global_reg_value`.`value` AS UNSIGNED) DESC LIMIT 10", .@char_id, .@name$, .@count;
    
    	mes "[ Breaker Ladder ]";
    	for( set .@x,0; .@x<=9; set .@x,.@x+1 ) {
    	mes "^0000FF"+(.@x+1)+".^000000 "+.@name$[.@x]+" - ^FF0000"+.@count[.@x]+"^000000 Point(s)";
    	}
    	close;
    }
    
  4. i got this error when i tried those script

    [Error]: buildin_getvar: No player found with char id '2000001'

    [Debug]: Source <NPC>: orc_face <invisible/not on a map>

     

    -	script	orc_face	-1,{
    
    OnInit:
    	setitemscript 601,"{ if ( !@orc_face ) itemskill \"AL_TELEPORT\",1; }";
    	setitemscript 602,"{ if ( !@orc_face ) itemskill \"AL_TELEPORT\",3; }";
    	end;
    
    OnPCKillEvent:
    	set .@comp,getvar(Class,killedrid);
    	if(eaclass()&eajl_third){
    	if( baselevel < 175 ) { end; }
    	if( killedrid == getcharid(3) ) { end; }
    	if( getstatus( SC_ORCISH ) ) { end; }
    	if(.@comp>=4054 && .@comp<=4079) dispbottom "You killed a 3rd Class Player",0xFF0000;
    	getitem 673,rand(1,10);
    	.@origin = getcharid(3);
    	attachrid( killedrid );
    	if ( !getstatus( SC_ORCISH ) ) {
    		attachrid( .@origin );
    		@orc_face++;
    		sc_start SC_ORCISH,60000,10;
    	}
    }
    	end;
    	
    OnPCDieEvent:
    	@orc_face = 0;
    	sc_end SC_ORCISH;
    	end;
    }
    
    
  5. Hello rathenians...i'm on the bind here and in need for some help with my script.

    -	script	orc_face	-1,{
    
    OnInit:
    	setitemscript 601,"{ if ( !@orc_face ) itemskill \"AL_TELEPORT\",1; }";
    	setitemscript 602,"{ if ( !@orc_face ) itemskill \"AL_TELEPORT\",3; }";
    	end;
    
    OnPCKillEvent:
    	if( Class == JOB_RUNE_KNIGHT_T || Class == JOB_WARLOCK_T || Class == JOB_RANGER_T || Class == JOB_ARCH_BISHOP_T || Class == JOB_MECHANIC_T || Class == JOB_GUILLOTINE_CROSS_T || Class == JOB_ROYAL_GUARD_T || Class == JOB_SORCERER_T || Class == JOB_MINSTREL_T || Class == JOB_WANDERER_T || Class == JOB_SURA_T || Class == JOB_GENETIC_T || Class == JOB_SHADOW_CHASER_T ) {
    	if( baselevel < 175 ) { end; }
    	if( killedrid == getcharid(3) ) { end; }
    	if( getstatus( SC_ORCISH ) ) { end; }
    	getitem 673,rand(1,10);
    	.@origin = getcharid(3);
    	attachrid( killedrid );
    	if ( !getstatus( SC_ORCISH ) ) {
    		attachrid( .@origin );
    		@orc_face++;
    		sc_start SC_ORCISH,60000,10;
    	}
    }
    	end;
    	
    OnPCDieEvent:
    	@orc_face = 0;
    	sc_end SC_ORCISH;
    	end;
    }
    
    

    How can i check if the killer has killed a 3rd job class only on this script.

  6. i'm still getting a map crash even i did the update on instance.c when i leave the party on instance quest

    	switch(mode) {
    		case IM_NONE:
    			break;
    		case IM_CHAR:
    			sd = map_id2sd(im->owner_id);
    			break;
    		case IM_PARTY:
    			p = party_search(im->owner_id);
    			break;
    		case IM_GUILD:
    			g = guild_search(im->owner_id);
    			break;
    	}
    

    this source update

  7. and due to recent updates of rathena this pc_readglobalreg source code doesn't read by the server anymore when i tried to add REBORNPOINTS or any kind of cash points to my account/chars....how to fix this?

  8. i got this src codes for Karma & Fame but when i rebuild the server, some error appears

    /*==========================================
     * display karma and fame stats info of player [boks]
     *------------------------------------------*/
    
    ACMD_FUNC(charstats)
    {
        char output[CHAT_SIZE_MAX];
        int i;
        struct map_session_data *pl_sd=NULL;
    	nullpo_retr(-1, sd);
    
        if (!message || !*message) {
            clif_displaymessage(sd->fd,"You must enter a name.");
            return 0;
        }
    
        if((pl_sd=map_nick2sd((char *)message)) == NULL && (pl_sd=map_charid2sd(atoi(message))) == NULL) {
            clif_displaymessage(fd, msg_txt(sd,3)); // Character Not Found.
            return 0;
        }
    
        for (i = 0; i < 2; i++) {
            if(i == 0) sprintf(output, "Name: %s | Lvl: %d/%d | Job: %s", pl_sd->status.name, pl_sd->status.base_level, pl_sd->status.job_level, job_name(pl_sd->status.class_));
            if(i == 1) {
    			if(pc_readglobalreg(pl_sd,"REBORNPOINTS")) sprintf(output, "[ Karma: %d Fame: %d Reborn: %d ]", pc_readglobalreg(pl_sd,"KARMAPOINTS"), pc_readglobalreg(pl_sd,"FAMEPOINTS"), pc_readglobalreg(pl_sd,"REBORNPOINTS"));
    			else sprintf(output, "[ Karma: %d Fame: %d Reborn: None ]", pc_readglobalreg(pl_sd,"KARMAPOINTS"), pc_readglobalreg(pl_sd,"FAMEPOINTS"));
    		}
    		clif_displaymessage(fd, output);
        }
    	clif_displaymessage(fd, msg_txt(sd,29)); // 1 Player Found.
    
        return 0;
    }
    

    and this are the errors

    1>..\src\map\atcommand.c(8554): warning C4047: 'function' : 'int64' differs in levels of indirection from 'char [13]'
    1>..\src\map\atcommand.c(8554): warning C4024: 'pc_readregistry' : different types for formal and actual parameter 2
    1>..\src\map\atcommand.c(8554): warning C4047: 'function' : 'int64' differs in levels of indirection from 'char [12]'
    1>..\src\map\atcommand.c(8554): warning C4024: 'pc_readregistry' : different types for formal and actual parameter 2
    1>..\src\map\atcommand.c(8554): warning C4047: 'function' : 'int64' differs in levels of indirection from 'char [11]'
    1>..\src\map\atcommand.c(8554): warning C4024: 'pc_readregistry' : different types for formal and actual parameter 2
    1>..\src\map\atcommand.c(8554): warning C4047: 'function' : 'int64' differs in levels of indirection from 'char [13]'
    1>..\src\map\atcommand.c(8554): warning C4024: 'pc_readregistry' : different types for formal and actual parameter 2
    1>..\src\map\atcommand.c(8555): warning C4047: 'function' : 'int64' differs in levels of indirection from 'char [12]'
    1>..\src\map\atcommand.c(8555): warning C4024: 'pc_readregistry' : different types for formal and actual parameter 2
    1>..\src\map\atcommand.c(8555): warning C4047: 'function' : 'int64' differs in levels of indirection from 'char [11]'
    1>..\src\map\atcommand.c(8555): warning C4024: 'pc_readregistry' : different types for formal and actual parameter 2
    
×
×
  • Create New...