NewHudS

From the Oblivion ConstructionSet Wiki
Jump to navigation Jump to search

A command for Pluggy.

Syntax:

(HudID:long) NewHudS Filename:stringID RootID:short Show:short X:float Y:float Layer:long Scale:float Opacity:long Align:short AutoScale:bool Protected:bool EspID:long

Create a new Hud Surface.

  • Acceptable file types: .png, .bmp, .dds, .dib, .hdr, .jpg, .pfm, .png, .ppm, and .tga
RootID Codes
« ...\User Files\ » is assumed.
  0:    « My Documents\My Games\Oblivion\Pluggy\User Files\ »
  1:    Oblivion Data folder
  2:    Oblivion main folder
Show Codes
Add for combinations; i.e., GameMode+MenuMode is 11 (1 + 2 + 8)
GameMode is assumed.
  0:    Hidden
  1:    GameMode only (all menus closed, console closed)
  2:    MenuMode only (a menu open, console closed)
  4:    Console only (from GameMode or MenuMode)
  8:    Disable the "only" behaviour - this is necessary for any combination of GameMode, MenuMode, and console
  16:   Always display under Oblivion menus and huds (i.e., compass)
  • If showing in MenuMode, there are some menus in particular that shouldn't be covered up: 1007 (Loading), 1013 (Pause), 1015 (Options), 1017 (Audio), 1018 (Video), 1019 (Video Display), 1020 (Gameplay), 1021 (Controls), 1038 (Load), 1039 (Save), 1044 (Main), 1047 (Credits)
  • X and Y determine where the Hud is placed.
    • The position is the center of the image (i.e., X=0 and Y=0 and center alignment will center the image exactly, with the center of the image in the center of the screen).
    • The scale is a pixel - for a 1600x1200 resolution there are 1600 units for the X-axis and 1200 for the Y-axis.
    • The location is relative to the alignment. For instance, for a 1600x1200 resolution a center alignment would have coordinates from -800 to 800 (X) and -600 to 600 (Y) and a top-left alignment would have coordinates from 0 to 1600 (X) and 0 to 1200 (Y).
  • Layer is the "layer level" from 1 to 1000, 1000 being the "closest of the screen". It's mostly to be used when you want certain HudS to be on top on the others. 500 is assumed.
  • Scale is proportional to the original image.
  • Opacity is 0-100; 0 = transparent, 100 = opaque. 100 if assumed.
Alignment Codes
Add for combinations; i.e., Top-left would be 5, Center would be 15.
Top-Left is assumed.
  1:    Left
  2:    Right
  4:    Top
  8:    Bottom
  • AutoScale - if the user changes the game screen resolution between reloading the savegame, the Position and Scale of the HudS will be automatically adjusted so it will have the same proportional size and position than on the older screen resolution. AutoScale is assumed.
  • If EspID is not specified or is -1, then the EspID is automatically associated to the calling mod.
  • If Protected is not specified or is set to non-0, then the string will be write-protected from other mods, and only the associated mod will ever be able to modify the Hud. Setting Protected to 1 is recommended if you don’t want your Hud to be modified by another mod.
  • If the ESP file is not active upon reloading a savegame, all the associated Huds are destroyed when/if the player saves.