Skip to content

Script error

Hello everyone. I have problem compiling this file and give me ERROR: NO FUNCTION STARTINGCONDITIONAL() IN SCRIPT


I was sure it worked years ago but now seems Is missed the function. Someone could help me?

thanks

#include "x2_inc_itemprop"
#include "x0_i0_position"



// =======INCLUDE costanti di uso generale ==========================================


const int ISA_DEBUG_OFF=TRUE;

const string IsaModuleFileName="Mod";

const string IsaCampaignName="Mod";
// tag anello della liberta'
const string IsaFreedomRingTag="IsaFreedomRing";
// slot inventario non valido
const int ISA_INVENTORY_SLOT_INVALID=-1;

const string IsaLocationVarPrefix="ISA_LOC_SYSTEM_";
const string IsaLocationVarPostfixAreaTag="_AREA_TAG";
const string IsaLocationVarPostfixAreaName="_AREA_NAME";
const string IsaLocationVarPostfixFace="_FACE";
const string IsaLocationVarPostfixPosition="_POSITION";

// ======= gestione calendario ===============================================

// costante inverno: 0
const int IsaCalendar_Errore=0;
// costante inverno: 1
const int IsaCalendar_Inverno=1;
// costante primavera: 2
const int IsaCalendar_Primavera=2;
// costante estate: 3
const int IsaCalendar_Estate=3;
// costante autunno: 4
const int IsaCalendar_Autunno=4;

// ======= gestione dicebag di isabella ======================================

// tipo di attacco: mischia
const int IsaDiceCheck_AttackMelee=1;
// tipo di attacco: distanza
const int IsaDiceCheck_AttackRanged=2;

// ======= funzioni di gestione login ========================================

// massimo numero di ingressi per pg
const int IsaLoginCnt_MaxEntering=10;
// massimo numero di ingressi lamerosi tollerati
const int IsaLoginCnt_MaxLamerEntering=5;

// ======= gestione sottorazze ===============================================

// sottorazza asimaar
const string IsaSubRace_Aasimar="Aasimar";
// sottorazza drow
const string IsaSubRace_Drow="Drow";
// sottorazza elfo dei boschi
const string IsaSubRace_ElfoBoschi="Elfo dei Boschi";
// sottorazza mezzo demone
const string IsaSubRace_Demone="Mezzo Demone";
// sottorazza tauro
const string IsaSubRace_Tauro="Taurus";
// sottorazza uomo del nord
const string IsaSubRace_UomoNord="Uomo del Nord";
// sottorazza vampiro
const string IsaSubRace_Vampiro="Vampiro";






Comments

  • KamirynKamiryn Member Posts: 74
    edited April 2021
    There's either a
    void main()
    {}
    
    or a
    int StartingConditional()
    {
    	return ...
    }
    

    missing. That's why you get the ERROR: NO FUNCTION STARTINGCONDITIONAL() message.

    Without it's just an include file, a file you can include into other scripts with #include "...".
  • ProlericProleric Member Posts: 1,281
    It looks like the script is indeed an include file. It will not compile (though attempting to compile it does not harm). Include it in other scripts, then compile them instead.
  • Talon79Talon79 Member Posts: 10
    thanks! i try so!
  • Talon79Talon79 Member Posts: 10
    I have another problem. The module is a pre 1.69 so i have the skin system to giving player some bonus. I saw that from 1.69 there is a problem with this kind of custom script. I saw that skins don't equipanymore to player but just stay in inventory.

    void main()
    {
    object oPC=GetPCSpeaker();
    UnSetOldObject(oPC);

    int nSub=GetLocalInt(oPC,"Isa_SubRaceSetting_WorkingRace");
    string sSub=IsaSubRace_GetNameByCode(nSub);

    string sSkin="Isa_S_"+sSub;
    string sHeart="Isa_H_"+sSub;

    IsaDestroyItemByTag(oPC,sSkin);

    sSkin=GetStringLowerCase(sSkin);

    object oSkin=CreateItemOnObject(sSkin,oPC);
    AssignCommand(oPC,ActionEquipItem(oSkin,INVENTORY_SLOT_CARMOUR));
    CreateItemOnObject(sHeart,oPC);

    SetSubRace(oPC,sSub);



    }

  • ProlericProleric Member Posts: 1,281
    This article may help:
    https://nwnlexicon.com/index.php/Builders_Guide_To_Horses#PC_Creature_Skins

    In brief, older systems using skins should still work, as long as the skin is created and equipped as soon as the player enters the module. To be safe, test whether the PC already has a skin (using GetItemInSlot, as the tag may be different). If so, you can use the existing skin instead.

    What you've seen elsewhere isn't correct - older scripts can still work, and skins are still equipped in the CARMOUR slot.
  • Talon79Talon79 Member Posts: 10
    great! so i could work onit! thanks
Sign In or Register to comment.