Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Colored Item Names
Author Message
JohnVeritas
Apprentice
*

Posts: 49
Likes Given: 0
Likes Received: 4 in 4 posts
Joined: Feb 2014
Reputation: 2



Post: #11
RE: Colored Item Names
Seems like magicals, give morey to items ( as usual way +3 got 200 morey +6 400 etc. ) under click trigger

if (<morey> > 100) && (<color> != <purple>)
color <purple>
elseif (<morey> > 200) && (<color> != <blue>)
color <blue>
...
.
..

I think you get what i want to explain Wink also you can give tags items and check that tags like morey. But if you give morey; weapons damage, armors armor value will be upgrade.
03-02-2014 03:47 AM
Find all posts by this user Like Post Quote this message in a reply
Osirirs
Journeyman
*

Posts: 73
Likes Given: 6
Likes Received: 4 in 2 posts
Joined: Feb 2014
Reputation: 2



Post: #12
RE: Colored Item Names
Thanks guys!

XuN
I'm getting a bit lost in the event thing, adding a tag to an event related to all players would change the rarity on the items?

John
I could do it like that too yeah, so I'd just have to add the Morey under the type and stuff?

Sorry guys I sound like the Total newb xD
its just I'm trying to make the link between this and the items. I get lost when it gets to Tags and events :/
03-02-2014 04:11 AM
Find all posts by this user Like Post Quote this message in a reply
JohnVeritas
Apprentice
*

Posts: 49
Likes Given: 0
Likes Received: 4 in 4 posts
Joined: Feb 2014
Reputation: 2



Post: #13
RE: Colored Item Names
If item is custom ( scripted by you ), you can set morey value under crate trigger;

on=@create
morey 200
..
..
..

otherwise ( default magicals or artifact items ) you have to edit values. Also type isnt matter it could be t_armor, t_weapon_sword, t_weapon_fence just define that types as like i defined.
03-02-2014 05:32 AM
Find all posts by this user Like Post Quote this message in a reply
Osirirs
Journeyman
*

Posts: 73
Likes Given: 6
Likes Received: 4 in 2 posts
Joined: Feb 2014
Reputation: 2



Post: #14
RE: Colored Item Names
Okay but wouldn't that set the item color?? o.O instead of the item name?
03-02-2014 06:30 AM
Find all posts by this user Like Post Quote this message in a reply
JohnVeritas
Apprentice
*

Posts: 49
Likes Given: 0
Likes Received: 4 in 4 posts
Joined: Feb 2014
Reputation: 2



Post: #15
RE: Colored Item Names
You can use click trigger for multiple events. If item got color that u want nothing changes otherwise it will change color. One way or another clicking will show item name as colored. Like;

on=@click
if (<more> > 100)
color 07a1
elseif (<more> > 300)
color 080a
endif

message @07a1,,1 <name>
return 1
(This post was last modified: 03-02-2014 09:46 AM by JohnVeritas.)
03-02-2014 09:45 AM
Find all posts by this user Like Post Quote this message in a reply
Alaric
Journeyman
*

Posts: 227
Likes Given: 7
Likes Received: 9 in 4 posts
Joined: Oct 2012
Reputation: 7



Post: #16
RE: Colored Item Names
Checking is ugly, its better to use defs as xun suggested.
There are many ways to do coloured naming, it depends what exactely you want. But since this fires very often, it's better not to do lots of operations.
(This post was last modified: 03-02-2014 09:56 AM by Alaric.)
03-02-2014 09:54 AM
Find all posts by this user Like Post Quote this message in a reply
Osirirs
Journeyman
*

Posts: 73
Likes Given: 6
Likes Received: 4 in 2 posts
Joined: Feb 2014
Reputation: 2



Post: #17
RE: Colored Item Names
yes that's what I figured, tho I'm not sure how to use the defs with the tag.
And then I thought about it too and I don't think I can use John's way either cause I still write the weapon stats as a sysmessage
so even if I used a command to pre-set the item rarity with a color I'd still have to write the stats Shock
tho I'd very much like to set a rarity system, I started with what XuN suggested but not sure of what to do next :/
thanks a lot for your help guys! I appreciate it Smile
03-02-2014 12:52 PM
Find all posts by this user Like Post Quote this message in a reply
XuN
Sphere Developer
*****

Posts: 852
Likes Given: 102
Likes Received: 156 in 119 posts
Joined: Jul 2013
Reputation: 30



Post: #18
RE: Colored Item Names
About the tag... it was just an example, I don't know how are you going to store the rarity of the item, but I guessed you are going to use a tag, you can use what you want to and change the tag line with the identifier for the rarity.
03-02-2014 03:14 PM
Find all posts by this user Like Post Quote this message in a reply
Osirirs
Journeyman
*

Posts: 73
Likes Given: 6
Likes Received: 4 in 2 posts
Joined: Feb 2014
Reputation: 2



Post: #19
RE: Colored Item Names
Oh okay, well then I'll just keep writing everything as sysmessages until I know better xD
I'm learning really fast here so I guess it won't be too long until I can figure out how to use these tags Tongue
Thank you! Smile

by the way, if anyone knows a great tutorial about Tags which would help me understand how to use them it would be
very appreciated! Followed the one on spherewiki but damn the guy lost me :/
Thanks again ^^
03-03-2014 02:06 AM
Find all posts by this user Like Post Quote this message in a reply
XuN
Sphere Developer
*****

Posts: 852
Likes Given: 102
Likes Received: 156 in 119 posts
Joined: Jul 2013
Reputation: 30



Post: #20
RE: Colored Item Names
Code:
[Itemdef i_staff_dragonwrath]
id=i_staff_black
name=Dragonwrath, Tarecgosa's Rest
dam=xx
blabla
code
code
more code
tag.rarity=3 //Legendary

ON=@Create
more code
etc


[Events e_players]
ON=@ItemAfterClick
if (<act.tag0.rarity>)
local.clickmsghue=<def.color_rarity_<act.dtag.rarity>>
endif
03-03-2014 06:03 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 3 Guest(s)