PenUltima Online Forum Index Official Core: 096.7
Official Core: 097 2008-02-26
Donate towards the POL web hosting bill!
 POL Home   FAQ   Search    Memberlist   Usergroups    Register    Profile   Log in to check your private messages   Log in
Hue Command and Multi Hue Command

 
Post new topic   Reply to topic    PenUltima Online Forum Index -> Custom Script Releases
Display posts from previous:   

Author Message
runtest



Joined: 05 Aug 2006
Posts: 98

PostPosted: Thu Oct 04, 2007 9:12 am    Post subject: Hue Command and Multi Hue Command Reply with quote

Call it .color or whatever you would like. I made this simple hue command. It works nicely I think. Should be comp. with 95+.

Code:

use uo;

program textcmd_Hue(who, text)

   SendSysMessage( who, "What do you want to hue?" ,3,65 );
   
   var coloritem := text;
   coloritem := CInt( coloritem );
   var targ := Target( who );
   
   targ.color := coloritem;

   if ( !targ )
      SendSysMessage( who, "Cancelled.",3,65 );
      return 0;
   endif

   return 1;

Endprogram


Last edited by runtest on Thu Oct 04, 2007 3:24 pm; edited 2 times in total

Author Message
runtest



Joined: 05 Aug 2006
Posts: 98

PostPosted: Thu Oct 04, 2007 9:17 am    Post subject: Reply with quote

Oh I forgot to mention, just copy and paste that in a text editor and save it as
Code:

hue.src

Then drop it in the seer folder in textcmd located in pkg/commands. It will compile with the latest distro.

Note: Will hue mobiles too.

Author Message
Austin
POL Developer


Joined: 30 Jan 2006
Posts: 345
Location: San Diego, California

PostPosted: Thu Oct 04, 2007 9:58 am    Post subject: Re: Hue Command Reply with quote

097/distro/pkg/commands/props/setprop.src

.setprop color 1234


runtest wrote:
Call it .color or whatever you would like. I could not find a color command with the 97off. release so I made this simple hue command. It works nicely I think. Should be comp. with 95+.

Code:

use uo;
use os;

program textcmd_Hue(who, text)

   SendSysMessage( who, "What do you want to hue?" ,3,65 );
   
   var coloritem := text;
   coloritem := CInt( coloritem );
   var targ := Target( who );
   
   targ.color := coloritem;

   if ( !targ )
      SendSysMessage( who, "Cancelled.",3,65 );
      return 0;
   endif

   return 1;

Endprogram

Author Message
runtest



Joined: 05 Aug 2006
Posts: 98

PostPosted: Thu Oct 04, 2007 11:25 am    Post subject: Reply with quote

Yeah, but its not .hue. Razz Just thought it would be cool for me. Thought hey, why not, lets give it out to learn off, use, or whatever.

Author Message
runtest



Joined: 05 Aug 2006
Posts: 98

PostPosted: Thu Oct 04, 2007 3:12 pm    Post subject: Reply with quote

Here be a nice multi hue command me mattes.

Code:

use uo;

program textcmd_MHue(who, text)

   SendSysMessage( who, "What do you want to hue?" ,3,65 );
   
   var coloritem := text;
   coloritem := CInt( coloritem );
   
   while( who.connected )

   var targ := Target( who );

      if( targ )
         var result := targ.color := coloritem;
         SendSysMessage( who,"Target's color was changed to " + coloritem + ".",3,65 );
            if( !result )
               SendSysMessage( who,result.errortext );
            endif
         else
         break;
      endif
   endwhile

   SendSysMessage( who,"Cancelled.",3,65 );

   return 1;

Endprogram


Hint: Save this one as "mhue.src".

Post new topic   Reply to topic    PenUltima Online Forum Index -> Custom Script Releases All times are GMT - 4 Hours
Page 1 of 1

 




Powered by phpBB © 2001, 2005 phpBB Group :: Theme & Graphics by GHS & Scott E. Royalty