Actionscript :: Add Score Tracker In An If / Else Statement For Multiple Choice Game?

Dec 12, 2010

Where and how I'd put the rest for the score tracker? I'm going to be making 3 of these multiple choice questions, so what would be the best way I lay that out and transition from one question to another?[code]...

View 1 Replies


Similar Posts:


Multiple Choice Game Containing Questions And The Answers?

Apr 22, 2009

I have a project that i want to make which is a Multiple choice game containing questions and the answers is four pictures when you click on the right answer you move to next question when your are wrong a wrong sign appears i have zero knowladge about flash but i thought this is similar to Geo Challenge in facebook ,,Right ?? what software to download ? any tutorials online ?

View 4 Replies

ActionScript 3.0 :: Tracking Time - Count The Seconds Passed While Playing The Game And Gives A Bonus Multiplier To The Current Score When The Game Ends?

Mar 15, 2009

Is there a way to get this code to work? It's meant to count the seconds passed while playing the game and gives a bonus multiplier to the current score when the game ends. I don't know how to get the returned value to combine it into the multiplier int variable. Is there any way to get this code to work or is it completely wrong?

View 11 Replies

Actionscript 3 :: Multiple Dynamic Text Score Display - Modifying Each Text One After Another And Incrementing The Score By A Certain Number

Feb 23, 2011

I have a result screen that shows bonus points and such. I want each text field to increment one after another and also have it increment by a certain amount each frame. Result Screen pops up. First is the player score check the player score, is it more than the score we want to display if the player score is greater than the player display score by 100 increase the player display score by 100 if the player score is greater than the player display score by 10 increase the player display score by 10 else increase the player display score by 1 when finished move to the next score...and so on. I have thought of using timers to move from one score to the next, but not being in an Event.ENTER_FRAME it only does one if then moves to the next one.

Also the if statement for incrementing the score looks ridiculous and I'm thinking there has to be a better way to do it. I was thinking of making it a separate function but then I wouldn't know what to return, or how to return it so it looks like its increasing and not just showing the total number instantly. I'll try to expand on it a little more.

View 1 Replies

ActionScript 2.0 :: Keeping Score With If Statement

Dec 15, 2010

I'm having an actionscript 2.0 problem with keeping score. I have a dynamic text box with a variable called score. I have the following action code for that variable:

_root.score = 0;

For the correct answer button I have this action:

_root.score = Number (score) +10;

This works fine to increase the score by 10 for each correct answer. The problem is that I can't get an if statement to work for when the score reaches 150 to gotoAndPlay a certain frame. I've tried various syntax, I've tried it on the action for a button and an action for the timeline with:

onRelease = function () {

(My learning game is set up to allow for users to answer up to four extra questions to reach the score of 150). Nothing has worked so far.

View 5 Replies

ActionScript 3.0 :: High Score Table Setup - If Statement With Variable

Feb 9, 2010

I am trying to get a high score table set up and I have it all working except for an if statement which decides whether to put a zero in the time or not.
ActionScript Code:
variable declared at the top
var gap:String;

This is getting data that is stored - it works fine except for the underlined "gap" - The "gap" is meant to be calling the variable which has the below if statement
ScoreInputScore.text=String(SpotTheDifferenceGame._minute)+gap+String(SpotTheDifferenceGame._second);
if (SpotTheDifferenceGame._second<10) {
gap=(":0");
} else {
gap=(":");
}

I thought by have the variable called in in the function and having the if statement with gap= it would do the specified text in the dynamic text box. When I put a trace on "gap" it traces with the correct text depending on what the number is but in my dynamic text box it displays as number null number.
// displays like this when trace put on it
:0
// displays like this in dynamic text box
2null02

View 1 Replies

IDE :: XML Flash Quiz (Multiple Choice)

Jan 31, 2007

I have made a quiz from mixing and matching from various tutorials of the internet, and now want to make the questions (multiple choice) and possibly the answers appear shuffled. The xml looks like this:
<quiz>
<title>Quiz</title>
<items>
<item>
<question>In which continent is the country Japan located?</question>
<answer correct="y">Asia</answer>
<answer>Europe</answer>
<answer>Africa</answer>
<answer>America</answer>
</item>
and here is what I've got so far with the actionscript!

View 2 Replies

ActionScript 3.0 :: Add Multiple Choice Answer To An Object?

Oct 18, 2009

I have declared an array which holds an object such as:

var myArr:Array = new Array({Question: 'Primary Colors Are?'});

How can I add the multiple choices to the object These are the choices:
 
red, green, blue
orange, red, white,
purple, yellow, green,
white, black, blue
 
I certainly can create the Answers as:

var myArr:Array = new Array({ Question: 'Primary Colors Are?', Answer1: 'red, green, blue',
, Answer2: 'orange, red, white, Answer3: 'purple, yellow, green', Answer4: 'white, black, blue' });

What I would like to do is to be able to store all the answer choices within an array called AnsArr. Can I declare a new array within the same obejct such as AnsArr and push these choices to it? 

View 3 Replies

ActionScript 3.0 :: Randomize Multiple Choice Buttons

Oct 26, 2009

I want to randomly scramble 4 multiple choice buttons (assigning each of them to one of four different positions). I'm trying to (a) randomly extract an element from an array, (b) delete that element from the array, and (c) go through the same process 3 more times till I have 4 random numbers assigned to 4 separate variables. I should be able to assign the buttons to different positions after that. 

Here's the first round of what could loosely be called code:

var firstElement:Number = 0;var distList:Array = ["0", "1", "2", "3"];var distNum0:Number = 0;var distNum1:Number = 0;var distNum2:Number = 0;var distNum3:Number = 0;

[Code].....

View 9 Replies

Professional :: Multiple Choice Quiz - How To Set Correct Answer

Jul 1, 2010

I'm using CS4 and trying to create a new quiz using one of the templates.I can see how to edit it to get only Multiple Choice but I'm stuck at one thing - I can't see where to specify which choice is the correct one.

View 4 Replies

ActionScript 3.0 :: Setup A Multiple Choice Radio Button?

Jul 21, 2010

I am trying to setup a multiple choice radio button question quiz, but I'm having issues with some of the AS and was hoping some of you could assist me. I'm fairly new to ActionScript, but I'm trying to pick up quickly. The code is listed below. The lines giving errors have been increased in size.

[Code]...

View 9 Replies

ActionScript 3.0 :: Multiple Choice Question Not Displaying Answer Feedback?

Jun 9, 2011

I have a few multiple choice questions using ActionScript 3.0 that are not displaying the answer feedback when tested as a movie or published to a swf. The way the question is set up is that a learner clicks a radio button and then clicks a Check Answer button. A red X or green checkmark appears next to the selected answer choice.Incorrect/Correct feedback should then appear below the Check Answer button.Currently the Incorrect/Correct answer feedback is not appearing in the output box when published.
 
stop();
 var currBtn = "";
var currSelected:Number = 0;[code].......

View 1 Replies

ActionScript 2.0 :: Multiple Choice Quiz - Tracking All Correct Answers?

Mar 24, 2004

I am currently trying to create a multiple choice quiz. Alright, what I want to do is this - I want to create a multiple choice like this, where user click the answer and they will be linked to a feedback page, telling them what is wrong with their answer. Then they can click an "OK" button to proceed to the next scene where there will be the next qns. The reason why I am not putting all in the same scene is because I need to do up a different scenario for each of the qns.

If I were to have ten qns in one scene, I was told it is "no good" by my lecturer. At the end of the ten qns, there will be a grading of points. I want the script to be able to track all correct answers despite all qns being on different scenes. Because I want the grade to show at the evaluation scene. is it possible to capture the answer user has clicked on, store to the array, store in another array as one point if it is a correct answer and click next to go to the next scene for the 2nd qns, not next frame.

View 14 Replies

ActionScript 2.0 :: Multiple Choice Questions Where The Question Are Being Fetched From A XML File

Jul 18, 2003

Can somebody give me an example of Multiple Choice Questions, where the question are being fetched from a XML file.

View 5 Replies

[CS3] Score Counter In A Shooter Game

Nov 24, 2008

I have a simple shooting game set up. 25 monsters appear on the screen, one after another, until no monsters are left. If you hit one before it disappears, the score increases. If you don't, the score stays the same.

In the actions frame, I placed an empty dynamic text box named score, and set it equal to 0 (declared in the main actions frame). But, seeing as though the monster actions are coded into the library item itself, do I have to declare score, and the score increase there instead?

View 4 Replies

ActionScript 3.0 :: Multiple Choice Questions Quiz - Conditional Answer Checking

Jun 7, 2010

I'm working on a quiz-style piece right now and in short it's several pages of multi choice questions, each rewarding a certain point amount that is added up at the end and given specific results based on the point range scored. (i.e. 10-20 = good, 21-30 = great... etc)

For code I've stopped here:
if (answercheck == 40 - 52){
trace("Feedback: Range 40 - 52");
form.gotoAndStop(3);
form.AnswerTotal.Number = answercheck;
}

Answercheck is the var with the total points accumulated. Form is the mc with the feedback frames based on their point totals. AnswerTotal is the dynamic text box I'm trying to load the exact point total the user acquired into at the end.

View 2 Replies

Actionscript 2.0 :: Make Interactive Multiple-choice Quiz In Adobe Flash?

Aug 13, 2009

Adobe Flash also lets users make interactive Flash quiz. This tutorial will guide you how to create interactive drop-down multiple-choice quiz in Adobe Flash. This short tutorial is just a sample of the workflow you'll use while authoring in Adobe Flash CS4.

Step 1 - Create a new document

a. Choose File > New.

b. In the New Document dialog box, selcet Flash File (ActionScript 2.0) and then Click OK.

Step 2 - Document settings Right-click on the stage, selcet Document Properties, then the Document Properties dialog box appears. It displays the current Stage size setting as 550*400 pixels, and the Background color swatch is set to white. You can change the size and color of the Stage as you want.

Step 3 - Import image to the stage Choose File > Import > Import to Stage, and then select the image you want. You also could click Ctrl+R to import image.

Step 4 - Add the multiple choice question to the Stage

a. Select the Text tool (T).

b. In the Property inspector (Window > Properties), select Static Text type to specify the type of text field, and then input the question " What was Michael's first song to air on MTV? ". You also could set the font size, family and color of the text.

Step 5 - Add ComboBox component

a. Select Window > Components.

b. Double-click ComboBox in the Components panel.

c. Select the component on the Stage, and name the instance name as box in the properties panel.

Step 6 - Add answer options

a. Select Window > Component Inspector. On the Component Inspector, click data, then the Value dialog box appears.

b. Click + to add answer options, and then replace the defaultValue as answer options, here the options are: thriller, billie jean, bad and the way you make me feel. After that, click OK.
c. On the Component Inspector, click labels, then the Value dialog box appears. Please following the same steps above to add the values by adding the + button.

[code]...

If that's too complicate to you, you could choose some 3rd party quiz makers to make multiple choice quiz for you. Wondershare QuizCreator is such a good Flash quiz maker that help you create multiple Flash quiz with ease.

View 1 Replies

ActionScript 2.0 :: GAME - Submit Score Via Email?

Apr 5, 2009

I have a question which I think should be fairly simple but my AS knowledge is rather poor so i'm wondering if someone could help me out or point me in a direction to find out how to do this...

I'm playing around with a game, (skinned it and slightly modded it) and at the end I want the player to be able to enter his email and hit a "submit" button and have his score emailed to me? Is this simple?

View 1 Replies

Add Highest Score Table In My Flash Game?

Jul 27, 2009

I want to add highest score table in my flash game ? I want to upload my game to web so visitors can play on my page and see how good they were. Im working with as2

View 1 Replies

ActionScript 3.0 :: Negative Score In Catching Game?

Dec 6, 2011

I'm trying to edit the actionscript of catching game in which a object fall from top to bottom and if the catcher fail to catch the object and the object hit the bottom, the score is subtracted. [code]In addition, how do I end the game after the catcher fail to catch at least 5 objects to go to "game over" screen with final score displayed?

View 10 Replies

ActionScript 3.0 :: Score Board For A Game Show?

Jun 7, 2011

I need to create a score board for a game show at work for staff. The score board must keep score on the left and right parts of the screen. score must start as default on 0. Then every time I press for example the left arrow key the left score must increase by the value of 1 and when I press the right arrow key the left score must decrease by 1.Same goes for the right score only with differant keys example up and down keys. This sounds very simple and I managed to get it to work when I tested with only 1 score, but failed when adding the second score to the picture.

View 5 Replies

Flash :: Write Game Score In XML File?

Feb 19, 2011

I am working on a flash game which is a shooting egg game. I want to export a score(what ever it may be ) to the xml file so that using php developer can take it from there n post it to the wall just like we play games on facebook n it asks you that "Do u want to post your scores?". The variable of Dynamic text box is score.

View 1 Replies

ActionScript 2.0 :: Get The Game To Stop When It Reaches A Certain Score?

Feb 24, 2003

The game Iam busy with, it keeps score how do I get the game to stop when it reaches a certain score?

View 3 Replies

ActionScript 2.0 :: Flash8 Simple Game Score Not Working?

Mar 28, 2011

I'm following a tutorial to make a simple game. The aim of the game is for a player to evade a flying enemy ; the higher the score, the faster the enemy. The main elements in the game are the enemy the player and a score card.

However, from following the tutorial, and adding the dynamic text field etc....the score doesn't actually work.

This is the code that I was instructed to place on the first frame of the Scripts layer:

//Game Variables
enemySpeed = 5; //Set Enemy initial speed
numberEnemy = 4; //Change this to add more Enemies
score = 0; //Set initial score to 0

[Code].....

View 2 Replies

ActionScript 1/2 :: Game Score - Points To Be Time Based

Jul 18, 2009

Is there an actionscript for a point system? I want my points to be time based from this script
stop();
count = 60;
countdown = function(){count--;
if (count ==0){clearInterval(doCountdown);
gotoAndStop(11);
clearInterval(doCountdown);
}}doCountdown = setInterval(countdown, 1000);

View 5 Replies

Flash :: Sharing Game Score To Social Networks?

Jul 11, 2011

there is is simple Game ( kids multiplication ) game will be on Normal website

How I can share Game score over Social networks like Facebook without using PHP or any server-side scripting directly from Flash ?

Game is also just XML based game just in the end I want to share User score and website link to any social-network where user want

View 1 Replies

Hack A Flash Game To Increase Votes Or Score?

Nov 10, 2011

I want to know about hacking a flash game...like in a flash game how to hack to increase your votes or score ... As there are flash games in Facebook,how to hack them

View 2 Replies

ActionScript 3.0 :: Score Board For BlackJack Game Points?

Oct 25, 2011

I am creating a blackjack game and almost have it all figured out besides the scoreboard. When I win the game it adds the 25 points and when I loose it subtracts the 25 points from the starting score = 200. The problem is that if you win multiple times in a row or lose multiple times in a row the score doesn't keep adding up. It only adds or subtracts the score once. I tried using a boolean code but can't get it to work right. Now I am using this set up.

[Code]...

View 4 Replies

ActionScript 3.0 :: AS2 To AS3 Conversion / Simple Score & HitTest For Bug Splatter Game

Sep 26, 2011

Non-programmer here, struggling with having to now (finally) work in AS3.I've looked around, but can't find something similar (or as simple) as my old AS2 scoring - hitTest method was.Problem 1: my converted AS3 game does not hitTest or score.[code]I have a Dynamic text box on the stage named "scorecounter" which is now displaying "0" when the game plays. This is correct.When the gun (mouse) is clicked, we then tell the "hittest1" MC to play, which will detect hits. All Correct.[code]The hittest1 MC plays, and checks if the "cursor" MC was touching the "bug1", and tells it to animate (splat) All bug detections are listed in the hitTest frame - "bug1" through "bug30", ie. the code below x 30. This Fails - maybe because the hitTest MC lists all 30, and not all bugs are visibile at once, some are hidden until required later in the game?[code]Then on the last frame of the "bug1" MC (frame 10), it tells the score to add one. Also Fails - maybe because of errors above, nothing is being processed now.[code]

View 5 Replies

ActionScript 1/2 :: If Score Over Certain Point Next Level Button Visible In Game

Oct 2, 2009

I'm making game, where I must collect points. In end menu screen, i want that if my score's over 200, a next level button will be visible. Now it's visible every time when timer's out. I have tried this code
if (score < 200){
this.visible == false;
} else
if (score >=200){
this.visible == false;
}

View 3 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved