Jump to content

Dastgir

Script Developers
  • Content Count

    3803
  • Joined

  • Last visited

  • Days Won

    248

Posts posted by Dastgir


  1. Script.c

     

    Place This above "BUILDIN_FUNC(dispbottom)"

    /*========================================== * Coloured DispBottom [By Dastgir] *------------------------------------------*/BUILDIN_FUNC(dispbottom2){	TBL_PC *sd=script_rid2sd(st);	const char *message;	unsigned long color;	message=script_getstr(st,3);	color=strtoul(script_getstr(st,2),NULL,0);	if(sd)		clif_colormes_e(sd,color,message);	return 0;}

     

    In the Same file

    Place This below "BUILDIN_DEF(showevent, "ii"),":

     

     

    BUILDIN_DEF( dispbottom2, "ss"),	//[By Dastgir] 

    In Clif.C:

    Place this at end of file:

     

     

    // Modification of clif_messagecolor to send colored messages to players to chat log only (doesn't display overhead)// 02c1 <packet len>.W <id>.L <color>.L <message>.?B// [By Dastgir]int clif_colormes_e(struct map_session_data * sd,unsigned long color1, const char* msg) {	unsigned short msg_len = strlen(msg) + 1;	WFIFOHEAD(sd->fd,msg_len + 12);	WFIFOW(sd->fd,0) = 0x2C1;	WFIFOW(sd->fd,2) = msg_len + 12;	WFIFOL(sd->fd,4) = 0;	WFIFOL(sd->fd,8) = (color1&0x0000FF) << 16 | (color1&0x00FF00) | (color1&0xFF0000) >> 16; // RGB -> BGR	safestrncpy((char*)WFIFOP(sd->fd,12), msg, msg_len);	clif_send(WFIFOP(sd->fd,0), WFIFOW(sd->fd,2), &sd->bl, SELF);	return 0;} 

     

    In Clif.H

    Place this at the end:

     

     

     

    int clif_colormes_e(struct map_session_data * sd,unsigned long color1, const char* msg);	//[By Dastgir] 

     

    So the Format you will use

    dispbottom2("0x00FF00","MESSAGE");

    OR

    dispbottom2 "0x00FF00","MESSAGE";

    REPLACE 0x00FF00 to any colour code.


  2. prontera,141,168,5	shop	CustomShop948,501:50
     
    -	script	CustomShop	-1,{OnInit:npcshopdelitem "CustomShop",501;for (.i = 22000; .i <= 23030; .i = .i+1){	npcshopadditem "CustomShop",.i,rand(10000000,20000000);}end;}
     

    Why this have Infinity Loop Error?

×
×
  • Create New...

Important Information

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