-
Notifications
You must be signed in to change notification settings - Fork 0
API UO GetProfile en
ClassicUO / Basic IDE
Reads the public character description sent by the server for the Profile window. Useful for notes or text matching; this is not a manager configuration profile.
UO.GetProfile(serial:Any) -> String
-
serial— Character serial: number, 0x ID string or object selector such as "self" or "lasttarget". Not a body type, filename or manager profile.
String: description body, without header/footer. Empty is a valid description and also the result after no response for 3 seconds. Not Boolean. Every call sends a request; an already retained description returns immediately, including an open-window draft. It does not guarantee a fresh server reply.
- The description/draft belongs to the session. Closing graphics retains it without publishing; reopening restores Profile. Explicitly closing your own Profile submits changed text once; other characters are never updated. A new server reply replaces retained data; disconnect clears it. GetProfile never edits text.
SessionCharacterPanels validates complete profile/arrow packets and stores records on the session thread. The bridge reads them without graphics. GetProfile sends 0xB8 and waits up to 3 seconds in 25 ms intervals for available text. Track updates its separate local marker. ProfileGump and QuestArrowGump display the same records. Arrows are excluded from GetGumpsCount server dialogs.
Reads the public character description sent by the server for the Profile window. Useful for notes or text matching; this is not a manager configuration profile.
String: description body, without header/footer. Empty is a valid description and also the result after no response for 3 seconds. Not Boolean. Every call sends a request; an already retained description returns immediately, including an open-window draft. It does not guarantee a fresh server reply.
Project source: src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs; function GetProfile.
The description/draft belongs to the session. Closing graphics retains it without publishing; reopening restores Profile. Explicitly closing your own Profile submits changed text once; other characters are never updated. A new server reply replaces retained data; disconnect clears it. GetProfile never edits text.
SessionCharacterPanels validates complete profile/arrow packets and stores records on the session thread. The bridge reads them without graphics. GetProfile sends 0xB8 and waits up to 3 seconds in 25 ms intervals for available text. Track updates its separate local marker. ProfileGump and QuestArrowGump display the same records. Arrows are excluded from GetGumpsCount server dialogs.
Project source: src/ClassicUO.Client/Game/Managers/SessionCharacterPanels.cs; function SessionCharacterPanels.
String: description body, without header/footer. Empty is a valid description and also the result after no response for 3 seconds. Not Boolean. Every call sends a request; an already retained description returns immediately, including an open-window draft. It does not guarantee a fresh server reply.
# Direct use
#
# Reads the public character description sent by the server for the Profile window. Useful for
# notes or text matching; this is not a manager configuration profile.
#
# String: description body, without header/footer. Empty is a valid description and also the
# result after no response for 3 seconds. Not Boolean. Every call sends a request; an already
# retained description returns immediately, including an open-window draft. It does not
# guarantee a fresh server reply.
SUB Main()
# "self" means your public description, not account configuration. Prints server text or an
# already retained session copy.
VAR note = UO.GetProfile("self")
IF note <> "" THEN
UO.Print(note)
END IF
END SUBParameter and execution notes:
- "self" means your public description, not account configuration. Prints server text or an already retained session copy.
# Game condition
#
# Reads the public character description sent by the server for the Profile window. Useful for
# notes or text matching; this is not a manager configuration profile.
#
# String: description body, without header/footer. Empty is a valid description and also the
# result after no response for 3 seconds. Not Boolean. Every call sends a request; an already
# retained description returns immediately, including an open-window draft. It does not
# guarantee a fresh server reply.
SUB Main()
# Requires a valid lasttarget. InStr looks for case-sensitive "Healer" in free text. AddObject
# saves that serial as healerNote on a match. This is user text, not proof of NPC profession.
IF NOT UO.Exists("lasttarget") THEN
RETURN
END IF
VAR note = UO.GetProfile("lasttarget")
IF InStr(note, "Healer") > 0 THEN
UO.AddObject("healerNote", "lasttarget")
END IF
END SUBParameter and execution notes:
- Requires a valid lasttarget. InStr looks for case-sensitive "Healer" in free text. AddObject saves that serial as healerNote on a match. This is user text, not proof of NPC profession.
# Complete helper function
#
# Reads the public character description sent by the server for the Profile window. Useful for
# notes or text matching; this is not a manager configuration profile.
#
# String: description body, without header/footer. Empty is a valid description and also the
# result after no response for 3 seconds. Not Boolean. Every call sends a request; an already
# retained description returns immediately, including an open-window draft. It does not
# guarantee a fresh server reply.
SUB Main()
# The complete HasPublicNote helper checks object existence and a substring, returning
# true/false. "Guild" is sample text; empty does not prove that the server has no such note.
IF HasPublicNote("lasttarget", "Guild") THEN
UO.AddObject("guildNote", "lasttarget")
END IF
END SUB
FUNCTION HasPublicNote(serial, phrase)
IF NOT UO.Exists(serial) THEN
RETURN FALSE
END IF
RETURN InStr(UO.GetProfile(serial), phrase) > 0
END FUNCTIONParameter and execution notes:
- The complete HasPublicNote helper checks object existence and a substring, returning true/false. "Guild" is sample text; empty does not prove that the server has no such note.
Русский · English · Українська · Deutsch · Français · Italiano · Español · 繁體中文 · 日本語 · 한국어
ClassicUO
Bad Newbie & Basic IDE
Найти в справочнике
Клиент и скрипты
Каталоги значений
Разработка и помощь