Modcraft - The community dedicated to quality WoW modding!

Wrath of the Lich King Modding => Serverside Modding => Topic started by: human1104 on September 28, 2016, 10:53:01 pm

Title: Trinitycore: Smart_script
Post by: human1104 on September 28, 2016, 10:53:01 pm
Hello.
I created an NPC with gossip, and smart scrypt.

Gossip:

Entry:                               2
option_icon                      0
Optiontext                        Ready to fight
Option_ID:                       1
NPC_option_NPCflag:     1


Smart_scrypt.

Entry                                 39
source type                      0
event type                        62
event chance                   100
event param                     2
action type                        2   SMART_ACTION_SET_FACTION
action param                    16
target_type                       1


I want to create, to if i talk to the npc, after i can fight him.
I create this scripts, after the NPC nameplate turn .. Red color. Like any enemy. But i cant fight for her. What i do wrong, or what can i do, to work correcctly?

And how can i do, to i can only talk this npc, if i accept the quest?
Title: Re: Trinitycore: Smart_script
Post by: human1104 on September 30, 2016, 02:59:30 am
Solved
Title: Re: Trinitycore: Smart_script
Post by: Amaroth on September 30, 2016, 08:24:51 am
LIke always, it would be nice to actually describe what was wrong and what turned out to be solution. Especially when apparently noone here knew what is wrong or what to do with it.
Title: Re: Trinitycore: Smart_script
Post by: human1104 on September 30, 2016, 02:56:53 pm
I just want to create a quest, similar like this:

http://www.wowhead.com/quest=10273/trou ... stractions (http://www.wowhead.com/quest=10273/troublesome-distractions" onclick="window.open(this.href);return false;)
 or this

http://www.wowhead.com/quest=10273/trou ... stractions (http://www.wowhead.com/quest=10273/troublesome-distractions" onclick="window.open(this.href);return false;)

Accept the quest, talk to the NPC, after fight with her. But without lua script.

I found more siimilar quest, example argent tournament daily, or that what i link, but this quest bugged my server. Difficult to use example, not working quest.

So i asked here, to anyone know a solution for this problem. I writed whole smart, and gossip here, becouse my english lesson so pure. Too pure. I hoped to you guys understanding what i want. But probably not. No matter, i discover a smar_script options.

Action_type  36
Action param. Creature entry.

This option replace the actual creature for the optioned creature. So i just need to create a creature copies, with faction 16 code, and i can alredy fight with her.

So the single part of my problem wa solved.

But I do not know it always yet, how can i do, to i can only talk this npc, if i accept the quest?

I hope so, that understandable, what I want to say. I dont know better.