Submit Your Article


 
RPG Maker

Welcome Guest ( Log In | Register )


  Games Resources RPG Maker VX RPG Maker XP Scripts Tutorials Downloads

2 Pages V   1 2 >  
Closed TopicStart new topic
> Flash Script, malucifer's SWF Script
anime4mage
post Apr 29 2008, 07:55 AM
Post #1


Level 5
Group Icon

Group: Member
Posts: 60
Type: Event Designer
RM Skill: Skilled




Author - Malucifer
Original RMXP Tread Here

-Not recommended for Full Screen.-
-Warning you will need a Flash editor to put necessary Action Script-
-This means your Flash is original to you-

There are a lot of you that would like Flash put in with your game.
Not to mention that a flash file is small in size.

Well I asked a friend (malucifer) and he agreed it is beneficial to everyone here.

Download the Demo Here

All you Have to do is copy this code into Script Editor
Title it whateveruwant I called it Scene_Flash
CODE
$library_dir=(Dir.pwd).concat("/malib")

class Malib
def playFlash(fileName)
if(File.exist?((Dir.getwd).concat("/flash/").concat(fileName)))
tempDir=(0.chr)*255
Win32API.new("kernel32", "GetTempPath", ['L', 'P'], 'L').call(254, tempDir)
tempDir=tempDir.delete(0.chr)
tempDir=tempDir.tr("\\", "/")
filenum=1
tempFileDel=tempDir+"RMXPFS"+(filenum.to_s)+".maltmp"
while(File.exist?(tempFileDel))
filenum+=1
tempFileDel=tempDir+"RMXPFS"+(filenum.to_s)+".maltmp"
end#while
createTempFile=File.new(tempFileDel, "w+")
createTempFile.close
myLibShell=$library_dir+"/RMXPFlash.exe "+fileName
myLibShell+="malstrsplit"+tempFileDel
Win32API.new("kernel32", "WinExec", ['P', 'L'], 'L').call(myLibShell, 1)
flashWaitTimer=Thread.new do
loop do
if(File.exist?(tempFileDel))
Graphics.update
sleep(0.75)
else
flashWaitTimer.stop
end#if
end#loop
end#Thread
end#if
return
end#def
end#class
[Show/Hide] Example
Create two Folders
[ Malib ] & [ Flash ]
in your Game Directory
'MyDocument'/RM##/Project/'folders here'


Take(copy,move) 'RMXPFlash.exe' to the Malib Folder
#From the Demo or on the attachment here#


Now in the Flash Folder
Your Flash Projects go here (swf files)
You can delete the .fla files when you finish your game project
-If you don't your game will have a higher file size

##-!This is Necessary!-##
in your fla files (flash editing) you will have to put an action script on the first & last Frame.
First frame
CODE
fscommand("RMXPCommand", "nohang")

Last Frame
CODE
fscommand("flashFinished", "return")

Exact Character Keys and Capitalization required
##-!This is Necessary!-##

