View Single Post
  #742  
Old 12-17-2002, 07:18 PM
xxxsaint's Avatar
xxxsaint xxxsaint is offline
 
Join Date: Jun 2002
Posts: 185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I was able to get this action-script info out of the snake game :

Quote:

// Action script...

// [Action in Frame 1]
ifFrameLoaded(45)
{
gotoAndStop(4);
} // End of ifFrameLoad

// [Action in Frame 3]
gotoAndPlay(1);

// [Action in Frame 4]
score = 0;
stop();

// [Action in Frame 37]
Snake._visible = false;
score = 0;
tail = 1;
head = 3;
xv = 0;
yv = 1;
x = 160;
y = 100;
eaten = true;
extend = false;
makeMove = false;

// [Action in Frame 38]
x = x + 10 * xv;
y = y + 10 * yv;
head++;
duplicateMovieClip("Snake", head, 16384 + head);
setProperty(head, _x, x);
setProperty(head, _y, y);
if (eval("s_" + x + "_" + y) || x < 20 || x > 300 || y < 20 || y > 290)
{
gotoAndStop(43);
} // end if
eval("s_" + x + "_" + y) = true;
if (extend)
{
extend = false;
score = score + level;
}
else
{
eval("s_" + tail._x + "_" + tail._y) = false;
removeMovieClip(tail);
tail++;
} // end if
if (Food._x == x && Food._y == y)
{
eaten = true;
extend = true;
} // end if
if (eaten)
{
Sound.gotoAndPlay(2);
eaten = false;
tellTarget("Food")
{
_x = 10 * (random(28) + 2)
_y = 10 * (random(27) + 2)
} // end of tellTarget
} // end if
makeMove = false;

// [Action in Frame 39]
if (level == 3)
{
gotoAndPlay(38);
} // end if

// [Action in Frame 40]
if (level == 2)
{
gotoAndPlay(38);
} // end if

// [Action in Frame 41]
gotoAndPlay(38);

// [Action in Frame 43]
for (temp = head; tail < temp + 1; temp--)
{
setProperty(temp, _alpha, 33);
} // end of for
vpaver = "100B";
snakescore = score;
action = "gameover";
game = gamename;
score_loc = location + "/proarcade.php";
getURL(score_loc, "_self", "POST");

// [Action in Frame 44]
rank = 0;
Input._visible = false;
scoresURL = "snakescores.txt";
loadMovie(scoresURL, "Scores");
stop();

// [Action in Frame 45]
if (level == 3)
{
l = "p";
}
else if (level == 2)
{
l = "w";
}
else
{
l = "s";
} // end if
for (i = 1; i < 11; i++)
{
if (Scores["s" + l + i] < score)
{
rank = i;
i = 11;
} // end if
} // end of for
if (rank)
{
for (i = 9; i >= rank; i--)
{
Scores["s" + l + Number(i + 1)] = Scores["s" + l + i];
Scores["n" + l + Number(i + 1)] = Scores["n" + l + i];
} // end of for
Scores["s" + l + rank] = score;
Scores["n" + l + rank] = "";
tellTarget("Input")
{
_y = 20 * _root.rank + 59.500000
_x = 100 * _root.level - 45.500000
_visible = true
} // end of tellTarget
HS.gotoAndStop(3);
}
else
{
HS.gotoAndStop(2);
} // end if
stop();
now , being a flash rookie - is this enough info to be able to start adding our own games because I really want to add flash casino games in there , I've posted that all over these forums with no luck.
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01075 seconds
  • Memory Usage 1,781KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_quote
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete