A ja potrzebuję scrypta na ue combo :o
@edit
co ja niby złego napisałem że poszedł warned? czemu jest głupi :|?
Ostatnio zmieniony przez Blaze : 03-12-2008, 22:56
Ostatnio zmieniony przez Eldereq : 06-12-2008, 09:45
const
minPots = 100;
var
Pots: Integer;
procedure Event_Notice(Text: String);
begin
if Pos('mana', Text) = 0 then Exit;
Delete(Text, 1, 13);
Pots := StrToInt(Copy(Text, 1, Pos(' ', Text) - 1));
end;
begin
Pots := minPots;
while not terminated do
begin
UpdateWorld;
ProcessEvents;
if Pots < minPots then
beep;
Sleep(200);
end;
end;
Const
MinHealth = 100 // ile hp
NumberOfVialsToDrink = 1 // zostaw jak jest
IDPotion = 7876 // to tez zostaw jak jest
Delay = 0 // i to tez ;d
while not terminated do
begin
UpdateWorld;
if Self.Health <= MinHealth then
begin
for i := 1 to NumberOfVialsToDrink do
begin
if (i >= NumberOfVialsToDrink + 1) or (terminated = true) then break;
Self.Containers.UseItemWithSelf(IDPotion);
Sleep(Delay*1000);
end;
end;
Sleep(500);
end;
Ostatnio zmieniony przez Gray : 06-12-2008, 18:25
Ostatnio zmieniony przez vivek123 : 06-12-2008, 16:51
function GetCreatureByID(ID: integer): TCreature;
var
x: integer;
begin
Result := nil;
for x := 0 to Creatures.Count - 1 do
begin
if x >= Creatures.Count then Break;
if Creatures.Creature[x].ID = ID then
begin
Result := Creatures.Creature[x];
Exit;
end;
end;
end;
begin
while not Terminated do
begin
UpdateWorld;
if Self.Attacking <> 0 then
begin
Creature := GetCreatureByID(Self.Attacking);
if Creature <> nil then
begin
case Creature.Direction of
0: Self.Containers.UseItemWithGround(3180, Creature.X, Creature.Y - 2, Creature.Z);
1: Self.Containers.UseItemWithGround(3180, Creature.X + 2, Creature.Y, Creature.Z);
2: Self.Containers.UseItemWithGround(3180, Creature.X, Creature.Y + 2, Creature.Z);
3: Self.Containers.UseItemWithGround(3180, Creature.X - 2, Creature.Y, Creature.Z);
end;
end;
end;
Sleep(2000);
end;
end;
Const
MinHealth = 100 // ile hp
NumberOfVialsToDrink = 1 // zostaw jak jest
IDPotion = 266 // ID pota
Delay = 0 // zostaw jak jest
while not terminated do
begin
UpdateWorld;
if Self.Health <= MinHealth then
begin
for i := 1 to NumberOfVialsToDrink do
begin
if (i >= NumberOfVialsToDrink + 1) or (terminated = true) then break;
Self.Containers.UseItemWithSelf(IDPotion);
Sleep(Delay*1000);
end;
end;
Sleep(500);
end;
Ostatnio zmieniony przez Oli22 : 08-12-2008, 20:13
<<<O.A>>>
//Enter the settings for when to change to DEFENSIVE//
MonsterName = 'Dwarf Guard'
weapon1_ID = 3295
//Enter the settings for when to change to OFFENSIVE back//
Weapon2_ID = 3291
function GetItemFromOpenBackpack(ID: integer): TItem;
var
y: integer;
begin
Result := nil;
for x := 0 to Self.Containers.Count - 1 do
begin
if x >= Self.Containers.Count then Break;
for y := 0 to Self.Containers.Container[x].Count - 1 do
begin
if y >= Self.Containers.Container[x].Count then Break;
if Self.Containers.Container[x].Item[y].ID = ID then
begin
Result := Self.Containers.Container[x].Item[y];
Exit;
end;
end;
end;
end;
function GetCreatureByID(ID: integer): TCreature;
var
x: integer;
begin
Result := nil;
for x := 0 to Creatures.Count - 1 do
begin
if x >= Creatures.Count then Break;
if Creatures.Creature[x].ID = ID then
begin
Result := Creatures.Creature[x];
Exit;
end;
end;
end;
procedure Event_Attacked(ID:integer);
begin
Creature := GetCreatureByID(ID);
if Creature <> nil then
begin
A := 0;
if Creature.Name = MonsterName then
begin
Self.Defensive;
Weapon := GetItemFromOpenBackpack(Weapon1_ID);
if Self.RightHand.ID <> Weapon1_ID then
if Weapon = nil then
self.DisplayText('Weapon1 wasnt found in open backpack!');
else Weapon.MoveToBody(Self.RightHand,0);
A := 1;
end;
if not self.attacking then
if A = 0 then
begin
Self.Offensive;
if Self.RightHand.ID <> Weapon2_ID then
begin
Weapon := GetItemFromOpenBackpack(Weapon2_ID);
if Weapon <> nil then
Weapon.MoveToBody(Self.RightHand,0);
else Self.DisplayText('Weapon2 wasnt found in opened backpack!');
end;
end;
end;
end;
while not terminated do
begin
UpdateWorld;
ProcessEvents;
sleep(100);
end;
Aktualnie 1 użytkowników przegląda ten temat. (0 użytkowników i 1 gości)
Zakładki