Jump to content
Promise

Trade GMs Mod

Recommended Posts

Hi everyone, this is my 2nd free source release for rAthena.

 

  • - By PromisE
  • - v1.0
  • - GMs Ignore necessary distance to trade
  • - Broadcast on GM trade (group_id > 1 || < 99 -- Normal Players and admins dont send broadcast on trade.)

Apply Guide:

Open src/map/trade.c

1.- find:

	// Players can not request trade from far away, unless they are allowed to use @trade.
	if (!pc_can_use_command(sd, "trade", COMMAND_ATCOMMAND) &&
	    (sd->bl.m != target_sd->bl.m || !check_distance_bl(&sd->bl, &target_sd->bl, TRADE_DISTANCE))) {
		clif_tradestart(sd, 0); // too far
		return ;
	} 

2.- Replace to:

	// Players can not request trade from far away, unless they are allowed to use @trade.
	// 1.0 GMS ignore distance limit [PromisE]
	// 1.1 Broadcast on GM trade [PromisE]
	if ( pc_get_group_level(sd) <= 50 && !pc_can_use_command(sd, "trade", COMMAND_ATCOMMAND) && (sd->bl.m != target_sd->bl.m || !check_distance_bl(&sd->bl, &target_sd->bl, TRADE_DISTANCE))) {
		clif_tradestart(sd, 0); // too far
		return ;
	}

	if (pc_get_group_level(sd) >= 1 && pc_get_group_level(sd) < 99) {
	npc_event(sd,"TradeSecure::OnSettings",0);
	target_sd->trade_partner = sd->status.account_id;
	sd->trade_partner = target_sd->status.account_id;
	clif_traderequest(target_sd, sd->status.name);
	return ;
	} 

3.- Then download the npc file and add it.

*Remember to compile after edit trade.c

 

 

ScreenShots:

http://prntscr.com/8aujig

tradesecure.txt

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   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.



×
×
  • Create New...

Important Information

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