LearningRO Posted November 6, 2019 Group: Members Topic Count: 107 Topics Per Day: 0.02 Content Count: 778 Reputation: 73 Joined: 02/10/12 Last Seen: 33 minutes ago Share Posted November 6, 2019 Hi, All i want to spawn monster but all status include mdef/def/element can be configuration via NPC? how to syncron between Monster and NPC for setting Quote Link to comment Share on other sites More sharing options...
1 Balfear Posted November 6, 2019 Group: Members Topic Count: 13 Topics Per Day: 0.00 Content Count: 256 Reputation: 245 Joined: 07/24/13 Last Seen: March 24 Share Posted November 6, 2019 1 hour ago, LearningRO said: Hi, All i want to spawn monster but all status include mdef/def/element can be configuration via NPC? how to syncron between Monster and NPC for setting You can use "setunitdata" in your script when spawn monsters.script_commands Spoiler *getunitdata <GID>,<arrayname>; *setunitdata <GID>,<parameter>,<new value>; This is used to get and set special data related to the unit. With getunitdata, the array given will be filled with the current data. In setunitdata the indexes in the array would be used to set that data on the unit. Both getunitdata and setunitdata will return -1 if the given GID does not exist. Note: When adjusting a unit's stat (STR, AGI, etc) the unit's respective statuses are recalculated (HIT, FLEE, etc) automatically. Keep in mind that some stats don't affect a unit's status and will have to directly be modified. Parameters (indexes) for monsters are: UMOB_SIZE UMOB_LEVEL UMOB_HP UMOB_MAXHP UMOB_MASTERAID UMOB_MAPID UMOB_X UMOB_Y UMOB_SPEED UMOB_MODE UMOB_AI UMOB_SCOPTION UMOB_SEX UMOB_CLASS UMOB_HAIRSTYLE UMOB_HAIRCOLOR UMOB_HEADBOTTOM UMOB_HEADMIDDLE UMOB_HEADTOP UMOB_CLOTHCOLOR UMOB_SHIELD UMOB_WEAPON UMOB_LOOKDIR UMOB_CANMOVETICK UMOB_STR UMOB_AGI UMOB_VIT UMOB_INT UMOB_DEX UMOB_LUK UMOB_SLAVECPYMSTRMD UMOB_DMGIMMUNE UMOB_ATKRANGE UMOB_ATKMIN UMOB_ATKMAX UMOB_MATKMIN UMOB_MATKMAX UMOB_DEF UMOB_MDEF UMOB_HIT UMOB_FLEE UMOB_PDODGE UMOB_CRIT UMOB_RACE UMOB_ELETYPE UMOB_ELELEVEL UMOB_AMOTION UMOB_ADELAY UMOB_DMOTION UMOB_TARGETID Quote Link to comment Share on other sites More sharing options...
Question
LearningRO
Hi, All i want to spawn monster but all status include mdef/def/element can be configuration via NPC?
how to syncron between Monster and NPC for setting
Link to comment
Share on other sites
1 answer to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.