-
Originally Posted by
zerger3
how do i do that?
debugging a project that is interactively loaded as a DLL is somewhat more complicated than usual.
Сurrent "active colution configuration" must be set "Debug"
Usually VS is in this state by default - just check.
If everything is OK, then when you set a breakpoint in your plugin project, it will rise at the right time.
If not, you will see a warning that the current version of the code is different from the one being run through the API.
then just "REbuild" your plugin, and restart the API one more time - running "Loader".
-
Member
Originally Posted by
zerger3
is there a guide on how to make a new plugin?
i started looking at buffutil and tried to add a new spell but it seems i get the basics wrong.
i forked the repository on github and rename my repository to buffutil-my-hacks
so in the exilehudmenu i get a new entry name "buffutil-my-hacks" but that seems not to be enough since i am under the impression "my" plugin collides with the original inside exileapi and i get the error
it only works if i delete all plugins and then only once
2022-01-19 22:03:31.103 +01:00 [VRB] LoadAssembly -> Failed to load "C:\Games\poe exileapi my plugins\Plugins\Compiled\BuffUtil-my-hacks".
2022-01-19 22:03:31.118 +01:00 [ERR] LoadAssembly() -> System.InvalidOperationException: Die Sequenz enthält mehr als ein Element.
bei System.Linq.Enumerable.SingleOrDefault[TSource](IEnumerable`1 source)
bei ExileCore.Shared.PluginAutoUpdate.PluginLoader.LoadAssembly(DirectoryInfo dir) in /buddy/exileapi/Core/Shared/PluginAutoUpdate/PluginLoader.cs:Zeile 61.
ok i figured it out. issues is my created folder and the compiled dll are different
-
Member
ok i am getting into it but i still have some questions left (i am a noob coder and only wrote some simple scripts for lua years ago with notepad++ and i am new to visual studio and c#)
1. how do i properly setup a new plugin?
i watched PoeHUD. Creating custom plugins - YouTube
but it seems out of date and when i create a new project in VS 2019 i am not sure what template to choose from
2. i not sure about the "using"part at the top of the cs files
Code:
using System;
using System.Collections;
using System.Runtime.InteropServices;
using System.Windows.Forms;
using ExileCore.Shared;
using SharpDX;
but basically these are libraries that make certain functions available?
the first 3 seem to be basic stuff that build in to (net??)
System.Windows.Forms; seems to be a library for menus
i can google it and get some documentation (System.Windows.Forms Namespace | Microsoft Docs)
ExileCore.Shared; the stuff exile actually makes accessible
using SharpDX; for rendering stuff on screen
How do i know which to include?
4.
where do i see the available functions from using ExileCore.Shared?
5.
the script engine i worked with and wrote my lua scripts just ran the "code" multiple times per second and the code basically was a long list of if cases
i don't know how poeexile works
for example
BuffUtil/BuffUtil.cs at master . 0xE0D59/BuffUtil . GitHub
Code:
HandleBladeFlurry(); does the "have buff" and "not on cd" checks etc
OnExecute() calls all functions for buffs like handlebladeflurry(); HandlePhaseRun(); HandleWitheringStep
public override void Render()
{
// Should move to Tick?
if (OnPreExecute())
OnExecute();
OnPostExecute();
}
Render() -> OnExecute() -> HandleBladeFlurry()
when is Render() run?
Last edited by zerger3; 01-20-2022 at 09:34 AM.
-
ExileAPI is an extremely complex, confusing and illogical product (in my opinion), which is absolutely not suitable for learning the basics of c#
that's all
Originally Posted by
zerger3
...when is Render() run?
all plugins inherit from an abstract class
Code:
public abstract class BaseSettingsPlugin<TSettings>
the Rende() method is called cyclically by the API core
set a breakpoint insade Render() and open the "Call stack" menu. Follow down this list to understand what is being called and from where.
-
Member
Originally Posted by
zerger3
ok i am getting into it but i still have some questions left (i am a noob coder and only wrote some simple scripts for lua years ago
with notepad++ and i am new to visual studio and c#)
1. how do i properly setup a new plugin?
i watched
PoeHUD. Creating custom plugins - YouTube
but it seems out of date and when i create a new project in VS 2019 i am not sure what template to choose from
2. i not sure about the "using"part at the top of the cs files
Code:
using System;
using System.Collections;
using System.Runtime.InteropServices;
using System.Windows.Forms;
using ExileCore.Shared;
using SharpDX;
but basically these are libraries that make certain functions available?
the first 3 seem to be basic stuff that build in to (net??)
System.Windows.Forms; seems to be a library for menus
i can google it and get some documentation (
System.Windows.Forms Namespace | Microsoft Docs)
ExileCore.Shared; the stuff exile actually makes accessible
using SharpDX; for rendering stuff on screen
How do i know which to include?
4.
where do i see the available functions from using ExileCore.Shared?
5.
the script engine i worked with and wrote my lua scripts just ran the "code" multiple times per second and the code basically was a long list of if cases
i don't know how poeexile works
for example
BuffUtil/BuffUtil.cs at master . 0xE0D59/BuffUtil . GitHub
Code:
HandleBladeFlurry(); does the "have buff" and "not on cd" checks etc
OnExecute() calls all functions for buffs like handlebladeflurry(); HandlePhaseRun(); HandleWitheringStep
public override void Render()
{
// Should move to Tick?
if (OnPreExecute())
OnExecute();
OnPostExecute();
}
Render() -> OnExecute() -> HandleBladeFlurry()
when is Render() run?
1) extend the base plugin and override the calls you want to use
2) "using" imports a dependency.
3) You import anything you want to use. You know which ones to use because you import them as you run into needs. You already explained pretty decently what each one does, when you have a need for those in your plugin, you add them.
4) there's a lot. Like an actual ton. If you add it as a reference then open the reference, it should give you a tree view of everything accessible.
5) all base plugin classes are called from exileapi on their event. Render is called during the frame update (rendering). So it calls at whatever fps your exileapi is running at. That's the tick rate for it.
-
Member
ok well i forked the projects again and didnt rename them. just edited the files in my repository and only used my repo in plugin loader and everything works now.
how do i use the top part of devtree?
Wnbmitj.png
where do i see which monster models are loaded in an area?
are all monster models loaded when i enter a map? like the stuff preload alert can show? or are they only loaded when i get near them?
i guess they are in the entity list. is there a way to dump the list to a txt file or copy it to clipboard?
Last edited by zerger3; 01-22-2022 at 03:50 PM.
-
Member
Originally Posted by
zerger3
ok well i forked the projects again and didnt rename them. just edited the files in my repository and only used my repo in plugin loader and everything works now.
how do i use the top part of devtree?
Wnbmitj.png
where do i see which monster models are loaded in an area?
are all monster models loaded when i enter a map? like the stuff preload alert can show? or are they only loaded when i get near them?
i guess they are in the entity list. is there a way to dump the list to a txt file or copy it to clipboard?
Monster models ARE the preloads.
-
Member
Originally Posted by
lamleial
Monster models ARE the preloads.
cool thx, it also has an dump option
Last edited by zerger3; 01-23-2022 at 10:34 AM.
-
Member
latest patch seems to have broken quite a few plugins.
radar and healthbars for sure are not working.
-
Post Thanks / Like - 1 Thanks
armory236 (1 members gave Thanks to bobfromuk for this useful post)
-
Member
Needs update, new update broke everything
-
Post Thanks / Like - 1 Thanks
armory236 (1 members gave Thanks to User59 for this useful post)
-
Originally Posted by
User59
Needs update, new update broke everything
I hope everything will work - in any case, the "radar" and most of the UI elements working
Update IngameDataOffsets.cs by wlastas . Pull Request #295 . Queuete/ExileApi . GitHub
-
Post Thanks / Like - 1 Thanks
levelmax (1 members gave Thanks to GameAssist for this useful post)
-
Member
where do you put these files in the loader folder ? The autoupdate doesn't work.
-
Originally Posted by
kidsarehot
where do you put these files in the loader folder ? The autoupdate doesn't work.
Auto-update will work after the pull request is approved and the application is recompiled
-
Post Thanks / Like - 1 Thanks
snowhawk (1 members gave Thanks to GameAssist for this useful post)
-
Member
didn t used it for months and now radar is not working . can t see any monster
checked in minimapscons
- draw monster
- draw only on large map
thx
edit
fresh install and it s ok
Last edited by TGillou; 01-26-2022 at 04:52 AM.
-
Member
Simple pickit has not been working for me for more than a month now - anyone else has this?