Tukaram
Member
I was playing with a mana potion script, trying to get potion kegs to work. I am able to get it into and out of the potion keg, working and the bottles labeled right. The problem is the potion keg itself does not get a label. I looked at the potionkeg.cs and found where some other newer potions get labeled (invisibility, confusionblast etc). It looks like cliloc labels were added manually. I never did see how the original potion kegs got labeled (cure, refresh etc)
I used fiddler to add labels, on blank lines in the cliloc file. I copied it into the game files (renamed old clicloc.enu to .bak). I did a full recompile and still no labels on the keg. How does one use fiddler to add labels? Is it more than just the one cliloc file?
First code is how I got the potion keg to work with filling from bottles and refilling bottles (default was night sight). This part works:
This label section is giving me issues...
I used fiddler to add labels, on blank lines in the cliloc file. I copied it into the game files (renamed old clicloc.enu to .bak). I did a full recompile and still no labels on the keg. How does one use fiddler to add labels? Is it more than just the one cliloc file?
First code is how I got the potion keg to work with filling from bottles and refilling bottles (default was night sight). This part works:
keg filling & refilling bottle:
public BasePotion FillBottle()
{
switch (m_Type)
{
default:
case PotionEffect.Nightsight:
return new NightSightPotion();
case PotionEffect.CureLesser:
return new LesserCurePotion();
case PotionEffect.Cure:
return new CurePotion();
case PotionEffect.CureGreater:
return new GreaterCurePotion();
case PotionEffect.Agility:
return new AgilityPotion();
case PotionEffect.AgilityGreater:
return new GreaterAgilityPotion();
case PotionEffect.Strength:
return new StrengthPotion();
case PotionEffect.StrengthGreater:
return new GreaterStrengthPotion();
case PotionEffect.PoisonLesser:
return new LesserPoisonPotion();
case PotionEffect.Poison:
return new PoisonPotion();
case PotionEffect.PoisonGreater:
return new GreaterPoisonPotion();
case PotionEffect.PoisonDeadly:
return new DeadlyPoisonPotion();
case PotionEffect.Refresh:
return new RefreshPotion();
case PotionEffect.RefreshTotal:
return new TotalRefreshPotion();
case PotionEffect.HealLesser:
return new LesserHealPotion();
case PotionEffect.Heal:
return new HealPotion();
case PotionEffect.HealGreater:
return new GreaterHealPotion();
case PotionEffect.ExplosionLesser:
return new LesserExplosionPotion();
case PotionEffect.Explosion:
return new ExplosionPotion();
case PotionEffect.ExplosionGreater:
return new GreaterExplosionPotion();
case PotionEffect.Conflagration:
return new ConflagrationPotion();
case PotionEffect.ConflagrationGreater:
return new GreaterConflagrationPotion();
case PotionEffect.ConfusionBlast:
return new ConfusionBlastPotion();
case PotionEffect.ConfusionBlastGreater:
return new GreaterConfusionBlastPotion();
case PotionEffect.Invisibility:
return new InvisibilityPotion();
#region Mana Potions
case PotionEffect.Mana:
return new ManaPotion();
case PotionEffect.TotalMana:
return new TotalManaPotion();
#endregion
This label section is giving me issues...
keg labels:
public override int LabelNumber
{
get
{
if (m_Held > 0 && (int)m_Type >= (int)PotionEffect.Conflagration)
{
switch (m_Type)
{
case PotionEffect.Parasitic: return 1080069;
case PotionEffect.Darkglow: return 1080070;
case PotionEffect.Invisibility: return 1080071;
case PotionEffect.Conflagration: return 1072658;
case PotionEffect.ConflagrationGreater: return 1072659;
case PotionEffect.ConfusionBlast: return 1072662;
case PotionEffect.ConfusionBlastGreater: return 1072663;
//Mana Potions
case PotionEffect.Mana: return 1116792;
case PotionEffect.TotalMana: return 1116793;
}
}
return (m_Held > 0 ? 1041620 + (int)m_Type : 1041641);
}
}
Attachments
Last edited: