SlideShare a Scribd company logo
1 of 14
Download to read offline
SCALEFORM MINI-GAME TUTORIALS PART 1/3




                          1
Creating a Slider
Mini-Game in UDK
Replicate an often used gameplay mechanic, used in games like Bioshock!

These tutorials are recommended for users that are familiar with UDK
and Adobe Flash to an intermediate level. Also it is recommended that
users have some knowledge of how to setup Scaleform in UDK.

If unfamiliar with Scaleform, it is recommended to the user to at least
complete the first two Scaleform tutorials by Mathew Doyle on the
following link:
http://gameware.autodesk.com/scaleform/support/documentation

These tutorials show you how to install the Scaleform GFX previewer
in Adobe Flash, so you can test your .swf files to see if they would
work in UDK. They also show you what settings need to be adjusted
for .swf compatibility and how to use custom images.




                             2
Setting Up The Tutorial Files

                                  To start these tutorials, the user first needs to open
                                  the “Tutorial CD Files” folder on the supplied disc
                                  and access the “Tutorial_Files” folder. This folder
                                  contains the flash files and UDK maps we require
                                  throughout these tutorials.


Alternatively, you can download these folders from the following link:
http://www.gamefront.com/files/21548379/Tutorial+CD+Files.rar



The “Scaleform_Flash” folder needs to be copied
and pasted to the following directory:
[UDKUDK-2011-10UDKGameFlash]



The “Scaleform_UDK_Maps” folder needs to be
copied and pasted to the following directory:
[UDKUDK-2011-10UDKGameContentMaps]




To start this tutorial, we will use the files in the “Slider” folder in the copied
“Scaleform_Flash” folder.

Here we will use the “Slider_Start.fla” for this tutorial, but the user can view a
completed version in the “Slider_End.fla” for reference.

                                              3
Getting Started In Flash
After opening “Slider_Start.fla”, you can see that the image files
“Hacking_Unlocked.png”, “Hacking_Shocked.png”,
“Hacking_Alarm.png”, “Hacking.png” and “Cursor.png” has
already been imported into the Library. The layers have also already
been named.




Firstly the four hacking image files need to be placed on each of the four keyframes
on the “Background Image” layer. Place the “Hacking.png” on the first keyframe,
“Hacking_Unlocked.png” on the second keyframe, “Hacking_Alarm.png” on the
third keyframe and “Hacking_Shocked.png” on the last keyframe. Make sure they
are positioned and scaled the same.



Next the “Cursor.png” should be placed on the “Cursor” layer
keyframe. It should be scaled to the appropriate size and be
rotated to the start position with the pivot moved to the center of
the screw image.



                             Next on the “Actionscript” Layer, we want to name
                             each keyframe in the properties frame name, so we can
                             reference these frames using Actionscript later. The first
                             keyframe should be named “Start”, the second should
                             be named “Green”, the third should be named “Red”
                             and the last should be named “Yellow”.



Now on the keyframe in the “Cursor” layer, we want to turn the
image into a graphic by pressing F8 to “Convert to Symbol”.
We then want to repeat this method to place the graphic in a
movieclip.




                                            4
Cursor Animation
Now we want to name the movieclip “Cursor_MC” in the
properties so we can control this movieclip later using
Actionscript.




Inside the movieclip, we need to extend the timeline to 122 frames on the
“Animation” layer and a keyframe should then be made on frame 59 and the last
frame. An Actionscript layer should also be created on the layer above.




The first and last keyframe graphic should both be identical pointing at the starting
position to the right side. The second keyframe image should be rotated to the end
position to the left. Now a classic tween should be made to the timeline to create the
looping animation of the cursor sliding back and forth.

Now every frame on the
“Actionscript” layer should be
keyframed and the Actionscript in the
screenshot should be added to them.

This script makes the cursor stop when
the “E Key” is pressed and the main
timeline will stop on the keyframe we
named "Green".

