Jump to content
  • 0

About new Rathena change const.txt , can't use custom npc


Question

Posted (edited)

About new Rathena change const .txt( 7 days ).

I can't use my custom NPC.

How to use custom NPC in new Rathena?

If I use in const.txt,

map.serv will be [Error]:status_set_viewdata (NPC): No view data for class <your custom NPC number>

Any body can use custom in new Rathena?

Edited by redlightliu

5 answers to this question

Recommended Posts

  • 0
Posted (edited)
9 hours ago, redlightliu said:

Custom npc sprite:unsure:

a new ID too? I guess because your NPC id is out of range based on this check. https://github.com/rathena/rathena/commit/f42c2ff21171ac48fec329d6ff0dfdbbd2f0ea59#diff-301256667588bcb9a1bbf9b2ab500229R1094 try change the ID (<-- better this) or add/edit the range urself

// Old NPC range
#define MAX_NPC_CLASS NPC_RANGE2_END
// New NPC range
#define MAX_NPC_CLASS2_START NPC_RANGE3_START
#define MAX_NPC_CLASS2_END NPC_RANGE3_END

//Checks if a given id is a valid npc id. [Skotlex]
//Since new npcs are added all the time, the max valid value is the one before the first mob (Scorpion = 1001)
#define npcdb_checkid(id) ( ( (id) > NPC_RANGE1_START && (id) < NPC_RANGE1_END ) || (id) == JT_HIDDEN_WARP_NPC || ( (id) > NPC_RANGE2_START && (id) < NPC_RANGE2_END ) || (id) == JT_INVISIBLE || ( id > NPC_RANGE3_START && id < NPC_RANGE3_END ) )

 

or can u paste here what's u write on const.txt and in ur script definition?

Edited by Cydh
  • 0
Posted
2 hours ago, redlightliu said:

About new Rathena change const .txt( 7 days ).

I can't use my custom NPC.

How to use custom NPC in new Rathena?

If I use in const.txt,

map.serv will be [Error]:status_set_viewdata (NPC): No view data for class <your custom NPC number>

Any body can use custom in new Rathena?

npc id ? http://nn.ai4rei.net/dev/npclist/?qq=8

or custom npc sprite ?

  • 0
Posted
On 2017/10/22 at 10:29 AM, Cydh said:

a new ID too? I guess because your NPC id is out of range based on this check. https://github.com/rathena/rathena/commit/f42c2ff21171ac48fec329d6ff0dfdbbd2f0ea59#diff-301256667588bcb9a1bbf9b2ab500229R1094 try change the ID (<-- better this) or add/edit the range urself


// Old NPC range
#define MAX_NPC_CLASS NPC_RANGE2_END
// New NPC range
#define MAX_NPC_CLASS2_START NPC_RANGE3_START
#define MAX_NPC_CLASS2_END NPC_RANGE3_END

//Checks if a given id is a valid npc id. [Skotlex]
//Since new npcs are added all the time, the max valid value is the one before the first mob (Scorpion = 1001)
#define npcdb_checkid(id) ( ( (id) > NPC_RANGE1_START && (id) < NPC_RANGE1_END ) || (id) == JT_HIDDEN_WARP_NPC || ( (id) > NPC_RANGE2_START && (id) < NPC_RANGE2_END ) || (id) == JT_INVISIBLE || ( id > NPC_RANGE3_START && id < NPC_RANGE3_END ) )

 

or can u paste here what's u write on const.txt and in ur script definition?

Thanks, I will change ID in other official NPC.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

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