Hey
I'm making a custom quest but when it comes to the part to get the reward, it don't show and it don't give me the reward.
Please tell me how to fix this code or what's wrong with it.
Code:
#region Killer
case 67436:
{
if (Control == 0)
{
if (GC.MyChar.InventoryContains(710854, 1))
{
GC.AddSend(Packets.NPCSay("Hello. A letter huh. Well, I accidently killed ghost a while back. Tell him his apology is accepted."));
GC.AddSend(Packets.NPCLink("Sure Thing", 1));
GC.AddSend(Packets.NPCLink("No", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
if (Control == 1)
{
GC.MyChar.CPs += 10000000;
GC.AddSend(Packets.NPCSay("Here is your reward.!"));
GC.AddSend(Packets.NPCLink("Thank you", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
}
break;
#endregion
#region Killer
case 67436:
{
if (Control == 0)
{
if (GC.MyChar.InventoryContains(710854, 1))
{
GC.AddSend(Packets.NPCSay("Hello. A letter huh. Well, I accidently killed ghost a while back. Tell him his apology is accepted."));
GC.AddSend(Packets.NPCLink("Sure Thing", 1));
GC.AddSend(Packets.NPCLink("No", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have the required item.));
GC.AddSend(Packets.NPCLink("Sorry", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
if (Control == 1)
{
GC.MyChar.CPs += 10000000;
GC.AddSend(Packets.NPCSay("Here is your reward.!"));
GC.AddSend(Packets.NPCLink("Thank you", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
break;
}
#endregion
You need to learn where breaks go and how to use brackets.
#region Killer
case 67436:
{
if (Control == 0)
{
if (GC.MyChar.InventoryContains(710854, 1))
{
GC.AddSend(Packets.NPCSay("Hello. A letter huh. Well, I accidently killed ghost a while back. Tell him his apology is accepted."));
GC.AddSend(Packets.NPCLink("Sure Thing", 1));
GC.AddSend(Packets.NPCLink("No", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have the required item"));
GC.AddSend(Packets.NPCLink("Sorry", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
if (Control == 1)
{
GC.MyChar.CPs += 10000000;
GC.AddSend(Packets.NPCSay("Here is your reward.!"));
GC.AddSend(Packets.NPCLink("Thank you", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
break;
}
#endregion
@ Arco Your MIssing the " at the End of the Text, In
Code:
GC.AddSend(Packets.NPCSay("You don't have the required item.[COLOR="Red"]"[/COLOR]));
#region Killer
case 67436:
{
if (Control == 0)
{
if (GC.MyChar.InventoryContains(710854, 1))
{
GC.AddSend(Packets.NPCSay("Hello. A letter huh. Well, I accidently killed ghost a while back. Tell him his apology is accepted."));
GC.AddSend(Packets.NPCLink("Sure Thing", 1));
GC.AddSend(Packets.NPCLink("No", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have the required item"));
GC.AddSend(Packets.NPCLink("Sorry", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
if (Control == 1)
{
GC.MyChar.CPs += 10000000;
GC.AddSend(Packets.NPCSay("Here is your reward.!"));
GC.AddSend(Packets.NPCLink("Thank you", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
break;
}
#endregion
@ Arco Your MIssing the " at the End of the Text, In
Code:
GC.AddSend(Packets.NPCSay("You don't have the required item.[COLOR="Red"]"[/COLOR]));
Not only that, but I h ad the brackets misplaced.
Oh well, lol that's what happens when you try to do a code without using C#.
Well the code works, but the same problem occurs.
It don't give me the cp's and it don't tell me I have the reward, as soon as he asks me to tell ghost his apology is accepted and i say sure thing, it goes off.
#region Killer
case 67436:
{
if (Control == 0)
{
if (GC.MyChar.InventoryContains(710854, 1))
{
GC.AddSend(Packets.NPCSay("Hello. A letter huh. Well, I accidently killed ghost a while back. Tell him his apology is accepted."));
GC.AddSend(Packets.NPCLink("Sure Thing", 1));
GC.AddSend(Packets.NPCLink("No", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have the required item"));
GC.AddSend(Packets.NPCLink("Sorry", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
else if (Control == 1)
{
GC.MyChar.CPs += 10000000;
GC.AddSend(Packets.NPCSay("Here is your reward.!"));
GC.AddSend(Packets.NPCLink("Thank you", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
break;
}
#endregion
#region Killer
case 67436:
{
if (Control == 0)
{
if (GC.MyChar.InventoryContains(710854, 1))
{
GC.AddSend(Packets.NPCSay("Hello. A letter huh. Well, I accidently killed ghost a while back. Tell him his apology is accepted."));
GC.AddSend(Packets.NPCLink("Sure Thing", 1));
GC.AddSend(Packets.NPCLink("No", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have the required item"));
GC.AddSend(Packets.NPCLink("Sorry", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
else if (Control == 1)
{
GC.MyChar.CPs += 10000000;
GC.AddSend(Packets.NPCSay("Here is your reward.!"));
GC.AddSend(Packets.NPCLink("Thank you", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
break;
}
#endregion
Wouldn't you need to send the client a string packet to update the CPs amount the client shows? o.o
B> DriftCity CBS Code | S> War Rock Code / Bounty Bay Code etc. 10/05/2010 - Trading - 1 Replies Hi,
wie schon im Titel beschrieben. In der CBS vom November gab es Bonusodes für mehrere Spiele. Ich benötige DriftCity Codes. Kann sonst für alle anderen Spiele die Codes biten, einige auch doppelt.
Hier eine Liste der Spiele und Bonusaktionen:
- (2x) War Rock
- (2x) War of Titans
- (2x) World of Warcraft
- (1x) Warhammer Online
- (1x) Bounty Bay online
what is the wrong with this code help me 10/21/2009 - CO2 Private Server - 4 Replies 6001 27 ToxicFog 1 0 1 4 0 0 30010 0 0 3 4 10 8796093022208 0 5400 70 2 0 20 300 0 0 0 0 50 0 0 0 0 3 905 Upgrade~after~lvl~70 Continually~reduce~10%~of~target`s~current ~HP~each~time.~20~times~in~1~minute.~I neffective~when~the~target`s~HP~reaches~ 1.~Stamina~Cost:~50.~The~lower~battle~po wer~than~the~target`s,~the~less~accuracy . NULL NULL poisoncast sound\Ninjamagic-04A.wav 800 poisonattack NULL poisonblast.tme poisonfog01 0 0
i need to know what is the wrong with this code to run...
Whats wrong with this code? 07/02/2009 - CO2 Private Server - 9 Replies someone help me please
i put this code in
everything works except /drop bigscroll
any1 see anything wrong?
EDIT: bigscroll is for dbscrolls