Hello Everyone!
anyone have an idea how i can make the Craftings skills beeing ignored by the Skillcap?...
Thanks for your Help!
No one could use 2 weapons at same time but you need arms lore and things like that if you want a good crafter. I placed no total skill cap on mine but there is always other way to get around things you want them to be able to do or not.i had that in mind but then Players could use the Skilllimit other ways like having 2 weapon skills or whatever....
public int BaseFixedPoint
m_Owner.Total = (m_Owner.Total - m_Base) + sv;
if (!Skills.NonTotalInfluencingSkills.Contains(SkillName))
m_Owner.Total = (m_Owner.Total - m_Base) + sv;
public class Skills : IEnumerable<Skill>
{
//Ignore Skillcap
public static HashSet<SkillName> NonTotalInfluencingSkills = new HashSet<SkillName>()
{
SkillName.Alchemy, SkillName.ArmsLore, SkillName.Blacksmith, SkillName.Fletching, SkillName.Carpentry,
SkillName.Cartography, SkillName.Cooking, SkillName.Fishing, SkillName.Inscribe, SkillName.Tailoring,
SkillName.Tinkering, SkillName.Lumberjacking, SkillName.Mining
};
public Skills(Mobile owner, GenericReader reader)
m_Total += sk.BaseFixedPoint;
if(!NonTotalInfluencingSkills.Contains(sk.SkillName))
m_Total += sk.BaseFixedPoint;
public static bool CheckSkill(Mobile from, Skill skill, object amObj, double chance)
double gc = (double)(from.Skills.Cap - from.Skills.Total) / from.Skills.Cap;
double gc = (double)(from.Skills.Cap + (Skills.NonTotalInfluencingSkills.Contains(skill.SkillName) ? 1 : 0) - from.Skills.Total) / from.Skills.Cap;
funktion public static void Gain(Mobile from, Skill skill)
if (!from.Player || (skills.Total + toGain) <= skills.Cap)
{
skill.BaseFixedPoint += toGain;
}
if (!from.Player || (skills.Total + toGain) <= skills.Cap || Skills.NonTotalInfluencingSkills.Contains(skill.SkillName))
{
skill.BaseFixedPoint += toGain;
}
Got this error.ill post it here after testing gimme a hour about
[doublepost=1513198583][/doublepost]Thanks to my friend not sure if i am allowed to name him here so i don't name him here
so go to Skills.cs (Server/Skills.cs)
look for:
Code:public int BaseFixedPoint
Replace:
Code:m_Owner.Total = (m_Owner.Total - m_Base) + sv;
with:
Code:if (!Skills.NonTotalInfluencingSkills.Contains(SkillName)) m_Owner.Total = (m_Owner.Total - m_Base) + sv;
Look for:
add this:Code:public class Skills : IEnumerable<Skill> {
Code://Ignore Skillcap public static HashSet<SkillName> NonTotalInfluencingSkills = new HashSet<SkillName>() { SkillName.Alchemy, SkillName.ArmsLore, SkillName.Blacksmith, SkillName.Fletching, SkillName.Carpentry, SkillName.Cartography, SkillName.Cooking, SkillName.Fishing, SkillName.Inscribe, SkillName.Tailoring, SkillName.Tinkering, SkillName.Lumberjacking, SkillName.Mining };
Look for:
Code:public Skills(Mobile owner, GenericReader reader)
and there you Replace:
Code:m_Total += sk.BaseFixedPoint;
with:
Code:if(!NonTotalInfluencingSkills.Contains(sk.SkillName)) m_Total += sk.BaseFixedPoint;
Then look for File SkillCheck.cs (Misc/SkillCheck.cs)
look for:
Code:public static bool CheckSkill(Mobile from, Skill skill, object amObj, double chance)
Replace:
Code:double gc = (double)(from.Skills.Cap - from.Skills.Total) / from.Skills.Cap;
with:
Code:double gc = (double)(from.Skills.Cap + (Skills.NonTotalInfluencingSkills.Contains(skill.SkillName) ? 1 : 0) - from.Skills.Total) / from.Skills.Cap;
Then Look for:
Code:funktion public static void Gain(Mobile from, Skill skill)
Replace:
Code:if (!from.Player || (skills.Total + toGain) <= skills.Cap) { skill.BaseFixedPoint += toGain; }
with:
Code:if (!from.Player || (skills.Total + toGain) <= skills.Cap || Skills.NonTotalInfluencingSkills.Contains(skill.SkillName)) { skill.BaseFixedPoint += toGain; }
then your Done and again big thanks to my Friend who gave me this Code!
Yours Sincerly
MarcelMan
ill post it here after testing gimme a hour about
[doublepost=1513198583][/doublepost]Thanks to my friend not sure if i am allowed to name him here so i don't name him here
so go to Skills.cs (Server/Skills.cs)
look for:
Code:public int BaseFixedPoint
Replace:
Code:m_Owner.Total = (m_Owner.Total - m_Base) + sv;
with:
Code:if (!Skills.NonTotalInfluencingSkills.Contains(SkillName)) m_Owner.Total = (m_Owner.Total - m_Base) + sv;
Look for:
add this:Code:public class Skills : IEnumerable<Skill> {
Code://Ignore Skillcap public static HashSet<SkillName> NonTotalInfluencingSkills = new HashSet<SkillName>() { SkillName.Alchemy, SkillName.ArmsLore, SkillName.Blacksmith, SkillName.Fletching, SkillName.Carpentry, SkillName.Cartography, SkillName.Cooking, SkillName.Fishing, SkillName.Inscribe, SkillName.Tailoring, SkillName.Tinkering, SkillName.Lumberjacking, SkillName.Mining };
Look for:
Code:public Skills(Mobile owner, GenericReader reader)
and there you Replace:
Code:m_Total += sk.BaseFixedPoint;
with:
Code:if(!NonTotalInfluencingSkills.Contains(sk.SkillName)) m_Total += sk.BaseFixedPoint;
Then look for File SkillCheck.cs (Misc/SkillCheck.cs)
look for:
Code:public static bool CheckSkill(Mobile from, Skill skill, object amObj, double chance)
Replace:
Code:double gc = (double)(from.Skills.Cap - from.Skills.Total) / from.Skills.Cap;
with:
Code:double gc = (double)(from.Skills.Cap + (Skills.NonTotalInfluencingSkills.Contains(skill.SkillName) ? 1 : 0) - from.Skills.Total) / from.Skills.Cap;
Then Look for:
Code:funktion public static void Gain(Mobile from, Skill skill)
Replace:
Code:if (!from.Player || (skills.Total + toGain) <= skills.Cap) { skill.BaseFixedPoint += toGain; }
with:
Code:if (!from.Player || (skills.Total + toGain) <= skills.Cap || Skills.NonTotalInfluencingSkills.Contains(skill.SkillName)) { skill.BaseFixedPoint += toGain; }
then your Done and again big thanks to my Friend who gave me this Code!
Yours Sincerly
MarcelMan
It works fine if you follow those steps posted. There are a few differences in the code from when this was posted but it otherwise works.anyone ever get this working?
public sealed class SkillUpdate : Packet
{
public SkillUpdate(Skills skills)
: base(0x3A)
{
EnsureCapacity(6 + (skills.Length * 9));
m_Stream.Write((byte)0x02); // type: absolute, capped
for (int i = 0; i < skills.Length; ++i)
{
Skill s = skills[i];
double v = s.NonRacialValue;
int uv = (int)(v * 10);
if (uv < 0)
{
uv = 0;
}
else if (uv >= 0x10000)
{
uv = 0xFFFF;
}
m_Stream.Write((ushort)(s.Info.SkillID + 1));
m_Stream.Write((ushort)uv);
if (!Skills.NonTotalInfluencingSkills.Contains(skills[i].SkillName))
{
m_Stream.Write((ushort)s.BaseFixedPoint);
}
else
{
m_Stream.Write((ushort)0);
}
m_Stream.Write((byte)s.Lock);
m_Stream.Write((ushort)s.CapFixedPoint);
}
m_Stream.Write((short)0); // terminate
}
}
if (!Skills.NonTotalInfluencingSkills.Contains(skills[i].SkillName))
{
m_Stream.Write((ushort)s.BaseFixedPoint);
}
else
{
m_Stream.Write((ushort)0);
}
def check_inventory_space(player_inventory, skill_size):
non_total_influencing_skills = ["skill1", "skill2", "skill3"]
total_inventory_space = player_inventory.capacity
used_inventory_space = 0
for item in player_inventory.items:
if item.name not in non_total_influencing_skills:
used_inventory_space += item.size
if (used_inventory_space + skill_size) > total_inventory_space:
return False
return True
def soulstone_skill(player, skill):
if check_inventory_space(player.inventory, skill.size):
player.inventory.add(skill)
player.remove_skill(skill)
print("Skill soulstoned successfully.")
else:
print("Not enough inventory space to soulstone that skill.")
I actually got it working last night. There were bunch of other changes that needed to be made to allow you to gain non-exempt skills when you're at the 720 skill cap, but it IS working. I'd like to change the "Show Real" to show exempt vs non-exempt totals, but haven't finished that yet.
Thanks! I appreciate this!I went through a bunch of iterations (fixing issues one by one) but I'll try and put it all together into a single post in the next day or two.
To give you an idea of all the files required to make it work properly: (I may have moved a few files around, so I apologize if they don't line up perfectly with what you may have)
Scripts\Items\Artifacts\Consumables\InfusedAlchemistsGem.cs
Scripts\Items\Consumables\ScrollOfTranscendence.cs
Scripts\Items\Consumables\SoulStone.cs
Scripts\Mobiles\Normal\BaseCreature.cs
Server\Skill.cs
Server\Skills.cs
Server\SkillInfo.cs
If you want "Show Real" to work "properly", then you'll also need to edit:
Server\Network\Packets.cs
I believe that's all the files that require some amount of editing. It's definitely not a "simple" fix
Did anyone ever get this figured, I as well am having this issue.. obviously the code has progressed since then and is a bit different but after doing some tweaking this was the exact same issue that I was haviung.
I had no luck either and was recently tinkering with this.I never managed to figure this out unfortunatey. If someone is willing to share their code, it would be much appreciated.
We use essential cookies to make this site work, and optional cookies to enhance your experience.