Aller au contenu

Photo

Persistant Map Notes?


  • Veuillez vous connecter pour répondre
5 réponses à ce sujet

#1
archer4217

archer4217
  • Members
  • 105 messages
Hi all,

I hope you all had a nice Thanksgiving. :wizard:

So, here's my question. Is it possible for map notes to be persistant through restarts using only the regular nwn database? I'm not using any other databases because *sheepish* I just can't figure them out. :P

What I mean by persistant map notes, what I want is for players to be able to put a map note on their map once they find a place they want to mark which wouldn't get wiped out with restarts.

Thank you for any help. :happy:

#2
Lightfoot8

Lightfoot8
  • Members
  • 2 535 messages
http://nwn.wikia.com/wiki/Map_pin

#3
Baaleos

Baaleos
  • Members
  • 1 330 messages
NOTE - Ignore most of this post - the above post was more informative.

Im not too sure on the topic of player created map notes.
What I do know about generic mapnotes however, is that the map note is either
enabled, or disabled to all players.

If you are planning on making a system that allows players to place persistent map notes, then it is potentially do-able, but I suspect it would need the help of a nwnx plugin.


1. Create the mapnote template / resref in toolset.
2. Allow the players to spawn it at a location - store its location persistently.
3. NWNX would undoubtably be needed to change the map note text of the placed map note. I dont think nwnscript allows this by default.
4. In order to make it persistent, make the onModLoad event load all the Map Note data stored in the database, and spawn the notes at the relevant locations.


eg - Data needed to be stored.
1. Location
2. Text

How to link these?
Via the variable name, eg
PER_MAP_TEXT_#
PER_MAP_LOC_#

Where # is a number equating to the number of the map note spawned.


then, the onLoad event would iterate through all of these - but be warned, Bioware db operations are SLOW.

int iNum = 1;
location lLoc;
string sText = GetCampaignString("MAP_PINS","PER_MAP_TEXT_"+IntToString(iNum));
while(sText != "")
{
lLoc = GetCampaignLocation("MAP_PINS","PER_MAP_LOC_"+IntToString(iNum));
CreateObject() //This is the place where your map pins get created - eg - set the location to be lLoc, and then use nwnx or a plugin from nwnx if one exists, to change hte map pin text to sText
iNum++
sText = GetCampaignString("MAP_PINS","PER_MAP_TEXT_"+IntToString(iNum));
}

Modifié par Baaleos, 03 décembre 2010 - 11:13 .


#4
archer4217

archer4217
  • Members
  • 105 messages
Thank you, sweeties. :) *hugs*

Modifié par archer4217, 03 décembre 2010 - 11:13 .


#5
Tyndrel

Tyndrel
  • Members
  • 185 messages
There are two systems available on the NwVault that do this...

Persistent / Editable Player Map Pins  by Jassper

and

Persistent Map Notes  by C. A. Schops

:)

#6
archer4217

archer4217
  • Members
  • 105 messages
Thank you, sweetie :) *hug*