Giter VIP home page Giter VIP logo

leaguesharp.common's Introduction

LeagueSharp.Common

The LeagueSharp platform, common library is our main support library for all assemblies, containing code which are part of a system or sort of system, required or commonly used data, supporting interfaces designed to assist assemblies which make use of the platform scope. It is made by the whole community to allow a universal standard.

Getting Started

When starting development with our library, we recommend to overview some of our existing code, examples are available on the forums. Additionally, you're able to dig into the files and start reading how to code operates, most of the codes are self-explanatory with proper field/property/function names but documentation is available.

License

Works that are created for use on joduska.me or other PlaySharp affiliated sites can freely use this project.

If you contribute to this library you assign licensing use to us.

Versioning

We use SemVer for versioning.

Acknowledgments

  • Our active development team, which works on the common library.
  • All of the past and post contributors, which help the project.

leaguesharp.common's People

Contributors

aliniti avatar andyi19 avatar badao avatar beaving avatar brian0305 avatar chewymoon avatar dz191 avatar ehmehe avatar esk0r avatar godls avatar h3h3 avatar hashtagendif avatar hellsing avatar l33t avatar legacy3 avatar lizzaran avatar myo avatar nabbhacker avatar onekeytowin avatar screeder avatar shinesharp avatar soresu avatar thesaltywaffle avatar tomkeen12 avatar tr33s avatar tricksterjoe avatar worstping avatar xkurisu avatar xqxcpmxqx avatar yol0swag avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

leaguesharp.common's Issues

SellItem

