Mod Tool: Difference between revisions

new v3 with fix for PPGs; redoing code piece "import an image clip only once"
m (let's hide the trgv img until there's a release for it)
(new v3 with fix for PPGs; redoing code piece "import an image clip only once")
Line 1,524: Line 1,524:
  support_oni_DnD_OnEvent = true
  support_oni_DnD_OnEvent = true
  end function
  end function




Line 1,558: Line 1,557:
'''[39] import an image clip only once'''
'''[39] import an image clip only once'''


  found_img = 0
  image_path = "C:\Users\RRM\Desktop\white_512_512.tga"
  set clips = ActiveProject.ActiveScene.ImageClips
  for each clip in clips
Set FSO = CreateObject("Scripting.FileSystemObject")
logmessage clip.name
  image_clip = FSO.GetBaseName(image_path) & "_" & FSO.GetExtensionName(image_path)
if clip.name = "white_512_512_tga" then
  logmessage image_clip
logmessage "found img"
found_img = 1
if not typename(ActiveProject.ActiveScene.ImageClips(image_clip)) = "Nothing" then
end if
logmessage "found image clip"
  next
  else
if found_placeholder_img = 0 then
  logmessage "image clip not yet present, going to import ..."
  ' import a new texture
 
  ' just so:
  SICreateImageClip image_path
  SICreateImageClip "C:\Users\RRM\Desktop\white_512_512.tga"
  ' or as script object:
' or as script object:
  'set oImage = AddImageSource (image_path)
  'set oImage = AddImageSource ("C:\Users\RRM\Desktop\white_512_512.tga")
  'set oImageClip = AddImageClip (oImage)
  'set oImageClip = AddImageClip (oImage)
  end if
  end if
Line 1,601: Line 1,599:


'''known issues (all versions)'''
'''known issues (all versions)'''
* glitchy PPGs (manager windows sometimes switch from "locked" to "refresh" mode, etc.)
* "(un)hide all" button inverts visibility for all objects individually
* "(un)hide all" button inverts visibility for all objects individually
** e.g. if one object is hidden but rest is visible, the button will make it visible and the rest hidden
** e.g. if one object is hidden but rest is visible, the button will make it visible and the rest hidden
Line 1,610: Line 1,607:
* disables transparency on weapon textures
* disables transparency on weapon textures
* button to access OniXSI resources folder
* button to access OniXSI resources folder
* fixes glitchy PPGs (manager windows sometimes switched from "locked" to "refresh" mode, etc.)




8,452

edits