I found this widget looking at someone else's twine code.
<<widget "video">>
<<if $args[0]>>
<<if $VidForce is 1>>
<<print '<video width="320" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<set $VidForce = 0>>
<<elseif $VidSize is "giant">>
<<print '<video width="1180" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<elseif $VidSize is "bigger">>
<<print '<video width="950" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<elseif $VidSize is "big">>
<<print '<video width="800" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<elseif $VidSize is "medium">>
<<print '<video width="650" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<elseif $VidSize is "small">>
<<print '<video width="500" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<endif>>
<</if>>
<</widget>>
In his, he managed to have this only in one passsage, and I cant seem to find how or if he call other passages to this line of code or twine does it for him. Yet in my story, for .webm files, I have to put this in each passage, and before the code, to get .webm files to play.
In his, he just has "<<set $vid = $image>><<video $vid>>" and it draws on the passage with the 'video' widget.
For my story, I can't get .webm files to work without having that block of widget text before the passage and before the
<<set $vid = $image>><<video $vid>> command.
Why is this?
<<widget "video">>
<<if $args[0]>>
<<if $VidForce is 1>>
<<print '<video width="320" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<set $VidForce = 0>>
<<elseif $VidSize is "giant">>
<<print '<video width="1180" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<elseif $VidSize is "bigger">>
<<print '<video width="950" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<elseif $VidSize is "big">>
<<print '<video width="800" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<elseif $VidSize is "medium">>
<<print '<video width="650" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<elseif $VidSize is "small">>
<<print '<video width="500" autoplay loop><source src="p/' + $args[0] + '.webm" type=\'video/webm; codecs="vp8, vorbis"\'></video>'>>
<<endif>>
<</if>>
<</widget>>
In his, he managed to have this only in one passsage, and I cant seem to find how or if he call other passages to this line of code or twine does it for him. Yet in my story, for .webm files, I have to put this in each passage, and before the code, to get .webm files to play.
In his, he just has "<<set $vid = $image>><<video $vid>>" and it draws on the passage with the 'video' widget.
For my story, I can't get .webm files to work without having that block of widget text before the passage and before the
<<set $vid = $image>><<video $vid>> command.
Why is this?