Now watching the cursor animation, each
keyframe should be selected and the script name
“Green” should be renamed to “Red” when the
cursor hovers over the red areas and “Yellow”
when the cursor hovers over the yellow areas.


This will ensure that the main timeline will play the correct outcome when the “E
Key” is pressed during the animation.

                                          5
Main Timeline Actionscript
We now need to add the script functions to the keyframes on the “Actionscript”
layer on the main timeline.

Now the first frame should have a “stop();” script and the following three should
have the Actionscript in the screenshots applied to them.




                                                 The second keyframe needs the
                                                 “Unlocked” fscommand.




                                                The third keyframe needs the
                                                “Alarm” fscommand.




                                                 The last keyframe needs the
                                                 “Buzzed” fscommand.




This script stops the main timeline and the FSCommands are uniquely named to
allow us to reference them in UDK to activate functions.




                                          6
Success and Failure Feedback
We now need to add the feedback animations for the cursor
stopping in the Green and Red areas.

So on the second keyframe on the “Screen Animations”
layer, we need to create a green square with the dimensions
of 1280x720. It should then be placed at the centre of the
screen and turned into a graphic. After being turned into a
graphic, it then needs to be turned into a movieclip.



Within the movieclip we should name the layer
“Animation” and extend the timeline to 28 frames.
A keyframe should be made on frame 14 and the last
frame. An “Actionscript” layer should also be
created above with a keyframe at the end of the
timeline with a “stop();” Actionscript applied to it.




                 The “Alpha” “Colour Effect” should then be used on all three
                 keyframes to make the first and last keyframe invisible. The timeline
                 then needs to be turned into a classic tween to create our green
                 flash fade animation.




                                        This should then be repeated for the third
                                        keyframe on the “Screen Animations”
                                        layer in the main timeline. A red square
                                        should be used for a red flash fade
                                        animation.




                                          7
Buzzed Feedback
The last keyframe on the “Screen Animations” layer should have
an electrical shock animation. To do this we need to scribble a blue
electrical effect and turn it into a movieclip.




Inside the movieclip the main timeline needs to be
extended to 41 frames and the layer should be
called “Animation”. A key frame should then be
added to frame 16, frame 30 and the last frame.
Each keyframe needs a different blue scribble and
then we can create a shape tween on the timeline.
This creates a nice shifting animation that
resembles an electrical spark.




An “Actionscript” layer should then be
created above this layer and a keyframe should
be added to the last frame. The Actionscript in
the screenshot should then be added to the
keyframe.

This script continues the cursor animation and sends the main timeline back to the
first keyframe we named “Start”.



The Flash side of this tutorial is now complete.
The slider mini-game should now work perfectly,
so give it a test to create the .swf. A test in the
“Scaleform GFX Launcher” is also
recommended to see if the images will appear in
UDK and the FSCommands activate properly.




With this done, we can now move on to the UDK side of this tutorial.




                                            8
Getting Started in UDK




To continue this tutorial, we will use the UDK map files in the copied
“Scaleform_UDK_Maps” folder. The “Slider_Tutorial_Start.udk” map will be used
for this tutorial, but the user can view a completed version in the
“Slider_Tutorial_End.udk” map for reference.



                                  Once the “Slider_Tutorial_Start.udk” map is
                                  opened, you can see that it is made up of two
                                  rooms. The small room is where we will setup
                                  the mini-game on the control console to open
                                  the door and a level complete script is already
                                  added past the door.



                                  The first task is to set a start “Trigger” next to
                                  the power console asset, place a “Player
                                  Start” in the small room and convert the door
                                  asset into a “Mover” asset, so it can be
                                  animated later.




                                      9
Kismet Scripting Begins
Now opening Kismet, a “Slider Mini-Game” box is set for
the player to place their kismet script.



                  We need to add the “Touch Trigger” and “Use Trigger”, both
                  with an unlimited max trigger count. A “Matinee” cutscene also
                  needs to be created for the door opening.




                            Next we should add a “Toggle” and wire both triggers
                            to the event connector, so we can later disable the
                            triggers. The used trigger should be connected to the
                            turn off connector of the toggle.




                            The purpose of the touch trigger is to inform the player
                            of the interaction, so we will want to connect a “Play
                            Announcement” node with the message “Hack
                            Console (Press E)”.




                            We also need to make a “Toggle Cinematic Mode”,
                            which we need to connect to the used trigger to lock
                            the player during the mini-game.




                                        10
