What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

Widget to interact with my DLL?

Status
Not open for further replies.

czzplnm

Member
Joined
Jun 18, 2012
Messages
88
Reaction score
0
If I wanted to have a "Collect Ore" check box on Widget, how would I be able to detect that in my program? I've seen someone elses code that looks like this:

PHP:
<?xml version="1.0" encoding="utf-8"?>
<widget size="170;500" opacity="1" backColor="#FF000000" textColor="#FF000000" font="Tahoma, 9pt" style="pro" expandButton="true" configButton="false" scriptButton="true" logButton="true" soundButton="true">
	<titleFormula>me.name</titleFormula>
	<element type="bar" size="146;17" pos="12;25" bright="#aa2f1e" faded="#6d342e" text_color="#151515">
		<value>me == null ? 0 : Math.Round((me.hp / (me.maxHp+0.0001)) * 100)</value>
		<text>me == null ? "Offline" : (me.hp + "/" + me.maxHp)</text>
	</element>
	<element type="bar" size="146;17" pos="12;47" bright="#1d09a9" faded="#342e6d" text_color="#c5c5c5">
		<value>me == null ? 0 : Math.Round((me.mp / (me.maxMp+0.0001)) * 100)</value>
		<text>me == null ? "Offline" : (me.mp + "/" + me.maxMp)</text>
	</element>
	<element type="bar" size="146;17" pos="12;69" bright="#aa2f1e" faded="#6d342e" text_color="#151515">
		<value>me.target == null ? 0 : Math.Round((me.target.hp / (me.target.maxHp+0.0001)) * 100)</value>
		<text>me.target == null ? "No target" : (me.target.hp + "/" + me.target.maxHp)</text>
	</element>
	<element type="coords" size="146;33" pos="12;91" showCoordText="1" />
	<element type="groups" size="146;553" pos="12;130" />
</widget>

I am assuming we can do something like this:

PHP:
 If(myWidget.mineCheckbox.Checked)
mineOre = true;
else
 mineOre = false;

I want to interact with the widget to control my bot.


Is there an API doc somewhere on this?
 
Last edited:
Also interested in this topic. As a plug-in to transfer the value of the checkbox widget?

Плюсую. Как значение чекбокса (или иного элемента виджета) получать в плагине ?
 
Also interested in this topic. As a plug-in to transfer the value of the checkbox widget?

Плюсую. Как значение чекбокса (или иного элемента виджета) получать в плагине ?

Yes, I saw someone elses mod that added custom options to the embedded widget. I would like to make my own addons to the widget that my program can interact with.
 
DelAllGroupStatus
DelGroupStatus
GetGroupStatus
SetGroupStatus

SetGroupStatus("Name") - will create checkbox with Name
GetGroupStatus("Name") - will receive isChecked for this checkbox
 
DelAllGroupStatus
DelGroupStatus
GetGroupStatus
SetGroupStatus

SetGroupStatus("Name") - will create checkbox with Name
GetGroupStatus("Name") - will receive isChecked for this checkbox
Спасибо.
Подскажите еще, пожалуйста, как в виджете добавить текстовое поле (большого шрифта), в котором бы в реальном времени отображалось бы расстояние до выделенной цели и можно ли, что бы текст менял цвет, когда значение расстояния становится меньше какого-то значения. (например до 20метров - красный цвет шрифта, менее 20 метров - зеленый) ?
 
DelAllGroupStatus
DelGroupStatus
GetGroupStatus
SetGroupStatus

SetGroupStatus("Name") - will create checkbox with Name
GetGroupStatus("Name") - will receive isChecked for this checkbox

I have in my program:

PHP:
            SetGroupStatus("Mining", true);
            SetGroupStatus("Engage Creatures", true);
            SetGroupStatus("Gathering", true);
            SetGroupStatus("Lumbering", false);
            SetGroupStatus("Find Fruit", true);
            SetGroupStatus("Collect Grapes", true);
            SetGroupStatus("Gather Leaves", true);
            SetGroupStatus("Collect Figs", true);
            SetGroupStatus("Paused", false);
            SetGroupStatus("Ignore objects", false);
            SetGroupStatus("Use GPS Coordinates", false);
            SetGroupStatus("Revive Pet", true);

But only up to Lumbering shows up, I have extended the height of the widget and I can not get all options to show up. Is this a bug in the SetGroupStatus code?
 
Status
Not open for further replies.
Back
Top