Jump to content

Script error question


hardarg

Recommended Posts

I've been having problem compiling a script I mashed up for my PRCSCR, I keep getting a parsing variable list error in Line 23. I don't really know what that means, tbh. :(

 

Line 23 is "object oElfMessenger = UT_GetNearestObjectByTag(oPC, sElfMessenger);"

I've never had problems using that one in similar scripts,

//string used for HumanMageOrigin
const string sMageINI = "bhm100ar_tower_level_1";
const string sLeandraLetter = "hg_htc_pc_mageini";
const resource rLeandraLetter = R"hg_htc_pc_mageini.utp";

//string used for all Origins
const string sElfINI = "pre100ar_kings_camp";
const string sElfMessenger = "hg_htc_cr_elfmessini";
const resource rElfMessenger = R"hg_htc_cr_elfmessini.utc";

#include "plt_hg_htc_pl_core" 
#include "wrappers_h"

void main()
{   
    object oMainControlled = GetMainControlled();
    
    //variables used for HumanMageOrigin
    object oLeandraLetter = UT_GetNearestObjectByTag(oPC, sLeandraLetter);
    object oMageINI = GetObjectByTag(sMageINI)
    
    //variables used for all origins
    object oElfMessenger = UT_GetNearestObjectByTag(oPC, sElfMessenger);
    object oElfINI = GetObjectByTag(sElfINI);
   
    if (WR_GetPlotFlag(PLT_HG_HTC_PL_CORE, HAWKES_INITIALIZED) == FALSE)
    {
        //Spawn Leandra Letter at Mage Quarters
        if (!IsObjectValid(oLeandraLetter))
        {
            location lSpawn = Location(oMageINI, Vector(33.238,-18.4668,0.431346), -205.2296);
            CreateObject(OBJECT_TYPE_PLACEABLE, rLeandraLetter, lSpawn);          
        }
        //Spawn Messenger at Ostagar
        else if (!IsObjectValid(oElfMessenger))
        {
            location lSpawn = Location(oElfINI, Vector(627.996,547.115,5.10486), 75.7);
            CreateObject(OBJECT_TYPE_PLACEABLE, rElfMessenger, lSpawn);          
        }
    }
}

I'm still learning my way around scripting, any help and guidance is greatly appreciated. :)

 

 

 

Link to comment
Share on other sites

You haven't defined oPC and instead used oMainControlled. So everything calling (oPC, whatever) needs to be changed to (oMainControlled, whatever) or oMainControlled needs to be changed to oPC.
Link to comment
Share on other sites

Thanks for the reply LadyHonor, I did not notice I had forgotten to define the oPC. :thumbsup:

 

EDIT:

Anyway, I changed it back, but I still get the parsing error. I tried using oMainControlled instead, but I still get the same result. :sad:

 

EDIT:

Finally found the problem, my line 20 didn't have a semi colon at the end. :facepalm:

Edited by hardarg
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...