SellItem packets are currently broken. (Or at least it doesn't work for trinkets.)

Utility.GetSpellSlot

Hi, I get code 44 to Sivir W, should get 1, because

public enum SpellSlot
{
Unknown = -1,
Q = 0,
W = 1,
E = 2,
R = 3,
Item1 = 4,
Item2 = 5,
Item3 = 6,
Item4 = 7,
Item5 = 8,
Item6 = 9,
Trinket = 10,
Recall = 11,
}

Thank you.

To: Esk0r. Please reed it

Hi Esk0r, I have a problem. I have been using leaguesharp, and now i cant enter to my account because i have to go to other house to live. Can you help me? Thank you for your attention.

SpellSlot says unknown when it isn't

var slot = ObjectManager.Player.GetSpellSlot(sdataname);
if (slot == SpellSlot.Unknown)
return;

It returns even when spellslot/spelldata is valid

Enhancement request: Add packet 0x97 (Model packet)

Structure is roughly (taken from intWars):

typedef struct _UpdateModel {
_UpdateModel(uint32 netID, const char *szModel) {
memset(this, 0, sizeof(_UpdateModel));
header.cmd = (PacketCmd)0x97;
header.netId = netID;
id = netID & ~0x40000000;
bOk = 1;
unk1 = -1;
strncpy((char *)szName, szModel, 32);
}
PacketHeader header;
uint32 id;
uint8 bOk;
uint32 unk1;
uint8 szName[32];
} UpdateModel;

Ignore Overlay while Orbwalking

You know sometimes when your holding orbwalk somewhere and you suddenly hover above one of LoLs UI like character ui and your champion starts glitching for a second.

Is it possible for the orbwalking to ignore the UIs around you?

Invalid z-coordinate calculation

                    result.CastPosition = input.RangeCheckFrom +
                                          input.Range *
                                          (result.UnitPosition - input.RangeCheckFrom).To2D().Normalized().To3D();

This code (in Prediction) multiples the z coordinate by input.Range given invalid values.

Update Dmg.cs For Nasus

Please update dmg for skill Q nasus !!!! It is : "Passive Count + Default Dmg + 100% Basic Attack Dmg"

More of a request that an issue. [Orbwalker]

I have a request a few requests that i wish to be added

  1. that you add a (prioritize farm over harass) for each mode (lasthit,waveclear, and harass) because i want to harass more than farm (unless big minion) if i'm holding harass button and then i wish to waveclear because a big wave is comming and do not wish to harass and so on..

  2. Prioritize big minions over small ones as sometimes it will attack the small and leave the big minion to die to our wave of minions

  3. something like assassin manager for big minions http://www.joduska.me/forum/topic/751-assassin-manager-for-assassin-characters/
    the idea here is when you are holding specific button (lasthit,waveclear, and harass) and a big minion which is about to die is within assassin manager range it will try to prioritize that big minion over the small minion near you

  4. Check what is the tower attacking and then do a check if the tower will kill it or not with the hit and if you will kill it before the tower
    For example; lets say there are 2 minions who are both under the tower ofcourse the tower will target one of them and any human player will kill the one the tower is targeting so the tower itself doesn't kill it and therefore lose gold because he will also have time to attack the other minion before the tower kills it but the orbwalker here will attack whichever is closer to you no matter if its killable or not and sometimes making you lose 2 minions instead of losing none

  5. LessAttackPriority + LessCastPriority self-explained

I actually had more in mind but i forgot them when writing this.

Wat is going on here

http://i.imgur.com/85YFd3k.png

My menus are all smooshed together almost off the screen, orbwalker doesn't move to mouse, and no spells cast with Spell.Cast

I'm using a fresh L# installation (27 september build), everything updated to latest github versions, and this persists across games/champions. Everything worked completely fine yesterday, and I'm quite puzzled as to what happened. If anyone has any insight, I would greatly appreciate it.

Also, Damage.GetItemDamage is still not implemented

Volibear W damage

Volibear W damage doesn't take in consideration the 15% bonus health, only the targeting missing health

Player.Buff

Can someone explain me Buff.DisplayName will change with other languages LoL ? or it always like that same like Name ? Bcz in L# Common i see you always use DisplayName instead of Name

TargetSelector (NearMouse)

Altrough nobody using it only I with Zed :P ,IMO its working pretty stupid. You need to have nonstop cursor on target to attack him. 50 is pretty low. If you get out of 50 it will just walk without attacking.
It should attack closest target near mouse

case TargetingMode.NearMouse:
return targets.FirstOrDefault(hero => hero.Distance(Game.CursorPos) < 50);

to

case TargetingMode.NearMouse:
return targets.FirstOrDefault(hero => hero.Distance(Game.CursorPos));

  • not sure if it will work or if it will cause lag, I am not coder.

GetAutoAttackDamage() issues

The calculated damage is 2.0 too low when attacking lane minions, also it does not incorporate Butcher mastery (then it is 4.0 too low). Tested with Ashe without any other items/masteries/runes.

Menu And ranges

Drawing.OnDraw doesnt not Fire when you load a script with orbwalker.
The menu isn't shown and it doesnt draw

HP Bar Damage Indicator not working

Am I doing something wrong or are the HP bar indicators broken?
They are not showing up at all.

var dmgComboWithItem =  new MenuItem("DrawComboDamage", "Draw Combo Damage").SetValue(true);
Utility.HpBarDamageIndicator.DamageToUnit = GetComboDmg;
Utility.HpBarDamageIndicator.Enabled = dmgComboWithItem.GetValue<bool>();

dmgComboWithItem.ValueChanged += delegate(object sender, OnValueChangeEventArgs eventArgs)
    {
        Utility.HpBarDamageIndicator.Enabled = eventArgs.GetNewValue<bool>();
    };

Update Damage.cs For Gragas

Gragas R is listed as SpellSlot.E in Damage.cs. This needs to be changed for Damage prediction to work correctly on Gragas.

Sth wrong with Dmg + DmgLib

The error in DmgLib (Leesin champ):
case SpellType.R:
return CalcPhysicalDmg((ObjectManager.Player.Spellbook.GetSpell(SpellSlot.R).Level * 200) + (2.0 * ObjectManager.Player.FlatMagicDamageMod), enemy);

The error in Dmg (Leesin champ): Q2 don't have stage to check
new DamageSpell{Slot = SpellSlot.Q, DamageType = DamageType.Physical, Damage = (source, target, level) => new double[]{50, 80, 110, 140, 170}[level] + 0.9 * source.FlatPhysicalDamageMod },
new DamageSpell{Slot = SpellSlot.Q, DamageType = DamageType.Physical, Damage = (source, target, level) => new double[]{50, 80, 110, 140, 170}[level] + 0.9 * source.FlatPhysicalDamageMod + 0.08 * (target.MaxHealth - target.Health)},

Oops. Prediction Problem?

g

yup 😄
just one picture 😃

using xSalice's Religion AIO, but that assembly just uses Q after GetPrediction and calc Hitchance!

maybe no problem on assembly.

calculation error? (20% hitchance on lane fight 😭 )

FEATURE: AP and AD specific AA range drawings.

Hate to compare this to that "other" script competitor, but it has a wonderful feature that allows you to see only the AA-range of the enemy ADC. With L#, currently, you see all enemies AA range in the Common Orbwalk option, and this can be chaotic. If you could implement sub-options that let you see only the enemy ADC and/or APC AA range, that would be amazing.

If you're curious, the competitor shows all 5 enemy AA ranges as an individual toggle.

Cast Spell with Packets ( zed E ) problem.

it seems like Zed E have a issue with Packetcasting

E = new Spell(SpellSlot.E, 125);

Works = E.CastOnUnit(ObjectManager.Player);
Not Works = E.CastOnUnit(ObjectManager.Player , true);

4.18 S2C Damage packet updated structure

I would do this as a pull request but I have no idea what the 6 bytes in the middle mean

position size (bytes) type description
0 1 Byte Header
1 4 Integer Target Network ID
5 1 Byte Damage Type
6 6 Unknown unknown - Damage Amount?
13 4 Integer Target Network ID Copy
17 4 Integer Source Network ID

Also, the damage type seem to have changed. So far, I've worked out that:
4 = Basic attack/Spell damage
3 = Critical attack

Sample packet (hex):
65 06 00 00 40 04 55 00 B2 33 D2 42 06 00 00 40 05 00 00 40

FEATURE: Jungle-Clear Orbwalk focuses Small Minions first.

Hello Common gurus,

It's been demonstrated mathematically that killing the small minions in a jungle camp results in healthier clears. Could you implement logic that would allow the Lane Clear / Jungle Clear orbwalk to attack small minions in a jungle camp before attacking the main minion? If the concern is enemy invasion, you can implement range logic such as "attack small minions first if no enemy within 1000 yards".

SpellSlot on Packets Not Working Correctly

In Packet.cs:202 and Packet.cs:187 you directly go from a byte to Spellslot and Spellslot to byte. This casting does not work as intended. I believe we want a mapping as follows:

128 = Q
129 = W
130 = E
131 = R
132 = Item_1
133 = Item_2
134 = Item_3
135 = Item_4
136 = Item_5
137 = Item_6
64 = Summoner_1
65 = Summoner_2
192 = Summoner_1
193 = Summoner_2
10 = Recall

Prediction Cone bug

Found out why cass ults are casting backwards when AOE is on and multiple targets are available:
(most assemblies fix it by checking if its casting bullsht and blocking the cast - which is not good because this way it can happen that it's not casting at all)

Basically
https://github.com/LeagueSharp/LeagueSharp.Common/blob/master/Prediction.cs#L670-670
is converting the positions to positions relative to the player, but
https://github.com/LeagueSharp/LeagueSharp.Common/blob/master/Prediction.cs#L709-709
doesn't calculate the real position and is returning the relative position. Replace the line with
CastPosition = (bestCandidate + input.From.To2D()).To3D(),
to make it work properly

Prediction.TargetsHit bug

Not sure exactly what is causing this bug, it has proven a little hard to isolate. TargetsHit doesn't seem to work for AOE spells (always returns 1). Tested with Oriannas ult and W (both of which don't cast on a position or target, they just... cast, which might be the issue here. Not sure how getprediction handles spells that don't actually have a target).

SpellShlot Summoner1 + 2 Error!

  •                    case SpellSlot.Summoner1:
    
  •                        return 0xEF;
    
  •                    case SpellSlot.Summoner2:
    

    Packet.cs(346,40): error CS0117: 'LeagueSharp.SpellSlot' enthält keine Definition für 'Summoner1'.
    Packet.cs(348,40): error CS0117: 'LeagueSharp.SpellSlot' enthält keine Definition für 'Summoner2'.

// IS FIXXED, GOT ALT LEAGUESHARP.DLL

how to build this project?

how to build this project?
where is the clipper_library,LeagueSharp,LeagueSharp.Sandbox,SharpDX,SharpDX.Direct3D9 Lib?

Spell.IsReady() bug

IsReady() will currently return true even if that skill has not yet been leveled. Should return false for all non-leveled spells

Found reason why there is AA-canceling problem

I tested on too many games. Because many korean have AA-canceling problem. (Include me)
We set "Extra Winduptime" to 200. but we still had AA-canceling problem.

Reason is..

Method "CanMove(float extraWindup)" on Orbwalking.cs
I deleted line...

if (_missileLaunched)
    return true;

It has no AA-canceling problem.

But it has big problem after channeling skills like Miss Fortune R and Caitlyn R, Orbwalking stops move before i use another skill.
(Yeah, just stops! It don't attack any object, and don't move to mouse.
But after i use any skill, it works.)

Any good idea to fix this problem?
(I try more to fix this problem on custom game before no Koreans have this problem.)

New Menu.cs file (new menu) causes severe lag when clicking icons

I believe this bug has now been Isolated to the Menu.cs file. The new menu implemented, causes a severe delay when clicking icons on the screen.

Shop/Spells/Teleport/Pings all seem to effected when using the mouse, I'm quite sure shortcut keys work fine but i'm not 100% on that, let me know if you need that info.

For now I am injecting the old Menu.cs file into a local version of the latest common commit, this appears to correct the issue but I am no longer on the gorgeous new menu.

Thanks and love your skills!!!

Zyra's "Flowers" missing in Orbwalker

Hey,

I noticed that the "flowers" of Zyra are not being attacked by the common orbwalker.

Would you mind to add them or is their a reason why they are not being attacked?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.