Gammon Forum
Entire forum
SMAUG
SMAUG coding
object to grant skills upon wearing/remove skill when removed?
object to grant skills upon wearing/remove skill when removed?
|
It is now over 60 days since the last post. This thread is closed.
  Refresh page
Posted by
| Alyce
(43 posts) bio
|
Date
| Tue 30 Aug 2016 04:31 AM (UTC) |
Message
| I was wondering if it were possible for an object to grant a skill while it is equipped, yet when you un-equip you no longer have that skill...
example:
I have gauntlets of fire.. when I have the gauntlets equipped I can cast fireball... when i remove them I no longer can cast fireball.
using Smaugfuss | top |
|
Posted by
| Nick Gammon
Australia (22,973 posts) bio
Forum Administrator |
Date
| Reply #1 on Tue 30 Aug 2016 08:44 PM (UTC) |
Message
| Anything's possible. I haven't looked at the SmaugFUSS code for a while, but you would need to have some sort of check, when casting, are the appropriate items equipped. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
Posted by
| Alyce
(43 posts) bio
|
Date
| Reply #2 on Wed 31 Aug 2016 01:31 AM (UTC) |
Message
| Thank you nick!
I was hoping to be able to set it once in the code and do it via mob progs... however hard code may be the better option..
I guess I could take a look at backstab (since it calls for a piercing weapon to be equipped) and perhaps set an itemvalue to represent the spell.
That bit should give me a good reference point on how to set it up.
I'm still trying to figure out how to make the slist (prac list) show ONLY learned skills, not those able to learn. lol | top |
|
Posted by
| Alyce
(43 posts) bio
|
Date
| Reply #3 on Wed 31 Aug 2016 06:27 AM (UTC) |
Message
| OK I got this to work!!!
I just copied mp_practice and made mp_unpractice... I just changed the values so that the unpractice will set it to 0...
now when i put it on object progs (wear or remove) I can adjust the skill accordingly... YAY
Now I can have Gauntlets of Fire that grant you the ability to cast Fireball while you wear them, but not have the ability to cast fireball if you don't!
Just incase anyone was wondering how to accomplish this!!
I feel so good and accomplished!!! teehee | top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
11,253 views.
It is now over 60 days since the last post. This thread is closed.
  Refresh page
top
Quick links:
MUSHclient.
MUSHclient help.
Forum shortcuts.
Posting templates.
Lua modules.
Lua documentation.
Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.