Kismet Scripting Continued
At this point the user should import .swf created from the
“Slider_Start.fla” file into UDK using the content browser. A
package called “Scaleform_Flash” will then be created from
the folder structure.




                             Here we can now communicate with the .swf from the
                             package. To do this we need to add an
                             “openGFXmovie” node and a “closeGFXmovie”
                             node.




                             The openGFXmovie node needs to be connected to
                             the closeGFXmovie node, using a “Variable” wiring
                             them both by their “Movie Player” connectors.




The .swf then needs to be applied to the “Movie”
property for the openGFXmovie and the variable
connected to the “Movie Player” connecters.




The openGFXmovie node should then be wired
into the used trigger to activate the mini-game.
The closeGFXmovie node needs to be wired to the
toggle cinematic mode to turn it off, so the player
can move when the mini-game closes.




                                         11
Kismet FSCommands
We can now reference the FSCommands we made in the .swf file earlier by creating
FSCommand nodes.


                          Three “FSCommand” nodes need to be created and linked
                          to the .swf in the “Movie” property. The nodes then need to
                          be named in the properties. The first should be named
                          “Unlocked”, the second should be named “Alarm” and
                          the last should be named “Buzzed”.


The “Unlocked” and “Alarm” FSCommands need to be wired
to the closeGFXmovie node, to end the mini-game once the
green and red area is selected in the mini-game.

The “Unlocked” FSCommand also needs to be wired to the
open door animation to complete the mini-game objective.


                          The “Alarm” FSCommand should be wired to the toggle to
                          turn the trigger back on, because the red area simply closes
                          the mini-game.



The “Buzzed” FSCommand then needs to hooked up to a
“Modify Health” node to lower the player health by 30 each time
the orange area is selected. This will modify the player health and
continue the animation. Now need to close it when the player dies.


To do this we need to add an “Attach to Event”
node and wire a “Death” event node to it. An
investigator “Variable” from the used trigger should
be hooked to the modify health target and the attach
event attachee. The death node should then be
wired to the closeGFXmovie and the toggle, to turn
the triggers back on.

This is to ensure that once the used trigger is
activated, the user will be the recipient of the modify
health and attached to closing the .swf file once the
player dies. It also allows the player to retry the
mini-game after death.


                                           12
Kismet Final Touches




Finally we can add “Sound” nodes and tweak the timing using “Delays”. With this
done, the mini-game is setup completely. Now the level should then be “fully rebuilt
and tested”.




                                         13
Tutorial Completed




This Slider tutorial is now “Complete” and you should now fully understand how to
implement your own mini-game. You should also now be able to implement your own
rendition of this timer game and implement the Actionscript functions used in this
tutorial.




You should now continue to “Tutorial Part 2” or look at all three tutorials compiled
together, in the example map “MiniGameLevel_Demo.udk”. It can be found in the
“Level Example” folder, in the “Tutorial CD Files” folder.



                                         14

More Related Content

Similar to Scaleform Mini-Games Tutorial 1/3

Scaleform Mini-Games Tutorial 3/3
Scaleform Mini-Games Tutorial 3/3Scaleform Mini-Games Tutorial 3/3
Scaleform Mini-Games Tutorial 3/3Reese Mills
 
Scaleform Mini-Games Tutorial 2/3
Scaleform Mini-Games Tutorial 2/3Scaleform Mini-Games Tutorial 2/3
Scaleform Mini-Games Tutorial 2/3Reese Mills
 
Unity3d scripting tutorial
Unity3d scripting tutorialUnity3d scripting tutorial
Unity3d scripting tutorialhungnttg
 
