One npc for honor halos

12/16/2009 10:23 WHITELIONX#1
Ok so somebody was asking about a single npc for all the honor halos so I decided to have a go and yup I created that single npc for all the honor halos, however the problem still remains for me that a Warrior can obtain an Archer halo :( I tried to have it so that only ninja can obtain Ninja halo and so on but I am not sure what else to do but anyways this code is set for Victor in TC the npv with the balloons. I hope somebody works on this so that it only gives the correct halos for the correct profession chars apart from Deputy/Guild/MonthlyPK/WeeklyPK.

case 300006: //Victor
{
if (Control == 0)
{
GC.AddSend(Packets.NPCSay("Hi, I can give honor halos are you interested?"));
GC.AddSend(Packets.NPCLink("Would you like the Top FireTaoist Halo?", 1));
GC.AddSend(Packets.NPCLink("Would you like the Top Trojan Halo?", 2));
GC.AddSend(Packets.NPCLink("Would you like the Top WaterTaoist Halo?", 3));
GC.AddSend(Packets.NPCLink("Would you like the Top Archer Halo?", 4));
GC.AddSend(Packets.NPCLink("Would you like the Top Warrior Halo?", 5));
GC.AddSend(Packets.NPCLink("Would you like the Top Ninja Halo?", 6));
GC.AddSend(Packets.NPCLink("Would you like the Top GuildLeader Halo?", 7));
GC.AddSend(Packets.NPCLink("Would you like the Top DeputyLeader Halo?", 8));
GC.AddSend(Packets.NPCLink("Nah.", 255));
GC.AddSend(Packets.NPCSetFace(30));
GC.AddSend(Packets.NPCFinish());
}
if (Control == 1)
{
if (GC.MyChar.Job >= 140 && GC.MyChar.Job <= 145)
{
}
else
{
GC.AddSend(Packets.NPCSay("You are not a FireTaoist, so get lost, will you?"));
GC.AddSend(Packets.NPCLink("Sorry.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
GC.MyChar.StatEff.Add(StatusEffectEn.TopFireTaoist );
GC.Message(2005, GC.MyChar.Name + "Has won the Top FireTaoist Halo");

}

if (Control == 2)
{
if (GC.MyChar.Job >= 10 && GC.MyChar.Job <= 15)
{
}
else
{
GC.AddSend(Packets.NPCSay("You are not a Trojan, so get lost, will you?"));
GC.AddSend(Packets.NPCLink("Sorry.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
GC.MyChar.StatEff.Add(StatusEffectEn.TopTrojan);
GC.Message(2005, GC.MyChar.Name + "Has won the Top Trojan Halo");
}
if (Control == 3)
{
if (GC.MyChar.Job >= 130 && GC.MyChar.Job <= 135)
{
}
else
{
GC.AddSend(Packets.NPCSay("You are not a WaterTaoist, so get lost, will you?"));
GC.AddSend(Packets.NPCLink("Sorry.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
GC.MyChar.StatEff.Add(StatusEffectEn.TopWaterTaois t);
GC.Message(2005, GC.MyChar.Name + "Has won the Top WaterTaoist Halo");

}
if (Control == 4)
{
if (GC.MyChar.Job >= 40 && GC.MyChar.Job <= 45)
{
}
else
{
GC.AddSend(Packets.NPCSay("You are not an Archer, so get lost, will you?"));
GC.AddSend(Packets.NPCLink("Sorry.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
GC.MyChar.StatEff.Add(StatusEffectEn.TopArcher);
GC.Message(2005, GC.MyChar.Name + "Has won the Top Archer Halo");

}
if (Control == 5)
{
if (GC.MyChar.Job >= 20 && GC.MyChar.Job <= 25)
{
}
else
{
GC.AddSend(Packets.NPCSay("You are not a Warrior, so get lost, will you?"));
GC.AddSend(Packets.NPCLink("Sorry.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
GC.MyChar.StatEff.Add(StatusEffectEn.TopWarrior);
GC.Message(2005, GC.MyChar.Name + "Has won the Top Warrior Halo");

}
if (Control == 6)
{
if (GC.MyChar.Job >= 50 && GC.MyChar.Job <= 55)
{

}
else
{
GC.AddSend(Packets.NPCSay("You are not a Ninja, so get lost, will you?"));
GC.AddSend(Packets.NPCLink("Sorry.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
GC.MyChar.StatEff.Add(StatusEffectEn.TopNinja);
GC.Message(2005, GC.MyChar.Name + "Has won the Top Ninja Halo");

}
if (Control == 7)
{
GC.MyChar.StatEff.Add(StatusEffectEn.TopGuildLeade r);
GC.Message(2005, GC.MyChar.Name + "Has won the TopGuildLeaderHalo");
}
}
if (Control == 8)
{
GC.MyChar.StatEff.Add(StatusEffectEn.TopDeputyLead er);
GC.Message(2005, GC.MyChar.Name + "Has won the TopDeputyLeaderHalo");
}

break;

#endregion
12/16/2009 10:30 Arcо#2
This has been released already.
[Only registered and activated users can see links. Click Here To Register...]
And next time you release a code.
Use the [code] tags please.
It makes it alot neater.
12/16/2009 10:48 WHITELIONX#3
Yup but that Top Class Effects thing gives around eleven pole npcs in TC and this script gives one npc only, that being Victor :D Somebody asked for a script like this and instead of cluttering the city up with loads of npcs for halos lol. Yup I will use code tag next time but how do I do that?
12/16/2009 10:53 Arcо#4
Quote:
Originally Posted by WHITELIONX View Post
Yup but that Top Class Effects thing gives around eleven pole npcs in TC and this script gives one npc only, that being Victor :D Somebody asked for a script like this and instead of cluttering the city up with loads of npcs for halos lol. Yup I will use code tag next time but how do I do that?

The post that I just referenced you to works perfectly with 1 npc, I don't know what you're talking about.
And a code tag is [*code*][*/code*].
Just take out the *'s.
12/16/2009 11:01 WHITELIONX#5
Ahhhh you mean the post that Korvacs put on that page hehehe I didn`t see that so my apologies
12/16/2009 11:18 Arcо#6
Here is what control 6 should look like:
Code:
if (Control == 6)
                                    {
                                        if (GC.MyChar.Job >= 50 && GC.MyChar.Job <= 55)
                                        {
                                            GC.MyChar.StatEff.Add(StatusEffectEn.TopNinja);
                                            GC.Message(2005, GC.MyChar.Name + "Has won the Top Ninja Halo");
                                        }
                                        else
                                        {
                                            GC.AddSend(Packets.NPCSay("You are not a Ninja, so get lost, will you?"));
                                            GC.AddSend(Packets.NPCLink("Sorry.", 255));
                                            GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                            GC.AddSend(Packets.NPCFinish());
                                        }
                                    }