,target and string editing

Ask for help

Moderators: Murderator+, Murderator

Post Reply
Leo((
Posts: 7
Joined: 2007-04-11 20:00:42

,target and string editing

Post by Leo(( »

hi guys, i'm from italy, so i don't speak russian (i'm sorry) and i try to write in english.

i play on ultima on line and usually i write scripts for me and my friends.
i'm trying to understand how to use the ,target command, but i can't find any help anywhere. i saw yoko's post in faq section, but it is not enough for me

how do i have to use ,target command? it is use to send a target after having used the object/skill like a manual click or before as a waittarget[something]?
i've tried to use this command some times. tell me if i'm wrong:
i wrote ,target 0x00000002 0x01567D94 but the client says "warning:error in command" and i was triyng to target a pg. i can't understand what is wrong...maybe the target key? (i have got it writing ,info lasttargetkey)

last question: how can i take just a part of a string of the journal?
if i say something injection journal writes like:"Leo: hello everybody". how can i do to get just what i said and not the whole line? or as is there any way to edit strings?

thank you so much
Nmy
Expert!
Posts: 2152
Joined: 2005-09-14 15:31:58
Location: Latvia

Post by Nmy »

viewtopic.php?p=57098#57098

try to use "waittarget"
Leo((
Posts: 7
Joined: 2007-04-11 20:00:42

Post by Leo(( »

thank you so much for your help with the strings!!
i'm sorry but maybe i didn't explained so well about targeting...
i usually write scripts that cast spells and immediately hit the target.
i'm triyng to find out the way to precast (preparing the spell and then wait for my target) and then hit the target.
at the moment i've solved it in this way:
- i (or better, the script) get the target and make an object with uo.findtype and uo.addobject
- i look for the target with the client command TargetNext until it is the same of the target i got before
- i cast the spell without hitting the target (so i wait some seconds)
- i hit the target using the client command LastTarget
it's a good solution, but some times TargetNext fails and targets another player and i don't want it.
i'm triyng to find out a better way to do it.
i explain the situation in game:
while we (the guild) are fighting with wizards we usually froze the enemy and then precast (in my shard we say precast, but i don't know how it is in english) flame strike. if we are 3-4 wizards we try to hit the enemy at the same time to kill him. what i want is to cast the spell and then be able to hit the target without clicking with the mouse so i could do it with scripts
i thought the command ,target could be a solution buy now i think i was wrong
could you help me??
Nmy
Expert!
Posts: 2152
Joined: 2005-09-14 15:31:58
Location: Latvia

Post by Nmy »

well i have few ideas but its always better to do it by yourself
Leo((
Posts: 7
Joined: 2007-04-11 20:00:42

Post by Leo(( »

it is good ti find out someone with some ideas...
no clues to help me?

i'm not asking for the script but just one or more clues to find it out by myself
i've also tried to use ,click but it doesn't work and i have found no command that simulates the click of the mouse on a determinate object
the problem is not to target the enemy but to target it some seconds after having activated the skill/spell.
i'll look again for something useful in this forum ;)
Sanch
Posts: 308
Joined: 2005-07-17 15:30:52
Location: www.drw.ru

Post by Sanch »

If uoy want to use object or type and then target, you may use uo.target(). But if you will use it incorrectly, you will be blocked.
Leo((
Posts: 7
Joined: 2007-04-11 20:00:42

Post by Leo(( »

so uo.target() could be a solution...good!
i'm triyng to use it properly but i find some problems :(

i want cast a spell and then to target a character, so:
- i need the targetkey
- i need his serial
i try to get the target key in this way: i cast a spell (and hit a character) and then a enter ",info lasttargetkey". injection in his text window replies "ID=0x00000002 (not an game object)". what does it means? maybe this command has been disabled in my shard?
go on...thinking that it could be the right target key i try to enter the command ,target: i cast poison, appears the sight and i write ",target 0x00000002 0x01567D94.
it happens nothing and the client says:"warning:error in command".
the documentation about this command says that this is the right syntax to use this command in this case...
i don't know what to do :(
maybe the command has been disabled?

at the moment i know only another way to target after using objects/casting and i tried to explain it in the previous post
Nmy
Expert!
Posts: 2152
Joined: 2005-09-14 15:31:58
Location: Latvia

Post by Nmy »

okey this is not a problem
the problem is how do you want to do it ? look in journal? i think its the only way
Post Reply