Jump to content

Capuche

Developer
  • Posts

    2,407
  • Joined

  • Last visited

  • Days Won

    49

Posts posted by Capuche

  1. Except Nova (who actually has his own dev to gather their infos) none of us are running private server.

    On 20/12/2017 at 7:21 PM, Psyche said:

    And for sure, they will update or improve in their server first to attach people and earn some adventages before take it to rAthena.

    Stop spilling bullshit. I don't feel any respect on your comment.

     

    Any other comments off topic will now be deleted. Thanks for understanding.

  2. You're right we didn't update Upper for 3rd class.

    case SP_UPPER:           val = sd->class_&JOBL_UPPER?1:(sd->class_&JOBL_BABY?2:0); break;

    Maybe the easier structure for you to edit could be :

    prontera,150,193,4	script	Reset Girl	124,{
    	disable_items;
    	disable_command;
    
    	mes "[Reset Girl]";
    	switch( Class ) {
    	case JOB_NOVICE:// normal class
    	case JOB_SWORDMAN:
    	case JOB_MAGE:
    	case JOB_ARCHER:
    	case JOB_ACOLYTE:
    	case JOB_MERCHANT:
    	case JOB_THIEF:
    	case JOB_KNIGHT:
    	case JOB_PRIEST:
    	case JOB_WIZARD:
    	case JOB_BLACKSMITH:
    	case JOB_HUNTER:
    	case JOB_ASSASSIN:
    	case JOB_KNIGHT2:
    	case JOB_CRUSADER:
    	case JOB_MONK:
    	case JOB_SAGE:
    	case JOB_ROGUE:
    	case JOB_ALCHEMIST:
    	case JOB_BARD:
    	case JOB_DANCER:
    	case JOB_CRUSADER2:
    	case JOB_SUPER_NOVICE:
    	case JOB_GUNSLINGER:
    	case JOB_NINJA:
    
    	case JOB_BABY:// baby class
    	case JOB_BABY_SWORDMAN:
    	case JOB_BABY_MAGE:
    	case JOB_BABY_ARCHER:
    	case JOB_BABY_ACOLYTE:
    	case JOB_BABY_MERCHANT:
    	case JOB_BABY_THIEF:
    	case JOB_BABY_KNIGHT:
    	case JOB_BABY_PRIEST:
    	case JOB_BABY_WIZARD:
    	case JOB_BABY_BLACKSMITH:
    	case JOB_BABY_HUNTER:
    	case JOB_BABY_ASSASSIN:
    	case JOB_BABY_KNIGHT2:
    	case JOB_BABY_CRUSADER:
    	case JOB_BABY_MONK:
    	case JOB_BABY_SAGE:
    	case JOB_BABY_ROGUE:
    	case JOB_BABY_ALCHEMIST:
    	case JOB_BABY_BARD:
    	case JOB_BABY_DANCER:
    	case JOB_BABY_CRUSADER2:
    	case JOB_SUPER_BABY:
    
    	case JOB_TAEKWON:
    	case JOB_STAR_GLADIATOR:
    	case JOB_STAR_GLADIATOR2:
    	case JOB_SOUL_LINKER:
    		if (BaseLevel < 50)
    			[email protected] = 40000;
    		else if (BaseLevel < 90)
    			[email protected] = 70000;
    		else
    			[email protected] = 100000;
    		mes "Reset Stats: " + [email protected] + "z.";
    		mes "Reset Skills: " + [email protected] + "z.";
    		mes "Please select the service you want:";
    		next;
    		[email protected] = select( "Reset Skills", "Reset Stats" );
    		mes "[Reset Girl]";
    		if (Zeny < [email protected]) {
    			mes "Sorry, you don't have enough Zeny.";
    			close;
    		}
    		Zeny -= [email protected];
    		if ([email protected] == 2)
    			resetstatus;
    		else {
    			sc_end_class;
    			resetskill;
    		}
    		mes "There you go!";
    		close;
    
    	default:// others class
    		[email protected] = 1000000;
    		if (BaseLevel > 89)
    			[email protected] += 500000;
    		mes "Reset Stats: " + [email protected] + "z + 1 Monster Card.";
    		mes "Reset Skills: " + [email protected] + "z + 1 Monster Card.";
    		mes "Please select the service you want:";
    		next;
    		[email protected] = select( "Reset Skills", "Reset Stats" );
    		mes "[Reset Girl]";
    		if (Zeny < [email protected]) {
    			mes "Sorry, you don't have enough Zeny.";
    			close;
    		}
    		getinventorylist;
    		for ( [email protected] = 0; [email protected] < @inventorylist_count; [email protected]++ ) {
    			if (getiteminfo(@inventorylist_id[[email protected]],2) != 6)
    				continue;
    			[email protected]_id[[email protected]_size] = @inventorylist_id[[email protected]];
    			[email protected]_name$[[email protected]_size] = getitemname( @inventorylist_id[[email protected]] );
    			[email protected]_size++;
    		}
    		if ([email protected]_size < 1) {
    			mes "Sorry, you don't have enough Card.";
    			close;
    		}
    		mes "Which card do you want to use?";
    		next;
    		[email protected] = select( implode([email protected]_name$,":") ) - 1;
    		mes "[Reset Girl]";
    		if (Zeny < [email protected]) {
    			mes "It shouldn't happen.";
    			close;
    		}
    		if (countitem([email protected]_id[[email protected]]) < 1) {
    			mes "It shouldn't happen.";
    			close;
    		}
    		Zeny -= [email protected];
    		delitem [email protected]_id[[email protected]],1;
    		if ([email protected] == 2)
    			resetstatus;
    		else {
    			sc_end_class;
    			resetskill;
    		}
    		mes "There you go!";
    		close;
    	}
    }

     

  3. Untested

    prontera,150,193,4	script	Reset Girl	124,{
    	disable_items;
    	disable_command;
    
    	mes "[Reset Girl]";
    	switch( Upper ) {
    	case 0:// normal class
    	case 2:// baby class
    		if (BaseLevel < 50)
    			[email protected] = 40000;
    		else if (BaseLevel < 90)
    			[email protected] = 70000;
    		else
    			[email protected] = 100000;
    		mes "Reset Stats: " + [email protected] + "z.";
    		mes "Reset Skills: " + [email protected] + "z.";
    		mes "Please select the service you want:";
    		next;
    		[email protected] = select( "Reset Skills", "Reset Stats" );
    		mes "[Reset Girl]";
    		if (Zeny < [email protected]) {
    			mes "Sorry, you don't have enough Zeny.";
    			close;
    		}
    		Zeny -= [email protected];
    		if ([email protected] == 2)
    			resetstatus;
    		else {
    			sc_end_class;
    			resetskill;
    		}
    		mes "There you go!";
    		close;
    	case 1:// advanced class
    		[email protected] = 1000000;
    		if (BaseLevel > 89)
    			[email protected] += 500000;
    		mes "Reset Stats: " + [email protected] + "z + 1 Monster Card.";
    		mes "Reset Skills: " + [email protected] + "z + 1 Monster Card.";
    		mes "Please select the service you want:";
    		next;
    		[email protected] = select( "Reset Skills", "Reset Stats" );
    		mes "[Reset Girl]";
    		if (Zeny < [email protected]) {
    			mes "Sorry, you don't have enough Zeny.";
    			close;
    		}
    		getinventorylist;
    		for ( [email protected] = 0; [email protected] < @inventorylist_count; [email protected]++ ) {
    			if (getiteminfo(@inventorylist_id[[email protected]],2) != 6)
    				continue;
    			[email protected]_id[[email protected]_size] = @inventorylist_id[[email protected]];
    			[email protected]_name$[[email protected]_size] = getitemname( @inventorylist_id[[email protected]] );
    			[email protected]_size++;
    		}
    		if ([email protected]_size < 1) {
    			mes "Sorry, you don't have enough Card.";
    			close;
    		}
    		mes "Which card do you want to use?";
    		next;
    		[email protected] = select( implode([email protected]_name$,":") ) - 1;
    		mes "[Reset Girl]";
    		if (Zeny < [email protected]) {
    			mes "It shouldn't happen.";
    			close;
    		}
    		if (countitem([email protected]_id[[email protected]]) < 1) {
    			mes "It shouldn't happen.";
    			close;
    		}
    		Zeny -= [email protected];
    		delitem [email protected]_id[[email protected]],1;
    		if ([email protected] == 2)
    			resetstatus;
    		else {
    			sc_end_class;
    			resetskill;
    		}
    		mes "There you go!";
    		close;
    	}
    }

     

  4. 	switch( checkquest(7122,PLAYTIME) ) {// 4 hours
    	case -1:	// Quest not started (not in quest log)
    	case 0:	// the time limit has not yet been reached -> cooldown
    	case 1:	// the time limit has not been reached but the quest is marked as complete
    	case 2:	// the time limit has been reached -> can redo the quest
    	}
    	end;

    case 0 and case 1 should return the cooldown message. case 2 player can redo the quest

    • Upvote 1
  5. 1. The blank message is a trick (until better implementation) to prevent attached player to interact with others NPCs (to mimic official behaviour).

    2. We need more information about the effect of Mind Blaster skill before implement it.

    • Like 1
  6.  

    
    // Old Glast Heim
    12316,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"Meeting Hugin"
    12317,82800,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"Trace of Time Travel"
    12318,0,2475,1,0,0,0,0,0,0,0,0,0,0,0,0,0,"Corrupted Soul Hunt"
    12319,0,2476,1,0,0,0,0,0,0,0,0,0,0,0,0,0,"Amdarais Hunt"
    12320,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"Time Traveler"
    12321,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"Time Conqueror"
    12322,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"Space Distortion"

     

    • Like 1
  7.  

    -	script	Controller	-1,{
    OnPcDieEvent:
    	if (strcharinfo(3) == instance_mapname("geffen")) {
    		'chance++;
    		if ('chance == 3)
    			mapwarp instance_mapname("geffen"),"prontera",150,150;
    		else
    			mapannounce instance_mapname("geffen"), "" + strcharinfo(0) + " has died! you only have " + (3 - 'chance) + " lives remaining.", bc_all;
    	}
    	end;
    }

    should work.

     

    About the script with the timer : forget it. After reading the commit, https://github.com/rathena/rathena/commit/9c46f3e6ba288c71f098b12834ea25779eadbc0e just prevent to duplicate npcs with script event in instance.

     

    Notes:

    - strcharinfo(3) return the real map name of the player.

    - instance_mapname doc :

    If no instance ID is specified,
    the instance the script is attached to is used. If the script is not attached to
    an instance, the instance of the currently attached player is used (if it is a
    character, party, guild or clan mode).

    Within your OnPCDieEvent instance_mapname will use by default the instance id attached to the player.

     

    EDIT: @crazyarashi please double check your script before posting!

    • Upvote 1
    • MVP 1
  8. You can, for example, attach a timer to the character.

    
    	@instance_map$ = instance_mapname("instance");
    	deltimer strnpcinfo(0) + "::OnAtcommand4";
    	addtimer 300, strnpcinfo(0) + "::OnAtcommand4";
    	end;
    
    OnAtcommand4:
    	if (strcharinfo(3) != @instance_map$) {
    		@instance_map$ = "";
    		end;
    	}
    	addtimer 300, strnpcinfo(0) + "::OnAtcommand4";
    	if (Hp < 1) {
    		'chance++;	// 'var attached to the instance
    		if ('chance == 3)
    			mapwarp @instance_map$,"prontera",150,150;
    		else {
    			mapannounce @instance_map$, strcharinfo(0) + " has died! you only have " + (3 - 'chance) + " lives remaining.",bc_all;
    			recovery 0;
    		}
    	}
    	end;

     

×
×
  • Create New...

Important Information

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