[Home] [Downloads] [Search] [Help/forum]

Gammon Software Solutions forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  Programming
. -> [Folder]  General
. . -> [Subject]  Working on adding perm affects for objects in olc

Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?
(New message)
Subject: Working on adding perm affects for objects in olc
Name:
Your forum user name.
Register forum user name
Password:
Your forum password.
Forgotten password?
Message:
Message to be posted (in English, please)
Maximum of 6000 characters. Text only please, no HTML.
Forum codes:
Check this if your message uses 'forum codes' or templates (auto-detected for new posts).
Forum codes Templates

Save this message ...


Subject review (reverse sequence)

Posted by Trom   (77 posts)  [Biography] bio
Date Mon 01 Nov 2004 01:24 AM (UTC)  quote  ]
Message
I figured it out after many hours of working on it. Basically put out the plan in point form and coded it and it works quite well so far. Using only a few of the properties of an affect and specifying a different type of affect it was possible to set a special set of rules for perm spells. My codebase can now use permanant spells of infinite duration or a set amount of ticks (should be infinite but the option is open). Thanks for any and all help.
[Go to top] top

Posted by Trom   (77 posts)  [Biography] bio
Date Sat 30 Oct 2004 09:00 PM (UTC)  quote  ]

Amended on Sat 30 Oct 2004 09:01 PM (UTC) by Trom

Message
so far i've figured out a way for it to cast the spell when the item is worn (so the actual spell is placed on the char as if it was cast by themselves). The next 2 problems i'm trying to over come is figuring out how to remove the spell which came from the item, for when they remove the item, (probably the -1 duration) and figuring out a way to save it in olc_save.c (which shouldn't be hard. Btw i'm doing this in my own codebase which came from rom/rot, its a multiclass mud so its a little different but similar to rom/rot still.
[Go to top] top

Posted by Meerclar   USA  (554 posts)  [Biography] bio
Date Sat 30 Oct 2004 06:01 PM (UTC)  quote  ]
Message
Typicly, spell effects on worn items will not be displayed to the character in an obvious way - no affects list, no wear messages, nothin. About the only ways to be sure to to either stat them before and after to be sure the affect is adding properly or live testing. There may also be issues with resetting flags properly when a char has camped and come back, it's been my experience that they'll need to rewear any gear with a permspell - mostly because the char construct wasn't designed to track perm effects from items.

Meerclar - Lord of Cats
Coder, Builder, and Tormenter of Mortals
Stormbringer: Rebirth
storm-bringer.org:4500
www.storm-bringer.org
[Go to top] top

Posted by Trom   (77 posts)  [Biography] bio
Date Sat 30 Oct 2004 02:32 PM (UTC)  quote  ]
Message
I've checked the perm snippet and tried figuring it out in olc. I've also made a new 'paf->where' value called 'TO_D_AFFECTS', when the object is equipped if it comes across an affect with that type of where, it gets the spell number from 'paf->type' and casts the spell. Now theoritically i think it should work well and its coded.
When i load the object right after adding the affect, then wear the object it doesn't do anything.. Any ideas on how to add perm affects in olc to objects?
[Go to top] 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.


2,602 views.

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

[Home]

Written by Nick Gammon - 5K

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( http://www.gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Internet Contents Rating Association (ICRA) - 2K]    [Web site powered by FutureQuest.Net]