Passport Revisited and HotU Local Variables Stored on items

Discuss any general matters related to CoPaP here!
Jordicus
World Leader: Avlis
Posts: 91
Joined: Thu Nov 20, 2003 3:13 pm
Location: Hackensack, NJ (GMT -5)
Contact:

Post by Jordicus » Thu Dec 18, 2003 10:48 am

in most cases, those items just pull the stored info out of a DB, they don't actually store the info themselves. but they probably could be used for the purpose being discussed here
"Wow. I can hear my brain." - The Tick

Nightbringer
Groundling
Posts: 94
Joined: Wed Nov 19, 2003 6:06 pm
Location: Crimson Stars
Contact:

Post by Nightbringer » Thu Dec 18, 2003 11:56 am

Pitched Black wrote:How often do you replace hides and how long would it take to get (a quick guess) 10 variables before you replace it and then store that same 10 again. For the price of that bit of extra script when you replace hides, this would be a very nice feature to have up and running.
The problem is not really how often it happens... once or ten times requires the same script to do it. The problem is how integrated, complex, and esoteric is the script being used to do either function. Its one thing to have a completely stand along functionality that a world has to use, but to have to integrate one functionality with another could be quite a problem, particularly if the script was not created by that world (like I imagine many subrace scripts would be given the existance of community made ones).