For 'last frame' you can use a button and put it anywhere in the frame timeline.
(if you make an arcade game and don't want to autoexit)
CODE
on (press) {fscommand("flashFinished", "return")}

See Step 4 on 2nd post for example
##---------------------------------------------------------------------------------------------##

OK to call a Flash Scene just call this script
CODE
(Malib.new).playFlash("intro.swf")
[Show/Hide] Example

Where intro.swf is the name of flash file plus its suffix.

To Call intro
In Script Editor on Main before begin call
CODE
(Malib.new).playFlash("intro.swf")

begin
  Graphics.freeze
.....
[Show/Hide] Example

##------------------------------------------------------------------------------------------------##

Download the Demo Here -or- Get exe & swf attachment here \/

This post has been edited by anime4mage: May 27 2008, 09:05 AM
Attached File(s)
Attached File  MaFiles.zip ( 100.02K ) Number of downloads: 191
Attached File  Flash_Script.html ( 9.74K ) Number of downloads: 110
 


__________________________
http://www.animemage.org<< My website (^^)
Go to the top of the page
 
+Quote Post
   
anime4mage
post May 6 2008, 01:12 PM
Post #2


Level 5
Group Icon

Group: Member
Posts: 60
Type: Event Designer
RM Skill: Skilled




If you want to embed a video to flash I recommend using Adobe Flash.

Import your movie file(avi,wmv,mpg,...) and a pop window will ask what to do?

Choose Embed Video[or Movie Clip] to SWF or whatever.

Choose the best Codec Conversions, I Recommend looking at the Movie Script Tread for Best Possible Conversions.

and convert.

Don't forget to put in the beginning and end Action Scripts





- I tried to be as informative as much as I can; Don't hate me -

This post has been edited by anime4mage: May 23 2008, 07:48 AM


__________________________
http://www.animemage.org<< My website (^^)
Go to the top of the page
 
+Quote Post
   
cyon8785
post May 9 2008, 06:39 AM
Post #3



Group Icon

Group: Member
Posts: 1
Type: Musician
RM Skill: Beginner




Sorry to be a bother, but when RPG VX loads a flash movie
a window appears on the top left corner but disappears quickly so I cannot view its content is this a bug?
(except for this your RPG XP Flash player works perfectly fine)
Go to the top of the page
 
+Quote Post
   
anime4mage
post May 12 2008, 07:35 AM
Post #4


Level 5
Group Icon

Group: Member
Posts: 60
Type: Event Designer
RM Skill: Skilled




QUOTE (cyon8785 @ May 9 2008, 07:53 AM) *
Sorry to be a bother, but when RPG VX loads a flash movie
a window appears on the top left corner but disappears quickly so I cannot view its content is this a bug?
(except for this your RPG XP Flash player works perfectly fine)
No I do not believe it is. It works on my VX just fine. I have found that if missplaced or mis-scripted can cause failure. try re-scripting it or ask malucifer.

This is probably because of the opens in new window 'thing' on original tread.
I do the same thing in movie script.

This happens because I think it has to load data in new window then close so it can play right.
This kind of file load is only playable on window mode[not full screen].

This is not my work, and Malucifer is still working on this script.

This post has been edited by anime4mage: May 12 2008, 07:40 AM


__________________________
http://www.animemage.org<< My website (^^)
Go to the top of the page
 
+Quote Post
   
Elighja
post May 13 2008, 06:15 PM
Post #5


Graphics Designer/Programmer
Group Icon

Group: Revolutionary
Posts: 202
Type: Developer
RM Skill: Advanced




Im going to try this script. Its exactly what i need so I really hope it works out great.
Go to the top of the page
 
+Quote Post
   
Elighja
post May 17 2008, 07:13 PM
Post #6


Graphics Designer/Programmer
Group Icon

Group: Revolutionary
Posts: 202
Type: Developer
RM Skill: Advanced




Ok should I be able to run a flash vid anytime possible by calling it in an event? if so then its not working...
Go to the top of the page
 
+Quote Post
   
anime4mage
post May 18 2008, 01:21 PM
Post #7


Level 5
Group Icon

Group: Member
Posts: 60
Type: Event Designer
RM Skill: Skilled




Did you use the 'call script' event to call -
(Malib.new).playFlash("intro.swf")

where 'intro.swf' is name of file

don't forget Action Scripts- and Scripts spelled and caracterized exactly


__________________________
http://www.animemage.org<< My website (^^)
Go to the top of the page
 
+Quote Post
   
Elighja
post May 18 2008, 01:44 PM
Post #8


Graphics Designer/Programmer
Group Icon

Group: Revolutionary
Posts: 202
Type: Developer
RM Skill: Advanced




Yes I used the call scrip in an vent. Do you think maybe you can post one or two screen shots showing how to properly call a video in an event?
Go to the top of the page
 
+Quote Post
   
anime4mage
post May 20 2008, 07:02 AM
Post #9


Level 5
Group Icon

Group: Member
Posts: 60
Type: Event Designer
RM Skill: Skilled




You mean how to embed video?

Yes I will eventually get some snapshots posted.
maybe a week or two, in a update.

-converting video to swf is tricky-


__________________________
http://www.animemage.org<< My website (^^)
Go to the top of the page
 
+Quote Post
   
anime4mage
post May 23 2008, 07:49 AM
Post #10


Level 5
Group Icon

Group: Member
Posts: 60
Type: Event Designer
RM Skill: Skilled




Updated the Embedding video with picture tutorial's.


__________________________
http://www.animemage.org<< My website (^^)
Go to the top of the page
 
+Quote Post
   
anime4mage
post May 27 2008, 07:16 AM
Post #11


Level 5
Group Icon

Group: Member
Posts: 60
Type: Event Designer
RM Skill: Skilled




just a update added pic examples and a color coded html file to attachments, no more txt.

Html file can work with any browser.


__________________________
http://www.animemage.org<< My website (^^)
Go to the top of the page
 
+Quote Post
   
ZaidoBlue23
post Jun 5 2008, 05:04 AM
Post #12


Level 2
Group Icon

Group: Banned
Posts: 15
Type: Event Designer
RM Skill: Skilled




can u make it full screen
while playing a Flash Movie
in RGSS Player?
Please fix it...
I hope that it will help to other people
and also to me.

QUOTE (anime4mage @ May 27 2008, 06:30 AM) *
just a update added pic examples and a color coded html file to attachments, no more txt.

Html file can work with any browser.


why are you advertising your website using signature!!!
Reported

This post has been edited by ZaidoBlue23: Jun 5 2008, 05:05 AM


__________________________
Beyond Reality
Go to the top of the page
 
+Quote Post
   
anime4mage
post Jun 5 2008, 07:28 AM
Post #13


Level 5
Group Icon

Group: Member
Posts: 60
Type: Event Designer
RM Skill: Skilled




QUOTE (ZaidoBlue23 @ Jun 5 2008, 06:18 AM) *
can u make it full screen
while playing a Flash Movie
in RGSS Player?
Please fix it...
I hope that it will help to other people
and also to me.


Unfortunatly I Can't make it work in full screen mode; in fact I can't/willnot decompile Malucifer's Libarary exe(MaLib.exe) to see what he did.


QUOTE (anime4mage @ May 27 2008, 06:30 AM) *
just a update added pic examples and a color coded html file to attachments, no more txt.

Html file can work with any browser.

It's an HTML file, like a worddoc, but usable in all computers: Mac,Unix,Windows.

QUOTE (ZaidoBlue23 @ Jun 5 2008, 06:18 AM) *
why are you advertising your website using signature!!!

Why not? I'll later use my site to post my Dev's and Graphic set's, Since I'm a developer and I'm not forcing anyone to join.

+Users are allowed to include a web site address in a signature, request comments on their personal site in a
social setting, or providing only once an interesting or relevant link to another site. -under Board Guidelines-

This post has been edited by anime4mage: Jun 5 2008, 07:44 AM


__________________________
http://www.animemage.org<< My website (^^)
Go to the top of the page
 
+Quote Post
   
SasukeKun
post Jun 6 2008, 09:43 AM
Post #14


Level 2
Group Icon

Group: Member
Posts: 24
Type: Event Designer
RM Skill: Beginner




Thanks for the script. I was looking for something like that. I will try it when my intro animation finished.
Go to the top of the page
 
+Quote Post
   
Yanazake
post Aug 24 2008, 04:32 AM
Post #15


Level 6
Group Icon

Group: Member
Posts: 80
Type: Artist
RM Skill: Skilled




I tried to use the flash that came with the demo, but I couldn't call it.

By the way, is there any update for this script?
Go to the top of the page
 
+Quote Post
   
jedah vulture
post Nov 14 2008, 02:33 PM
Post #16



Group Icon

Group: Member
Posts: 1
Type: Event Designer
RM Skill: Beginner




Are you still working on it?
Is it possible to pass information from the rpg maker to flash ???
Thanks
Go to the top of the page
 
+Quote Post
   
Amechiki
post Apr 7 2009, 07:40 PM
Post #17



Group Icon

Group: Member
Posts: 3
Type: Artist
RM Skill: Undisclosed




I've just tested the intro video that plays at the beginning before the title screen, and I've found that if you click on the window, as if to move it, the title screen music will begin to play. It only plays if you click on the window though, if you sit back and watch the intro it's perfectly fine. But it seems like it would cause problems for people who would want to make a longer, more cinematic intro (like me =D)

sorry if I'm necro-posting.
Go to the top of the page
 
+Quote Post
   
Fina
post Apr 16 2009, 05:33 PM
Post #18



Group Icon

Group: Member
Posts: 1
Type: None
RM Skill: Undisclosed




QUOTE (Amechiki @ Apr 7 2009, 08:40 PM) *
I've just tested the intro video that plays at the beginning before the title screen, and I've found that if you click on the window, as if to move it, the title screen music will begin to play. It only plays if you click on the window though, if you sit back and watch the intro it's perfectly fine. But it seems like it would cause problems for people who would want to make a longer, more cinematic intro (like me =D)

sorry if I'm necro-posting.


This works perfectly in RPG Maker VX!!

I couldn't get two other video scripts to work, because my .avi file was too large and other formarts were clunky. But this worked great!

Saved my project.
Go to the top of the page
 
+Quote Post
   
Valdred
post Nov 22 2010, 09:44 AM
Post #19


Level 4
Group Icon

Group: Member
Posts: 56
Type: Developer
RM Skill: Advanced




The file is temporarily unavailable. It's been so for a while. Could you re-upload?


__________________________
Go to the top of the page
 
+Quote Post
   
rpgmakermaster
post Jan 29 2011, 01:05 PM
Post #20


Level 1
Group Icon

Group: Member
Posts: 12
Type: None
RM Skill: Beginner




mm i have a question, can i use this script to play video on a skill in battle like a summoning???
Go to the top of the page
 
+Quote Post
   

2 Pages V   1 2 >
Closed TopicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Lo-Fi Version Time is now: 22nd May 2013 - 01:03 PM
RPG RPG Revolution is an Privacy Policy and Legal
eXTReMe Tracker