How tomakea gameinunity3d
How tomakea gameinunity3dHow tomakea gameinunity3d
How tomakea gameinunity3dDao Tung
 
controlling_animations
controlling_animationscontrolling_animations
controlling_animationstutorialsruby
 
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter boardLab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter boardVincent Claes
 
Desenvolva um game para android ou iPhone
Desenvolva um game para android ou iPhoneDesenvolva um game para android ou iPhone
Desenvolva um game para android ou iPhoneTiago Oliveira
 
What the Unity engine documentation does not tell you?
What the Unity engine documentation does not tell you?What the Unity engine documentation does not tell you?
What the Unity engine documentation does not tell you?Łukasz Stępniak
 
Rocket Editor (Recovered).pptx
Rocket Editor (Recovered).pptxRocket Editor (Recovered).pptx
Rocket Editor (Recovered).pptxSkyknightBeoulve1
 
Game Development Session - 3 | Introduction to Unity
Game Development Session - 3 | Introduction to  UnityGame Development Session - 3 | Introduction to  Unity
Game Development Session - 3 | Introduction to UnityKoderunners
 
ontents · Introduction· Objectives·.docx
ontents  ·      Introduction·      Objectives·.docxontents  ·      Introduction·      Objectives·.docx
ontents · Introduction· Objectives·.docxcherishwinsland
 
Introduction to html5 game programming with impact js
Introduction to html5 game programming with impact jsIntroduction to html5 game programming with impact js
Introduction to html5 game programming with impact jsLuca Galli
 
1 of 6 LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
1 of 6  LAB 5 IMAGE FILTERING ECE180 Introduction to.docx1 of 6  LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
1 of 6 LAB 5 IMAGE FILTERING ECE180 Introduction to.docxmercysuttle
 
Quick Step by Step Flash Tutorial
Quick Step by Step Flash TutorialQuick Step by Step Flash Tutorial
Quick Step by Step Flash TutorialSu Yuen Chin
 
Application of Google Earth Engine in Open NAPs
Application of Google Earth Engine in Open NAPsApplication of Google Earth Engine in Open NAPs
Application of Google Earth Engine in Open NAPsNAP Events
 
Throughout the semester, we have been working on command line applic.pdf
Throughout the semester, we have been working on command line applic.pdfThroughout the semester, we have been working on command line applic.pdf
Throughout the semester, we have been working on command line applic.pdfbirajdar2
 

Similar to Scaleform Mini-Games Tutorial 1/3 (20)

Scaleform Mini-Games Tutorial 3/3
Scaleform Mini-Games Tutorial 3/3Scaleform Mini-Games Tutorial 3/3
Scaleform Mini-Games Tutorial 3/3
 
Scaleform Mini-Games Tutorial 2/3
Scaleform Mini-Games Tutorial 2/3Scaleform Mini-Games Tutorial 2/3
Scaleform Mini-Games Tutorial 2/3
 
Unity3d scripting tutorial
Unity3d scripting tutorialUnity3d scripting tutorial
Unity3d scripting tutorial
 
How tomakea gameinunity3d
How tomakea gameinunity3dHow tomakea gameinunity3d
How tomakea gameinunity3d
 
controlling_animations
controlling_animationscontrolling_animations
controlling_animations
 
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter boardLab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
 
a3.pdf
a3.pdfa3.pdf
a3.pdf
 
Desenvolva um game para android ou iPhone
Desenvolva um game para android ou iPhoneDesenvolva um game para android ou iPhone
Desenvolva um game para android ou iPhone
 
What the Unity engine documentation does not tell you?
What the Unity engine documentation does not tell you?What the Unity engine documentation does not tell you?
What the Unity engine documentation does not tell you?
 
Rocket Editor (Recovered).pptx
Rocket Editor (Recovered).pptxRocket Editor (Recovered).pptx
Rocket Editor (Recovered).pptx
 
