Skip to content

How to remove Fog of war on a Map when Modding?

AvaleanAvalean Member Posts: 7
So here is the basics.
1) I created a tile set of a village.

2) I want to make the area fully visible to players upon entry.

A ) SO, I placed a NPC at the start point that ask if they would like to buy a map of said village.
There is two possible answers,
Yes or No.

B ) If they select yes I wanted the entire tile set to be seen on their map when it opens in the game map section. In short so the entire village is exposed.

C ) If answer is no then game on with maps "Fog of war" as usual.

CURRENT STATUS:
SO; I highlight the Yes response and select "Actions taken" Tab
I then place in the following script.

void main()
{
object oPC = GetPCSpeaker();
object oArea = GetObjectByTag(Dunduree);
ExploreAreaForPlayer(oArea, oPC);
}


I get the Object Tag from going to properties on the tile set and looking for its TAG. Which in this case is Dunduree.

After Mod is saved, I then start game as normal.

All runs fine, NPC is on site, NPC ask question when clicked on, I respond with Yes and POOF no map revealed still "fog of war", so what am I missing here???

Any assistance would be welcomed.
I also have a Discord and SKYPE servers for screen share and voice if of any assistance.

GMT Currently +2 "Germany" but my Deutsch really blows sorry.

Comments

  • BehindflayerBehindflayer Member Posts: 36
    Have you tried:

    object oArea = GetArea(OBJECT_SELF) ;
  • PhantomizerPhantomizer Member Posts: 76
    edited April 2018
    Try this, It'll go on the ActionsTaken of the conversation node. Basically It'll reveal the CURRENT AREA to the PC, you can basically reuse It as much as you want.

    void main()
    {
    object oPC = GetPCSpeaker();
    ExploreAreaForPlayer(GetArea(oPC), oPC);
    }

    The problem you might be running Into, which someone who knows more can confirm or correct me If I'm wrong, Is that I don't think the function that you want to use works with an area tag.
  • ProlericProleric Member Posts: 1,269
    edited April 2018
    If is Dunduree is the tag of the area,

    object oArea = GetObjectByTag("Dunduree");
    is the correct syntax - what you had won't compile without the double quotes, because it refers to an undeclared variable Dunduree rather than a literal. Behindflayer / Phantomizer's solution is more elegant, though, as it works for any area.
  • AvaleanAvalean Member Posts: 7
    edited April 2018
    Thanks folks I will look into this sorry for the late reply as I have been in the hospital for almost a month now in critical / guarded condition and just got home this week. I am now listed as stable /Ambulatory but under observation, my wife has even taken 4 weeks off to be here with me as it is simply cheaper than a live in nurse.

    Seems some way or another I got a super infection into my blood system that effected all major organs and limbs, they still do not know what the bacteria is and took them almost two weeks to figure out a drug combination to combat it. as such why I have not been responding.

    I am now back, not at 100% working order but getting there and ready to get back to working on the module. I hope in a few months to have it or make it available for all to play.

    SO, here is the thing I understand about 25% of what you are talking about as I am NOT a coder 8-)
    SO if anyone wishes to help educate an old fuddy duddy, you can always grab me if I am online in my groups teamspeak3 server located here:
    originaldu.mainvoice.info:8048

    Look for sarath or avalean, then perhaps we can use screen share via SKYPE or discord and you can help walk me through it once so I am sure of what exactly is going on.

    OR if the servr is passworded as happens due to trolls time to time, you can reach me via my skype.
    BaronGalwin
    email: originadu@yahoo.com

    And I can get you the password of the week.
    Right now it is not PW protected.

    thanks again.
    Avalean
    AKA StarCitizen
    Sarath
  • OndaderthadOndaderthad Member Posts: 9
    here is the script I use in a conversation:

    void main()
    {
    object oArea = GetArea(OBJECT_SELF);

    // explore the area for the player so that their map shows everything

    ExploreAreaForPlayer(oArea, GetPCSpeaker());

    string sAreaName = GetName(oArea);

    AssignCommand(OBJECT_SELF, SpeakString("Let me see your map of " + sAreaName + ", there is a place over here..."));
    }

Sign In or Register to comment.