Code | function RunTest(ply, cmd, arg)
Winmain = vgui.Create("DFrame")
Winmain:SetPos(0,0)
Winmain:SetSize(800,600)
Winmain:SetVisible(true)
Winmain:SetTitle( "StartAnimate() Test" )
Winmain:MakePopup()
Winmain:ShowCloseButton(true)
Winhtml = vgui.Create( "HTML" , Winmain)
Winhtml:SetPos(0,30)
Winhtml:SetSize(790,560)
Winhtml:SetVisible(true)
local link = "dagobah.net/flash/Touhou_Canyon.swf" // you can put whatever media you want here
local url = [[<center>
<OBJECT ID="MediaPlayer" WIDTH="750" HEIGHT="530" CLASSID="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95"
STANDBY="Loading Windows Media Player components..." TYPE="application/x-oleobject">
<PARAM NAME="FileName" VALUE="http://]]..link..[[">
<PARAM name="autostart" VALUE="true">
<PARAM name="ShowControls" VALUE="false">
<param name="ShowStatusBar" value="false">
<PARAM name="ShowDisplay" VALUE="false">
</OBJECT>
</center>]]
Winhtml:SetHTML( url )
Winhtml:Refresh(true)
Winhtml:StartAnimate(100)
end
concommand.Add("animtest", RunTest) |