Page 3 of 3 FirstFirst 123
Results 41 to 50 of 50
  1. #41
    Community Member Jacoboon's Avatar
    Join Date
    Sep 2009
    Posts
    55

    Cool /salute

    So, when I wrote that guide over a year ago, I just wanted to share some knowledge that I had stumbled upon that had serious RP value and general game-improving qualities. I wanted to give people an extra dimension of creativity. An added tool of immersion. That extra little bit that draws you into the story/group/adventure/feeling at that precise moment in time. It truly is what DnD is about in my honest opinion. The game started with dice and a character sheet. Throw in a DM screen, a monstrous compendium, and some IMAGINATION and you have something going. The game should not limit our creativity. It should nurture it, write it letters, and stow away a college fund for it.

    We want our friggin custom emotes. Obviously.

    I added a link to your thread here at the top of my guide. Would you kindly return the favor and add a link to my petition at the top of yours? https://forums-old.ddo.com/forums/showthread.php?p=3373531

    +1
    Last edited by Jacoboon; 08-04-2012 at 03:32 AM.

  2. #42
    Community Member
    Join Date
    Feb 2011
    Posts
    26

    Default

    i noticed something:when i used /ui layout save [name].txt ,it was saves as .txt file.not sure if it can be then loaded properly,but you may want to look into it.
    and i made this too:
    <Alias String=";hi" Value="/wave &lt;&lt;>p>hello mates!"/>
    funny thing,is that when i made it,i used the <p>.maybe it can be used to convert the standart rgb code to the complicated code needed for the new format?

  3. #43
    Community Member error55o's Avatar
    Join Date
    Sep 2009
    Posts
    0

    Default

    Quote Originally Posted by Mernom View Post
    i noticed something:when i used /ui layout save [name].txt ,it was saves as .txt file.not sure if it can be then loaded properly,but you may want to look into it.
    and i made this too:
    <Alias String=";hi" Value="/wave &lt;&lt;>p>hello mates!"/>
    funny thing,is that when i made it,i used the <p>.maybe it can be used to convert the standart rgb code to the complicated code needed for the new format?
    you used >p> not <p>

    just saying :P

  4. #44
    Community Member
    Join Date
    Aug 2012
    Posts
    261

    Default

    Been messing with this a bit.

    NOTE: If you are confused by this, it may be because you are confusing two layers of data.

    1. Alias definitions and expansions.
    2. XML.

    You need to separate these mentally to make sense of what's happening.

    XML is the stuff with <Foo/> and <Foo></Foo>. The rules are (oversimplified):

    1. Tags are either <Foo></Foo> or <Foo/>.
    2. Tags can have attributes, which look like name="value".
    3. The contents of attributes need to have <>&" encoded.

    Basically, once you're in the right hunk of the UI layout file, an alias entry looks like:
    Code:
    <Alias String="STRING" Value="VALUE"/>
    As to the contents of VALUE, start with the string you actually want, then:

    1. Replace every ampersand (&) with "&amp;".
    2. Replace every double quote (") with "&quot;".
    3. Replace every less-than (<) with "&lt;".
    3. Replace every greater-than (>) with "&gt;". Yes, I know, it sometimes works if you don't, but don't rely on that. Consistency is king with fussy file formats...

    Aliases are the DDO aliasing stuff. The rules are:
    1. Each alias has a name and a value. The name is introduced with a semicolon, the value is any string.
    2. After an alias is expanded, it's rescanned for more aliases.
    3. All the letters after an alias are treated as an alias name. If you have an alias named ";this", and you write ";thisandthat", you won't get the alias expanded.
    4. The main thing you likely care about is colors, which are done as <rgb=#XXXXXX>text</rgb>.
    5. Note that this requires encoding; see above.

    So if you want to create an alias with the name ";redred" and the value "<rgb=#ff0000>RED</rgb>", the XML code looks like:

    Code:
    <Alias String=";redred" Value="&lt;rgb=#ff0000&gt;RED&lt;/rgb&gt;"/>
    As you can see, the <rgb=...> turned into "&lt;rgb=...&gt;".

    For most of this, I'll be showing the raw alias strings and values, because they're more legible.

    Aliases are expanded recursively (the result of each expansion is reviewed again for more expansions). So:

    Code:
    ;red = "ff0000"
    ;redred = "<rgb=#;red>RED</rgb>"
    produces the same effect as the above.

    There are limits to this. Each alias's expansion is looked at separately. For instance:

    Code:
    ;red = "ff0000"
    ;semi = ";"
    ;color = "red"
    ;redred = ";semi;color"
    Given these definitions, ";redred" expands to a literal ";red" which is not further expanded.

    Let's say you wanted to string stuff together. Like, say, alternating colors for a stupendously obnoxious holiday greeting:

    Code:
    <rgb=#ff0000>M</rgb><rgb=#00ff00>e</rgb><rgb=#ff0000>r</rgb>...
    And you have:
    Code:
    ;red = "<rgb=#ff0000>"
    ;green = "<rgb=#00ff00>"
    ;end = "</rgb>"
    You might want to do:
    Code:
    ;redM;end;greene;end;redr;end...
    But this obviously won't work.

    You can do:
    Code:
    ;red M;end;green e;end;red r;end
    and it will work, but it'll be "s p a c e d o u t".

    Well, long story short: You can't make an alias expand immediately followed by a letter. And you can't have enough aliases to just make, say, aliases for every letter:

    Code:
    ;a = "a"
    ;b = "b"
    ..
    What you can do is move the > out of the alias:
    Code:
    # leave the trailing > so it can be part of the caller's string.
    ;red = "<rgb=#ff0000"
    ;green = "<rgb=#00ff00"
    Now, ";red>M;green>e;red>r..." will do what you want.

    Of course, since the aliases are now stored in an XML file, that becomes unwieldy; you have to write something like:

    Code:
    <Alias String=";merry" Value=";red&gt;M;green&gt;e;red&gt;r..."/>
    So don't do that.

    Having a hard time getting your XML right? I've enclosed Lua and Ruby scripts to take aliases in the form I've been using above and generate an output file that can be loaded with "/ui layout load". If the file only has an Aliases section, it doesn't appear to overwrite any other settings (though I'm not 100% sure of this yet).

    I have no idea whether or how these would work with a DOS prompt, I use MinGW. With MinGW:

    Code:
    $ lua.exe aliases.lua < myaliases.in > myaliases.txt
    OR
    $ ruby aliases.rb < myaliases.in > myaliases.txt
    $ cp myaliases.txt /c/users/$LOGNAME/Documents/Dungeon*/ui/layouts
    And then in game:
    Code:
    /ui layout load myaliases.txt
    Ruby version:

    Code:
    header = <<EOH
    <?xml version="1.0" encoding="UTF-8" standalone="no" ?>
    <UI>
    
      <Version Value="1.0"/>
    
      <Aliases>
    EOH
    footer = <<EOH
      </Aliases>
    
    </UI>
    EOH
    aliases = []
    $<.lines do |line|
      next if line.match(%r{^\s*#})
      line.chomp!
      match = line.match(%r{^\s*;(\w*)\s*=\s*"(.*)"\s*$})
      if not match
        STDERR.puts("Can't match '#{line}'.")
        next
      end
      aliases << [ match[1], match[2] ]
    end
    print header
    aliases.each do |a|
      value = a[1]
      value.gsub!('&', '&amp;')
      value.gsub!('<', '&lt;')
      value.gsub!('>', '&gt;')
      value.gsub!('"', '&quot;')
      puts "    <Alias String=\";#{a[0]}\" Value=\"#{value}\"/>"
    end
    print footer
    Lua version:
    Code:
    local header = [[<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
    <UI>
    
      <Version Value="1.0"/>
    
      <Aliases>]]
    local footer = [[  </Aliases>
    
    </UI>]]
    local aliases = {}
    while true do
      local line = io.read()
      if line == nil then
        break
      end
      if not string.find(line, '^%s*#') then
        local name, value
        name, value = string.match(line, ';(%a+)%s*=%s*"(.*)"%s*$')
        if not value then
          print("Can't parse line: " .. line)
        else
          aliases[#aliases + 1] = { name, value }
        end
      end
    end
    
    print(header)
    for _, alias in ipairs(aliases) do
      name, value = unpack(alias)
      value = string.gsub(value, '&', '&amp;')
      value = string.gsub(value, '<', '&lt;')
      value = string.gsub(value, '>', '&gt;')
      value = string.gsub(value, '"', '&quot;')
      print('    <Alias String=";' .. name .. '" Value="' .. value .. '"/>')
    end
    print(footer)
    Last edited by seebs; 09-03-2012 at 09:46 PM.
    Yes, that seebs.
    Not having fun anymore? Learn to play, noob!

  5. #45
    The Hatchery Habreno's Avatar
    Join Date
    Sep 2009
    Posts
    1,145

    Default

    Remember when we could load the 11th through 20th hotbars without them "technically" being in-game? Can you still do that with 21st and on hotbars?


    If so I'd like to know.
    Quote Originally Posted by TheLegendOfAra View Post
    Welcome to Argo, where our end game players are constantly striving for new and exciting ways to make themselves more gimp, and continually working towards progressively more pointless goals.
    BYOH. Know it, abide by it, or don't mess with those who do.

  6. #46
    Community Member
    Join Date
    Feb 2010
    Posts
    37

    Default

    Ty very much for my colors alias back
    Sad that <p> dont work anymore but hope it will be back in a way some day.

    Uman-1

  7. #47
    Community Member brzytki's Avatar
    Join Date
    Sep 2009
    Posts
    671

    Default

    Quote Originally Posted by seebs View Post
    all sorts of awesomeness
    I haven't used your scripts yet but i bet using them along with AliasHQ should really cut down the time when creating some complicated aliases. Much appreciated and +1.

    Quote Originally Posted by Habreno View Post
    Remember when we could load the 11th through 20th hotbars without them "technically" being in-game? Can you still do that with 21st and on hotbars?

    If so I'd like to know.
    I've never needed more than 10 hotbars, not to mention more than 20, so i don't really know if it's still possible.
    Quote Originally Posted by Camarde View Post
    Ty very much for my colors alias back
    Sad that <p> dont work anymore but hope it will be back in a way some day.

    Uman-1
    For <p> try one of these:
    Code:
    &lt;p&gt; OR &lt;p>
    whichever should do the job, actually.
    Quote Originally Posted by Absolute-Omniscience View Post
    Did Einstein solo eLoB without pots or what?
    Guild: Captain's Crew
    Characters: Kyorli , Xunrae , Halisstra , Nyarly

  8. #48
    Community Member
    Join Date
    Aug 2012
    Posts
    261

    Default

    You should always escape either both or neither of <>. Some parsers will tolerate a > where there ought to be a &gt;, because they ignore a > if they haven't seen a < yet, but it's not going to be better.
    Yes, that seebs.
    Not having fun anymore? Learn to play, noob!

  9. #49
    Community Member Emili's Avatar
    Join Date
    Apr 2006
    Posts
    5,756

    Default

    Quote Originally Posted by Missing_Minds View Post
    Probably got removed from game due to griefers.

    Personally, it is obvious when it happens, and I say ban those people who do grief and give us those controls back.
    It was removed maybe due to red text. A certain few people used to speak about the "/death count " command and such or add in new line characters an such.

    A Baker's dozen in the Prophets of the New Republic and Fallen Heroes.
    Abaigeal(TrBd25), Ailiae(TrDrd2), Ambyre(Rgr25), Amilia(Pl20), Einin(TrRgr25), Emili(TrFgt25), Heathier(TrClc22), Kynah(TrMnk25), Meallach(Brb25), Misbehaven(TrArt22), Myara(Rog22), Rosewood(TrBd25) and Sgail(TrWiz20) little somethings with flavour 'n favour

  10. #50

    Default

    Quote Originally Posted by Emili View Post


    It was removed maybe due to red text. A certain few people used to speak about the "/death count " command and such or add in new line characters an such.

    If that was talking about the "P" command, no. It has been a while. The griefers would use the paragraph to go to the next line and fake being a GM to harras people as the chat log would show it as a new line, hence, different person talking.

Page 3 of 3 FirstFirst 123

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

This form's session has expired. You need to reload the page.

Reload