It can be a bit of a pain, but I've got no real problem modding scripts and figuring out what they do. However, I imagine I'm in the minority with that. I can also think of a few times I have used the creature hide for extra random effects, and I can imagine someone having one of those in a mod, not coming up too often, but then completely hosing the system when it does.
[url=http://www.crimsonstars.com]Crimson Stars: Spelljammer Persistant world[/url]
[url=http://nwvault.ign.com/Files/hakpacks/data/1060320751937.shtml]Arcane Space Tileset / Turn Based Spelljammer[/url]
Spelljammer in NWN, ship to ship combat, space piracy, and more!

hermyt
World Leader - LoT: Moonsea
Posts: 65
Joined: Fri Nov 21, 2003 9:41 pm
Contact:

hmm glad someone actually read that post instead

Post by hermyt » Thu Dec 18, 2003 2:34 pm

thanks Nightbringer for actually reading through that script I tried to mention or orl before that there is still a function to access the diety string but I guess he didn't really catch what I was saying. The system seems pretty good, it uses the export characters function which seems to be pretty fast accessing for bioware functions, you can export an entire server full of character data without making much of a blip on the radar as far and hd access. If the setdiety database was only used for things that were necessary for cross server data, like the tradeskills info then it wouldn't get unwieldly huge and as mentioned THERE IS STILL A FUNCTION TO ACCESS DIETY INFORMATION. Just incase someone still wasn't aware of that.

And I'm all for one tradeskills system myself as well as far as such things go, no one has really mentioned what they want to do with biowares built in, but I figure leaving it on or off can be pretty much server specific, as far as serious tradeskills I'd be all for supporting the avlis one, its better than any others that I've really mucked about with.

HerMyT

Daerthe
Ambassador: Ea
Posts: 41
Joined: Fri Nov 21, 2003 2:56 pm
Location: Ea: Legend of Valinor
Contact:

Post by Daerthe » Thu Dec 18, 2003 3:38 pm

Jordicus wrote:in most cases, those items just pull the stored info out of a DB, they don't actually store the info themselves. but they probably could be used for the purpose being discussed here
It just seemed a logical place to me. If the tradeskills is the primary bit of information we want to be passed, then the crafting journal makes sense as the item to store the information. The majority of PCs I have seen craft anyway. If you make it a default starting item in a PCs inventory, every PC will have one and the other information can be stored in it as well. If you rename the object to just be "Journal" storing various types of information about a specific PC in it also makes IC sense.

Pitched Black
World Leader: Hala
Posts: 76
Joined: Mon Nov 24, 2003 5:59 pm

Post by Pitched Black » Mon Dec 22, 2003 6:57 pm

The problem with the book is that it can be dropped by the PC. This isn't a bad thing as we should only need to record and strip the data during the link but it would require that everyone record and send this data during the link. If someone doesn't want to participate in this, and the player drops this book on that server, their tradeskills for every server would reset to what they were the last time they were on the next server they go to. If something wasn't droppable (like a hide), then the data would stay there and the server who doesn't want to write that data again wouldn't have to.

What about the claws instead of the hide? Does anyone use those too?

For the script, It'll have to be something like this:

Code: Select all

#include "ars_include" (might need to add a SetXP function, or just make a new include with only it)

void Main()
{
object oPC = OBJECT_SELF;
object oHide = GetItemInSlot(nCurrent);

int nAlchemy = GetLocalInt(oHide, "ars_alchemy");
if (nAlchemy > 0) ARS_SetXP(oPC, "alchemy's db name", nAlchemy);

(rest of the tradeskills...)
}

The exact reverse for the writing script: 
int nAlchemy = ARS_GetXP(oPC, "alchemy's db name");
if (nAlchemy > 0) SetLocalInt(oHide, "ars_alchemy", nAlchemy);

Pitched Black
World Leader: Hala
Posts: 76
Joined: Mon Nov 24, 2003 5:59 pm

Post by Pitched Black » Mon Dec 22, 2003 8:41 pm

Now that I actually got to thinking about this script...

Code: Select all

filename: copap_include

#include "ars_include"

void copap_updatedb(object oPC = OBJECT_SELF, object oHide = GetItemInSlot(INVENTORY_SLOT_CHEST), int nChangingHides = 0)
{
int nCurrent = 1;
int nTotal = ARS_GetSkillCount();

while (nValue <= nTotal)
 {
 string sSkill = ARS_GetSkillName(nCurrent);
 int nXP = ARS_GetPlayerXP(oPC, sSkill);
 int nNewXP = GetLocalInt(oHide, IntToString(nCurrent)); 

 if ((nNewXP != -1) && (nNewXP > nXP) && (nChangingHides = 0) ARS_GiveXP(oPC, sSkill, (nNewXP-nXP);
 if (nChangingHides == 1) SetLocalInt(oPC, IntToString(nCurrent), nNewXP);

 nCurrent++;
 }
}


copap_updatehide(object oPC = OBJECT_SELF, object oHide = GetItemInSlot(INVENTORY_SLOT_CHEST), int nChangingHides = 0)
{
int nCurrent = 1;
int nTotal = ARS_GetSkillCount();

while (nValue <= nTotal)
 {
 string sSkill = ARS_GetSkillName(nCurrent);
 int nValue;

 if (nChangingHides == 0) nValue = ARS_GetPlayerXP(oPC, sSkill);
 if (nChangingHides == 1) nValue = GetLocalInt(oPC, IntToString(nCurrent);

 if ((nValue == 0) SetLocalInt(oHide, IntToString(nCurrent), -1);
 else SetLocalInt(oHide, IntToString(nCurrent), nValue);

 nCurrent++;
 }
}



copap_updateplayer(oPC = OBJECT_SELF)
{
object oHide = GetItemInSlot(INVENTORY_SLOT_CHEST);

if (oHide != OBJECT_INVALID) copap_updatehide(oPC, oHide);

if (oHide == OBJECT_INVALID)
 {
 object oNewHide = CreateItemOnObject("generichide", oPC);
 AssignCommand(oPC, ActionEquipItem(oNewHide, INVENTORY_SLOT_CHEST));
 copap_updatehide(oPC, oNewHide);
 }
}
This include script has two functions, copap_updatedb() and copap_updateplayer(). These two functions should be caled whenever a player enters into or comes through a portal (or just enter/exit the server).

Code: Select all

Changing hides

include "copap_include"

void main()
{
object oPC = OBJECT_SELF;
object oHide = GetItemInSlot(INVENTORY_SLOT_CHEST);
copap_updatedb(oPC, oHide, 1);

// Paste or use ExecuteScript() here to change the hide.

object oHide = GetItemInSlot(INVENTORY_SLOT_CHEST);
copap_updatehide(oPC, oHide, 1);
Using this as a template for changing hides, you don't even need to be connected to a db and all the variables should *cough* copy over nicely.


btw, sorry about the formatting...
Last edited by Pitched Black on Mon Dec 22, 2003 11:12 pm, edited 1 time in total.

Orleron
Multiverse Scholar
Posts: 1247
Joined: Mon Nov 10, 2003 11:15 am
Location: Avlis
Contact:

Post by Orleron » Mon Dec 22, 2003 9:01 pm

I wouldn't use claws either, because some of the more beastly races will have them as PC's.
Avlis: http://www.avlis.org

"My name is Orleron...a dungeonmaster...two years ago I got shot through a game client...I'm in a distant part of the internet aboard these servers of escaped mental patients...my players. I've made enemies, stupid, and annoying...now all I want to do is make CoPaP a reality, to warn Earth...Look inward(to your monitor) and share the newbies I've seen..."

Red Golem
World Leader: Abyss404
Posts: 109
Joined: Fri Nov 21, 2003 8:19 pm
Location: Honolulu, Hawaii (GMT-10)
Contact:

Post by Red Golem » Tue Dec 23, 2003 1:13 am

With the cursed plot undroppable items in HotU, you can't drop them as far as I know. You can't sell/trade them or put them in an inventory bag or in a placeable container.

There's no getting rid of them except for scripted means. So one of those small miscellaneous items would probably do. No need to mess around with creature items. These items can even be usable (unlimited use) perhaps for displaying some of the data stored in it.
[url=http://nwn.bioware.com/guilds_registry/viewguild.html?gid=6231]Autobic Guild[/url]

Pitched Black
World Leader: Hala
Posts: 76
Joined: Mon Nov 24, 2003 5:59 pm

Post by Pitched Black » Tue Dec 23, 2003 11:37 pm

Remove the nChangingHides option and functionality then set oHide to your book and (assuming they'd work in the first place), you still have your scripts ready.

Daerthe
Ambassador: Ea
Posts: 41
Joined: Fri Nov 21, 2003 2:56 pm
Location: Ea: Legend of Valinor
Contact:

Post by Daerthe » Wed Dec 24, 2003 3:15 pm

Red Golem wrote:With the cursed plot undroppable items in HotU, you can't drop them as far as I know. You can't sell/trade them or put them in an inventory bag or in a placeable container.

There's no getting rid of them except for scripted means. So one of those small miscellaneous items would probably do. No need to mess around with creature items. These items can even be usable (unlimited use) perhaps for displaying some of the data stored in it.
If there was a small miscellaneous item that looked like a notebook, it could be considered the physical presence of the PC's journal and/or a place to store their private papers (deeds to property, citizenship papers, passport, etc.) It would seem the perfect IC reason a PC would not want to drop the item. Forcing PCs to carry an item will be more acceptable in general if you create an IC reason why they should have it.

Red Golem
World Leader: Abyss404
Posts: 109
Joined: Fri Nov 21, 2003 8:19 pm
Location: Honolulu, Hawaii (GMT-10)
Contact:

Post by Red Golem » Wed Dec 24, 2003 4:01 pm

Yeah that makes sense. We'd just need to cook up a story for low intelligence characters and pure barbarian characters who can't read.

Or even a more abstract item called "Memories" or "Mind". Activating it could display some of the variables. If it was ever somehow lost - then some dire consequences could take place for losing your "Memories" or losing your "Mind". Everyone has memories or a mind, so there would be no need to even make a special explanation for it.
[url=http://nwn.bioware.com/guilds_registry/viewguild.html?gid=6231]Autobic Guild[/url]

lafferty
Planewalker
Posts: 31
Joined: Mon Nov 24, 2003 9:30 pm
Location: look at my hands... they are HUGE. And they cant touch themselves... (AVLIS)
Contact:

Post by lafferty » Wed Dec 24, 2003 9:24 pm

sounds nice... but please do use a small item (1x1) and not a 2x2 item.

Maybe the item could also hold the stuff the emote wand does too?

*hopes for it to weigh less than 1.0 lbs.*

If Copap needs a custom icon for it just tell me ;)
[url=http://zope.lafferty.de]Crafter's helper[/url]

Orleron
Multiverse Scholar
Posts: 1247
Joined: Mon Nov 10, 2003 11:15 am
Location: Avlis
Contact:

Post by Orleron » Thu Dec 25, 2003 12:02 am

Why does the item have to stay with them all the time? Why can't we just create a temporary item for during the server transfer and then delete it once the transfer is done and all the variables have been transfered?
Avlis: http://www.avlis.org

"My name is Orleron...a dungeonmaster...two years ago I got shot through a game client...I'm in a distant part of the internet aboard these servers of escaped mental patients...my players. I've made enemies, stupid, and annoying...now all I want to do is make CoPaP a reality, to warn Earth...Look inward(to your monitor) and share the newbies I've seen..."

Pitched Black
World Leader: Hala
Posts: 76
Joined: Mon Nov 24, 2003 5:59 pm

Post by Pitched Black » Thu Dec 25, 2003 12:36 am

For the pathfinding issue. If one server doesn't correctly/completely transfer the variables, they're not lost. This also means that a few servers can have a specific variable set up for a cross-server quest and they wouldn't have to make every other server transfer that variable for them.

Daerthe
Ambassador: Ea
Posts: 41
Joined: Fri Nov 21, 2003 2:56 pm
Location: Ea: Legend of Valinor
Contact:

Post by Daerthe » Thu Dec 25, 2003 2:22 pm

Good reasons PB, was also thinking (like Laff) that it can serve multiple functions. It could remove the need for PCs to carry around multiple items, like the tradeskills journal and an emote wand. Heh, hadn't thought of the emote wand, but that is a good idea too. The wand is not an IC item, but has weight and takes space in your pack.

Darien
Noobie
Posts: 1
Joined: Sat Apr 17, 2004 9:42 pm

Post by Darien » Sat Apr 17, 2004 11:35 pm

I think that moving all CoPaP worlds to one tradeskills system would be nice, both for players and for admins. This could be a new, neat way to make spiffy items: make recipies that require ingredients from multiple servers.

Oh, and for IC reasons too: Hey, I just walked over this magical line in the ground, and now I have to make things in a completely new way! Woo-hoo!

lafferty
Planewalker
Posts: 31
Joined: Mon Nov 24, 2003 9:30 pm
Location: look at my hands... they are HUGE. And they cant touch themselves... (AVLIS)
Contact:

Post by lafferty » Sun Apr 18, 2004 8:32 am

Wouldnt it also be possible to utilize the nwvaultster?

As i understand it the problem we have is to transfer data stored on players in the db of a world to another world. We could do this with the variables in items, with some sort of external tool/protocol that sends the data directly to the db, a centralized copap db with some sort of protocol interface (xml-rpc? soap?...) that is set up only for the purpose of storing such data and making logs of character movements around the worlds.
Another possibility would be to place simple text file in the server vault along with the character file that gets transfered. When logging in into a world nwxn just checks if this file exists, parses it and deletes it afterwards. the drawback at that is we'd need some sort of extension to nwnx. but that way we would not need to pack even more data ingame we originally wanted to hold external in the dbs.
I think in the long run some sort of replication/clustering amongst the dbs would be highly useful...

just some random thoughts
[url=http://zope.lafferty.de]Crafter's helper[/url]

Orleron
Multiverse Scholar
Posts: 1247
Joined: Mon Nov 10, 2003 11:15 am
Location: Avlis
Contact:

Post by Orleron » Sun Apr 18, 2004 11:13 am

Yes, we could have a centralized DB, but it might present some security concerns. It's much easier to just store the variables on an item. We're already thinking of giving all PC's some kind of hide or another, for other reasons besides this, so it might be a way to go by using hides.
Avlis: http://www.avlis.org

"My name is Orleron...a dungeonmaster...two years ago I got shot through a game client...I'm in a distant part of the internet aboard these servers of escaped mental patients...my players. I've made enemies, stupid, and annoying...now all I want to do is make CoPaP a reality, to warn Earth...Look inward(to your monitor) and share the newbies I've seen..."

duncantiv
Noobie
Posts: 1
Joined: Sat May 08, 2004 4:19 pm
Location: Los Angeles, CA

Post by duncantiv » Mon May 10, 2004 7:16 am

Hmm, well, this seemed to a good place to post this, as the concept has already been mentioned.

I was asking about this on the Travellers boards, and Themicles suggested I bring it up here. What are the general opinions of using the radial Craft option for emotes? I've tried this on another server I was poking around in recently, and I honestly liked the feel much better. At the very least, my character didn't go into the overly dramatic item-using pose when all I want to do is sit down or kneel to pray or whatever. As has been mentioned in the Avlis boards, this would also free up a small amount of weight for characters weak enough to be concerned with every 0.5 pounds of gear.

Anybody know if such a change would require 2da changes, or what would need to be done to enable such a possibility?

Post Reply