181
Pytania i problemy / Problem z Info_ClearChoices [G2NK]
« dnia: 2010-07-31, 16:44 »
Dzięki wielkie, ten pomysł ze zmienną okazał się dobrym rozwiązaniem. Temat do zamknięcia.
Ta sekcja pozwala Ci zobaczyć wszystkie wiadomości wysłane przez tego użytkownika. Zwróć uwagę, że możesz widzieć tylko wiadomości wysłane w działach do których masz aktualnie dostęp.
INSTANCE DIA_Aeral_Czlonkostwo (C_INFO)
{
npc = NONE_5001_Aeral;
nr = 601;
condition = DIA_Aeral_Czlonkostwo_Condition;
information = DIA_Aeral_Czlonkostwo_Info;
permanent = TRUE;
description = "Co do mojego członkostwa...";
};
FUNC INT DIA_Aeral_Czlonkostwo_Condition()
{
if (Npc_KnowsInfo (other, DIA_Aeral_Specjalizacja))
{
return TRUE;
};
};
FUNC VOID DIA_Aeral_Czlonkostwo_Info()
{
AI_Output (other, self ,"DIA_Aeral_Czlonkostwo_15_01"); //Co do mojego członkostwa...
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_03_02"); //Tak?
Info_ClearChoices (DIA_Aeral_Czlonkostwo);
Info_AddChoice (DIA_Aeral_Czlonkostwo, "Jestem gotów by zostać Asasynem!", DIA_Aeral_Czlonkostwo_Gotowy);
Info_AddChoice (DIA_Aeral_Czlonkostwo, "WRÓĆ", DIA_Aeral_Czlonkostwo_BACK);
};
FUNC void DIA_Aeral_Czlonkostwo_Gotowy()
{
if (other.HitChance[NPC_TALENT_1H] >= 30)
|| (other.HitChance[NPC_TALENT_2H] >= 30)
|| (other.HitChance[NPC_TALENT_BOW] >= 30)
|| (other.HitChance[NPC_TALENT_CROSSBOW] >= 30)
|| (Npc_GetTalentSkill (hero, NPC_TALENT_MAGE) >= 1)
{
AI_Output (other, self ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_02"); //Uważam, że jestem gotów by do was dołączyć.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_15_03"); //Tak uważasz?
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_15_04"); //No cóż ja jestem ZA!
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_05"); //Pokazałeś że coś umiesz.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_06"); //Nauczyłeś się przydatnych umiejętności.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_07"); //Czy jesteś gotów zostać prawdziwym Asasynem?
AI_Output (other, self ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_08"); //Tak jestem gotów!!!
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_09"); //A więc witaj w drużynie!
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_10"); //Od teraz noś ten amulet jako znak, że do nas należysz.
CreateInvItems (self, ItAm_Asasyn, 1);
B_GiveInvItems (self, other, ItAm_Asasyn, 1);
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_11"); //A i jeszcze coś.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_12"); //Nie obchodzi mnie co robisz poza obozem. Nasza gildia jest mało ważna w Khorinis. Nikt raczej o nas nie wie
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_13"); //więc masz prawo dołączyć do którejś z prawdziwych i ważnych gildii na wyspie.
AI_Output (other, self ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_15_14"); //Rozumiem.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_15"); //Teraz idź do Sythzona. Da ci jakiś porządny ekwipunek.
AI_Output (other, self ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_15_16"); //Do zobaczenia.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Gotowy_03_17"); //Nie daj się zabić.
Info_ClearChoices (DIA_Aeral_Czlonkostwo);
B_LogEntry (TOPIC_Dolaczenie_Asasyni,"Zostałem przyjęty w poczet Asasynów. Powinienem się udać do Sythzona po nowy ekwipunek.");
B_GivePlayerXP (2000);
Asasyn = 1;
AI_StopProcessInfos (self);
}
else
{
AI_Output (other, self ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Nie_gotowy_15_01"); //Sądzę, że jestem gotów do was dołączyć.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Nie_gotowy_15_02"); //Jest jeszcze dla ciebie za wcześnie.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Nie_gotowy_03_03"); //Popracuj trochę nad swoimi umiejętnościami, oczywiście w zależności od twojej specjalizacji.
AI_Output (self, other ,"DIA_Aeral_Czlonkostwo_Czlonkostwo_Nie_gotowy_03_04"); //Potrenuj trochę a cię przyjmę.
AI_StopProcessInfos (self);
};
};
FUNC void DIA_Aeral_Czlonkostwo_BACK()
{
Info_ClearChoices (DIA_Aeral_Czlonkostwo);
};
// ******************************************************************
// B_AddFightSkill
// ---------------
// setzt die Kampftalent-Ani abhängig von TrefferChance%
// (ab 30% und ab 60%)
// wird aus NPC_SetFightSkills aufgerufen (um FightSkill in NSC-Instanzen zu setzen)
// und aus B_TeachFightTalentPercent (um Player-Skill zu erhöhen)
// ******************************************************************
func void B_AddFightSkill (var C_NPC slf, var int talent, var int percent)
{
if (talent == NPC_TALENT_1H)
{
slf.HitChance[NPC_TALENT_1H] = slf.HitChance[NPC_TALENT_1H] + percent;
if (slf.HitChance[NPC_TALENT_1H] >=0)
{
Npc_SetTalentSkill (slf, NPC_TALENT_1H, 0);
Mdl_RemoveOverlayMDS (self, "Humans_1hST1.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_1hST2.MDS");
};
if (slf.HitChance[NPC_TALENT_1H] >=30)
{
Npc_SetTalentSkill (slf, NPC_TALENT_1H, 1);
Mdl_ApplyOverlayMDS (self, "Humans_1hST1.MDS");
Mdl_RemoveOverlayMDS(self, "Humans_1hST2.MDS");
};
if (slf.HitChance[NPC_TALENT_1H] >=60)
{
Npc_SetTalentSkill (slf, NPC_TALENT_1H, 2);
Mdl_ApplyOverlayMDS (self, "Humans_1hST2.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_1hST1.MDS");
};
};
if (talent == NPC_TALENT_2H)
{
slf.HitChance[NPC_TALENT_2H] = slf.HitChance[NPC_TALENT_2H] + percent;
if (slf.HitChance[NPC_TALENT_1H] >=0)
{
Npc_SetTalentSkill (slf, NPC_TALENT_2H, 0);
Mdl_RemoveOverlayMDS (self, "Humans_2hST1.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_2hST2.MDS");
};
if (slf.HitChance[NPC_TALENT_2H] >=30)
{
Npc_SetTalentSkill (slf, NPC_TALENT_2H, 1);
Mdl_ApplyOverlayMDS (self, "Humans_2hST1.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_2hST2.MDS");
};
if (slf.HitChance[NPC_TALENT_2H] >=60)
{
Npc_SetTalentSkill (slf, NPC_TALENT_2H, 2);
Mdl_ApplyOverlayMDS (self, "Humans_2hST2.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_2hST1.MDS");
};
};
if (talent == NPC_TALENT_BOW)
{
slf.HitChance[NPC_TALENT_BOW] = slf.HitChance[NPC_TALENT_BOW] + percent;
if (slf.HitChance[NPC_TALENT_BOW] >=0)
{
Npc_SetTalentSkill (slf, NPC_TALENT_BOW, 0);
Mdl_RemoveOverlayMDS (self, "Humans_BowT1.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_BowT2.MDS");
};
if (slf.HitChance[NPC_TALENT_BOW] >=30)
{
Npc_SetTalentSkill (slf, NPC_TALENT_BOW, 1);
Mdl_ApplyOverlayMDS (self, "Humans_BowT1.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_BowT2.MDS");
};
if (slf.HitChance[NPC_TALENT_BOW] >=60)
{
Npc_SetTalentSkill (slf, NPC_TALENT_BOW, 2);
Mdl_ApplyOverlayMDS (self, "Humans_BowT2.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_BowT1.MDS");
};
};
if (talent == NPC_TALENT_CROSSBOW)
{
slf.HitChance[NPC_TALENT_CROSSBOW] = slf.HitChance[NPC_TALENT_CROSSBOW] + percent;
if (slf.HitChance[NPC_TALENT_CROSSBOW] >=0)
{
Npc_SetTalentSkill (slf, NPC_TALENT_CROSSBOW, 0);
Mdl_RemoveOverlayMDS (self, "Humans_CBowT1.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_CBowT2.MDS");
};
if (slf.HitChance[NPC_TALENT_CROSSBOW] >=30)
{
Npc_SetTalentSkill (slf, NPC_TALENT_CROSSBOW, 1);
Mdl_ApplyOverlayMDS (self, "Humans_CBowT1.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_CBowT2.MDS");
};
if (slf.HitChance[NPC_TALENT_CROSSBOW] >=60)
{
Npc_SetTalentSkill (slf, NPC_TALENT_CROSSBOW, 2);
Mdl_ApplyOverlayMDS (self, "Humans_CBowT2.MDS");
Mdl_RemoveOverlayMDS (self, "Humans_CBowT1.MDS");
};
};
};