Game Development Session - 3 | Introduction to Unity
Game Development Session - 3 | Introduction to  UnityGame Development Session - 3 | Introduction to  Unity
Game Development Session - 3 | Introduction to Unity
 
Android animation in android-chapter17
Android animation in android-chapter17Android animation in android-chapter17
Android animation in android-chapter17
 
Presentación Unity
Presentación UnityPresentación Unity
Presentación Unity
 
ontents · Introduction· Objectives·.docx
ontents  ·      Introduction·      Objectives·.docxontents  ·      Introduction·      Objectives·.docx
ontents · Introduction· Objectives·.docx
 
Introduction to html5 game programming with impact js
Introduction to html5 game programming with impact jsIntroduction to html5 game programming with impact js
Introduction to html5 game programming with impact js
 
1 of 6 LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
1 of 6  LAB 5 IMAGE FILTERING ECE180 Introduction to.docx1 of 6  LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
1 of 6 LAB 5 IMAGE FILTERING ECE180 Introduction to.docx
 
Apps in a Flash HCI
Apps in a Flash HCIApps in a Flash HCI
Apps in a Flash HCI
 
Quick Step by Step Flash Tutorial
Quick Step by Step Flash TutorialQuick Step by Step Flash Tutorial
Quick Step by Step Flash Tutorial
 
Application of Google Earth Engine in Open NAPs
Application of Google Earth Engine in Open NAPsApplication of Google Earth Engine in Open NAPs
Application of Google Earth Engine in Open NAPs
 
Throughout the semester, we have been working on command line applic.pdf
Throughout the semester, we have been working on command line applic.pdfThroughout the semester, we have been working on command line applic.pdf
Throughout the semester, we have been working on command line applic.pdf
 

Recently uploaded

Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 

Recently uploaded (20)

Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 

