This potion when imbibed will fill you with a new found energy one would generally associate with a full night's rest.
This script like most of my submissions is a rather simple tag based on activate addition that comes in two parts; the first part is the script and the second the item which can be found under the Custom Items tab in the Plot section.
Feel free to change the standard price, description at your will since this was designed with my own server in mind.
Oh I'm redoing the entire item and script, and still trying to launch my server at the same time so it's on the back burner for a bit. Making multiple different types of the potion with a level restriction to prevent higher level players from abusing what, in my server, is intended for low level castors and Alchemists. _________________________ "Eloquence dear freind, Eloquence in simplicity."
-Arken Deadroth
"have been working" -- did you encounter a problem? It should be fairly quick to copy the three lines into your script, then verify that it does not change the behavior in your test module.
The reason I don't want to change the submissions I already have out is mostly because I know the ones I have out work, I have taken your advice and have been working to attempt to get it to work in the way you demonstrated. I just don't want to remove the scripts that I know work for ones I'm not yet sure of. Once I'm satisfied with the new ones though I'll just put them into another submission so people can choose. And yes I know I can't spell... Dyslexia's a bitch.. _________________________ "Eloquence dear freind, Eloquence in simplicity."
-Arken Deadroth
OK, I might have been jumping to conclusions. Let me backtrack and ask a few questions instead. (Some of these might sound pointed, but that is not the intent. The written word is not always the best way to convey intent.) Maybe the answers will show me where I jumped off course.
Why is it important that this entry be *only* what you have been able to accomplish?
Why are you opposed to expanding your scripting knowledge beyond what was learned by copying scripts from the script generator?
What is your goal in sharing this? (Apparently not to show off what you have been able to accomplish on your own?) Just to be able to say you shared? To help some people, but only those who will do things the way you have been doing them? Why do you not want to do less work and broaden your target audience?
Or if you prefer, we can cut straight to end result: Is there any point in constructive criticism here? Would it be better to just post a review (and rating) as guidance for others who take a look at this?
PS Not to start a tangent, but this caught my eye while I was typing: you may want to consider that Arken Deadroth might have been talking about eloquence, rather than elloquence. ;)
I think you took what I meant the wrong way, I'm not here to brag either, what I've submitted is usable to some and if not oh well at least I shared what I was able to accomplish with the very little scripting knowledge that I have. _________________________ "Eloquence dear freind, Eloquence in simplicity."
-Arken Deadroth
Sorry, I thought you were trying to contribute something that others could use, not simply bragging about what you had been able to accomplish in your own module. I won't bother trying to help you improve it then.
If other people wan't to use that line then they are certianly free to do so, I on the other hand have no problems with the scripts that I use, and have never actually encountered any errors caused by doing things the way I have been. _________________________ "Eloquence dear freind, Eloquence in simplicity."
-Arken Deadroth
Wait a minute.... you decided to add more scripts (ones that could break other tag-based items) instead of adding three lines to your script? Why do more work to get less compatible results?
(The three lines should not be breaking the script even in your module; if the event number is not set in the module event, it defaults to activation.)
In case you haven't seen them, the first line to add to the activation script would be
#include "x2_inc_switches"
somewhere near the top, before any functions. The other two lines would go at the beginning of the main() function (with indentation that gets lost in these comments):
if ( GetUserDefinedItemEventNumber() != X2_ITEM_EVENT_ACTIVATE )
return;
Really, just add these three lines, and the problem is fixed without messing with module events and causing your item to be incompatible with tag-based items that use on the acquire and unacquire events.
Lastly, for all my upcoming scripts there will be example Module events supplied inside the .erfs to help prevent such issues from arising in the future. _________________________ "Eloquence dear freind, Eloquence in simplicity."
-Arken Deadroth
Once again sorry for the confusion, I had forgotten that the standard Module events included a tag based OnAcquire that I don't use in my own modules. _________________________ "Eloquence dear freind, Eloquence in simplicity."
-Arken Deadroth
Yeah sorry about that, as for the acquire and unaquire scripts it's a simple matter of modifying the modules onAC and onUNac to the script that I will be adding to the description, as for the item; It should be in the custom Item palette in the plot folder, it's called Potion: Vial of Midnight. _________________________ "Eloquence dear freind, Eloquence in simplicity."
-Arken Deadroth
The script is bugged in that it does not check for which tag-based event was fired. This means that acquiring and unacquiring the item can result in someone being rested, as can casting a spell on the item. Who gets rested in these cases would be the last character to activate an item, so it might not even be the character with the potion. (Do all of your "rather simple tag based on activate" scripts have this flaw?)
How to see this bug in action: make one of these items and a (standard) Stone of Recall available to your PC. Pick up and activate the Stone of Recall. After doing that, pick up the potion -- rested. Cast a spell on the potion -- rested again. Put the potion back down -- rested again (and the potion can still be unidentified at this point). Just one of these items can give an unlimited ability to rest in areas flagged to prevent resting. The only limitation on this is in multiplayer, where a different player can claim the benefits by activating an item before you trigger the tag-based script.
Your script needs to #include "x2_inc_switches" and make sure that GetUserDefinedItemEventNumber() returns X2_ITEM_EVENT_ACTIVATE before resting the activator.
jdeavila: It's called "Potion: Vial of Midnight" located under "Plot Item" for some reason.
Ok. I imported the erf...but I can only find the script. did you or did you not also make an item too. I can't find a potion of rest in the pallette. If you did where would I find it? _________________________ Imtherealthing