Scaleform Mini-Games Tutorial 1/3

  • 2. Creating a Slider Mini-Game in UDK Replicate an often used gameplay mechanic, used in games like Bioshock! These tutorials are recommended for users that are familiar with UDK and Adobe Flash to an intermediate level. Also it is recommended that users have some knowledge of how to setup Scaleform in UDK. If unfamiliar with Scaleform, it is recommended to the user to at least complete the first two Scaleform tutorials by Mathew Doyle on the following link: http://gameware.autodesk.com/scaleform/support/documentation These tutorials show you how to install the Scaleform GFX previewer in Adobe Flash, so you can test your .swf files to see if they would work in UDK. They also show you what settings need to be adjusted for .swf compatibility and how to use custom images. 2
  • 3. Setting Up The Tutorial Files To start these tutorials, the user first needs to open the “Tutorial CD Files” folder on the supplied disc and access the “Tutorial_Files” folder. This folder contains the flash files and UDK maps we require throughout these tutorials. Alternatively, you can download these folders from the following link: http://www.gamefront.com/files/21548379/Tutorial+CD+Files.rar The “Scaleform_Flash” folder needs to be copied and pasted to the following directory: [UDKUDK-2011-10UDKGameFlash] The “Scaleform_UDK_Maps” folder needs to be copied and pasted to the following directory: [UDKUDK-2011-10UDKGameContentMaps] To start this tutorial, we will use the files in the “Slider” folder in the copied “Scaleform_Flash” folder. Here we will use the “Slider_Start.fla” for this tutorial, but the user can view a completed version in the “Slider_End.fla” for reference. 3
  • 4. Getting Started In Flash After opening “Slider_Start.fla”, you can see that the image files “Hacking_Unlocked.png”, “Hacking_Shocked.png”, “Hacking_Alarm.png”, “Hacking.png” and “Cursor.png” has already been imported into the Library. The layers have also already been named. Firstly the four hacking image files need to be placed on each of the four keyframes on the “Background Image” layer. Place the “Hacking.png” on the first keyframe, “Hacking_Unlocked.png” on the second keyframe, “Hacking_Alarm.png” on the third keyframe and “Hacking_Shocked.png” on the last keyframe. Make sure they are positioned and scaled the same. Next the “Cursor.png” should be placed on the “Cursor” layer keyframe. It should be scaled to the appropriate size and be rotated to the start position with the pivot moved to the center of the screw image. Next on the “Actionscript” Layer, we want to name each keyframe in the properties frame name, so we can reference these frames using Actionscript later. The first keyframe should be named “Start”, the second should be named “Green”, the third should be named “Red” and the last should be named “Yellow”. Now on the keyframe in the “Cursor” layer, we want to turn the image into a graphic by pressing F8 to “Convert to Symbol”. We then want to repeat this method to place the graphic in a movieclip. 4
  • 5. Cursor Animation Now we want to name the movieclip “Cursor_MC” in the properties so we can control this movieclip later using Actionscript. Inside the movieclip, we need to extend the timeline to 122 frames on the “Animation” layer and a keyframe should then be made on frame 59 and the last frame. An Actionscript layer should also be created on the layer above. The first and last keyframe graphic should both be identical pointing at the starting position to the right side. The second keyframe image should be rotated to the end position to the left. Now a classic tween should be made to the timeline to create the looping animation of the cursor sliding back and forth. Now every frame on the “Actionscript” layer should be keyframed and the Actionscript in the screenshot should be added to them. This script makes the cursor stop when the “E Key” is pressed and the main timeline will stop on the keyframe we named "Green". Now watching the cursor animation, each keyframe should be selected and the script name “Green” should be renamed to “Red” when the cursor hovers over the red areas and “Yellow” when the cursor hovers over the yellow areas. This will ensure that the main timeline will play the correct outcome when the “E Key” is pressed during the animation. 5
  • 6. Main Timeline Actionscript We now need to add the script functions to the keyframes on the “Actionscript” layer on the main timeline. Now the first frame should have a “stop();” script and the following three should have the Actionscript in the screenshots applied to them. The second keyframe needs the “Unlocked” fscommand. The third keyframe needs the “Alarm” fscommand. The last keyframe needs the “Buzzed” fscommand. This script stops the main timeline and the FSCommands are uniquely named to allow us to reference them in UDK to activate functions. 6
  • 7. Success and Failure Feedback We now need to add the feedback animations for the cursor stopping in the Green and Red areas. So on the second keyframe on the “Screen Animations” layer, we need to create a green square with the dimensions of 1280x720. It should then be placed at the centre of the screen and turned into a graphic. After being turned into a graphic, it then needs to be turned into a movieclip. Within the movieclip we should name the layer “Animation” and extend the timeline to 28 frames. A keyframe should be made on frame 14 and the last frame. An “Actionscript” layer should also be created above with a keyframe at the end of the timeline with a “stop();” Actionscript applied to it. The “Alpha” “Colour Effect” should then be used on all three keyframes to make the first and last keyframe invisible. The timeline then needs to be turned into a classic tween to create our green flash fade animation. This should then be repeated for the third keyframe on the “Screen Animations” layer in the main timeline. A red square should be used for a red flash fade animation. 7
  • 8. Buzzed Feedback The last keyframe on the “Screen Animations” layer should have an electrical shock animation. To do this we need to scribble a blue electrical effect and turn it into a movieclip. Inside the movieclip the main timeline needs to be extended to 41 frames and the layer should be called “Animation”. A key frame should then be added to frame 16, frame 30 and the last frame. Each keyframe needs a different blue scribble and then we can create a shape tween on the timeline. This creates a nice shifting animation that resembles an electrical spark. An “Actionscript” layer should then be created above this layer and a keyframe should be added to the last frame. The Actionscript in the screenshot should then be added to the keyframe. This script continues the cursor animation and sends the main timeline back to the first keyframe we named “Start”. The Flash side of this tutorial is now complete. The slider mini-game should now work perfectly, so give it a test to create the .swf. A test in the “Scaleform GFX Launcher” is also recommended to see if the images will appear in UDK and the FSCommands activate properly. With this done, we can now move on to the UDK side of this tutorial. 8
  • 9. Getting Started in UDK To continue this tutorial, we will use the UDK map files in the copied “Scaleform_UDK_Maps” folder. The “Slider_Tutorial_Start.udk” map will be used for this tutorial, but the user can view a completed version in the “Slider_Tutorial_End.udk” map for reference. Once the “Slider_Tutorial_Start.udk” map is opened, you can see that it is made up of two rooms. The small room is where we will setup the mini-game on the control console to open the door and a level complete script is already added past the door. The first task is to set a start “Trigger” next to the power console asset, place a “Player Start” in the small room and convert the door asset into a “Mover” asset, so it can be animated later. 9
  • 10. Kismet Scripting Begins Now opening Kismet, a “Slider Mini-Game” box is set for the player to place their kismet script. We need to add the “Touch Trigger” and “Use Trigger”, both with an unlimited max trigger count. A “Matinee” cutscene also needs to be created for the door opening. Next we should add a “Toggle” and wire both triggers to the event connector, so we can later disable the triggers. The used trigger should be connected to the turn off connector of the toggle. The purpose of the touch trigger is to inform the player of the interaction, so we will want to connect a “Play Announcement” node with the message “Hack Console (Press E)”. We also need to make a “Toggle Cinematic Mode”, which we need to connect to the used trigger to lock the player during the mini-game. 10
  • 11. Kismet Scripting Continued At this point the user should import .swf created from the “Slider_Start.fla” file into UDK using the content browser. A package called “Scaleform_Flash” will then be created from the folder structure. Here we can now communicate with the .swf from the package. To do this we need to add an “openGFXmovie” node and a “closeGFXmovie” node. The openGFXmovie node needs to be connected to the closeGFXmovie node, using a “Variable” wiring them both by their “Movie Player” connectors. The .swf then needs to be applied to the “Movie” property for the openGFXmovie and the variable connected to the “Movie Player” connecters. The openGFXmovie node should then be wired into the used trigger to activate the mini-game. The closeGFXmovie node needs to be wired to the toggle cinematic mode to turn it off, so the player can move when the mini-game closes. 11
  • 12. Kismet FSCommands We can now reference the FSCommands we made in the .swf file earlier by creating FSCommand nodes. Three “FSCommand” nodes need to be created and linked to the .swf in the “Movie” property. The nodes then need to be named in the properties. The first should be named “Unlocked”, the second should be named “Alarm” and the last should be named “Buzzed”. The “Unlocked” and “Alarm” FSCommands need to be wired to the closeGFXmovie node, to end the mini-game once the green and red area is selected in the mini-game. The “Unlocked” FSCommand also needs to be wired to the open door animation to complete the mini-game objective. The “Alarm” FSCommand should be wired to the toggle to turn the trigger back on, because the red area simply closes the mini-game. The “Buzzed” FSCommand then needs to hooked up to a “Modify Health” node to lower the player health by 30 each time the orange area is selected. This will modify the player health and continue the animation. Now need to close it when the player dies. To do this we need to add an “Attach to Event” node and wire a “Death” event node to it. An investigator “Variable” from the used trigger should be hooked to the modify health target and the attach event attachee. The death node should then be wired to the closeGFXmovie and the toggle, to turn the triggers back on. This is to ensure that once the used trigger is activated, the user will be the recipient of the modify health and attached to closing the .swf file once the player dies. It also allows the player to retry the mini-game after death. 12
  • 13. Kismet Final Touches Finally we can add “Sound” nodes and tweak the timing using “Delays”. With this done, the mini-game is setup completely. Now the level should then be “fully rebuilt and tested”. 13
  • 14. Tutorial Completed This Slider tutorial is now “Complete” and you should now fully understand how to implement your own mini-game. You should also now be able to implement your own rendition of this timer game and implement the Actionscript functions used in this tutorial. You should now continue to “Tutorial Part 2” or look at all three tutorials compiled together, in the example map “MiniGameLevel_Demo.udk”. It can be found in the “Level Example” folder, in the “Tutorial CD Files” folder. 14