1# package Mrsmith;
2
3
4require 'DataHelper.pl';
5use strict;
6
7sub LoadMrsmith
8{
9	my ( @Frames, %FrameLookup, %Frames, %States, %Shorthands,
10		$Doodad, $Con, $Con2,
11		@States1,
12		$framedesc, $key, $value, $framename, $nextst, $st, $lastchar, $nextchar, $codename );
13
14$codename = 'Mrsmith';
15
16@Frames = LoadFrames( "$codename.dat.txt", 150, 70 );
17%FrameLookup = CreateFrameLookup( scalar @Frames -1,
18'start', 10,
19'stand', 2,
20'walk', 6,
21'turn', 7,
22'falling', 6,
23'laying', 1,
24'getup', 12,
25'hurt', 5,
26'won', 25,
27'block', 4, 'dummyc', 2,
28'dummya', 4, 'kneeling', 4, 'dummyb', 1,
29'onknees', 3,
30'kneelingpunch', 4, 'dummyknp', 2,
31'kneelingkick', 4, 'dummyknk', 4,
32'kneelingpunched', 6,
33'kneelingkicked', 8,
34'fun', 27,
35'threat', 7,
36'highpunch', 5,
37'lowpunch', 9,
38'highkick', 8,
39'lowkick', 7,
40'groinkick', 6,
41'kneekick', 5,
42'elbow', 4,
43'spin', 7,
44'sweep', 8,
45'grenade', 9,
46'uppercut', 11,
47'throw', 13,
48'highpunched', 9,
49'lowpunched', 7,
50'groinkicked', 7,
51'swept', 12,
52'thrown', 7,
53'speciala', 7,
54'specialb', 7,
55);
56
57
58
59$Con = {
60'forw'=>'Walk',
61'back'=>'Back',
62'jump'=>'Jump',
63'jumpfw'=>'JumpFW',
64'jumpbw'=>'JumpBW',
65'block'=>'Block',
66'down'=>'Kneeling',
67
68'hpunch'=>'HighPunch',
69'lpunch'=>'LowPunch',
70'hkick'=>'HighKick',
71'lkick'=>'LowKick',
72'lkickBF'=>'GroinKick',
73'lkickF'=>'KneeKick',
74'hpunchD'=>'Uppercut',
75'hpunchF'=>'Elbow',
76'hkickB'=>'Spin',
77'lkickB'=>'Sweep',
78
79'lpunchBD'=>'Grenade',
80'hpunchFF'=>'SpecPunch',
81};
82
83
84$Con2 = {
85'lkick'=>'KneelingKick',
86'hkick'=>'KneelingKick',
87'hpunch'=>'KneelingUppercut',
88'lpunch'=>'KneelingPunch',
89};
90
91
92
93@States1 = (
94# 1. BASIC MOVES
95
96{ 'N'=>'Start',			'DEL'=>7,	'S'=>'+start', 'DEL6'=>12, },
97{ 'N'=>'Stand',			'DEL'=>7,	'S'=>'+stand,-stand', 'CON'=>$Con, 'SITU'=>'Ready' },
98{ 'N'=>'Turn',			'DEL'=>5,	'S'=>'+turn',	'TURNN'=>1, },
99{ 'N'=>'Hurt',			'DEL'=>8,	'S'=>'+hurt,-hurt' },
100{ 'N'=>'Won',			'DEL'=>10,	'S'=>'+won',	'NEXTSTN'=> 'Won2' },
101{ 'N'=>'Won2',			'DEL'=>1000,'S'=>'won n',	'NEXTST'=>'Won2', },
102{ 'N'=>'Fun',			'DEL'=>5,	'S'=>'+fun', 'CON'=>$Con, 'DEL20'=> 16, 'SITU'=>'Ready' },
103{ 'N'=>'Threat',		'DEL'=>7,	'S'=>'+threat,-threat', 'CON'=>$Con, 'SITU'=>'Ready' },
104WalkingFrames( \%FrameLookup, \@Frames, 0, 8, $Con ),
105BlockStates( FindLastFrame( \%FrameLookup, 'block' ), 5 ),
106KneelingStates( FindLastFrame( \%FrameLookup, 'kneeling' ),
107	FindLastFrame( \%FrameLookup, 'onknees' ), 7, $Con2 ),
108JumpStates( \%FrameLookup,
109	{'lkick'=>'JumpKick', 'hkick'=>'JumpKick',
110	'lpunch'=>'JumpPunch', 'hpunch'=>'JumpPunch'} ),
111
112# 2. OFFENSIVE MOVES
113
114{ 'N'=>'KneelingPunch',	'DEL'=>5,	'S'=>'+kneelingpunch,-kneelingpunch', 'SITU'=>'Crouch',
115	'HIT'=>'Hit', 'NEXTSTN'=>'Onknees' },
116{ 'N'=>'KneelingKick',	'DEL'=>5,	'S'=>'+kneelingkick,-kneelingkick', 'SITU'=>'Crouch',
117	'HIT'=>'Hit', 'NEXTSTN'=>'Onknees' },
118{ 'N'=>'KneelingUppercut','DEL'=>5,	'S'=>'kneeling 3-2,uppercut 2-n',
119	'HIT'=>'Uppercut' },
120{ 'N'=>'HighPunch',		'DEL'=>12,	'S'=>'+highpunch',
121	'HIT'=>'Highhit' },
122{ 'N'=>'LowPunch',		'DEL'=>7,	'S'=>'+lowpunch',
123	'HIT'=>'Hit' },
124{ 'N'=>'HighKick',		'DEL'=>7,	'S'=>'highkick 1-5, highkick 5-1',
125	'HIT'=>'Hit' },
126{ 'N'=>'LowKick',		'DEL'=>7,	'S'=>'lowkick 1-4, lowkick 4-1',
127	'HIT'=>'Leghit' },
128{ 'N'=>'GroinKick',		'DEL'=>10,	'S'=>'+groinkick,-groinkick', 'DEL3'=>'12',
129	'HIT'=>'Groinhit' },
130{ 'N'=>'KneeKick',		'DEL'=>8,	'S'=>'kneekick 5-3, kneekick 3-5',
131	'HIT'=>'Hit' },
132{ 'N'=>'Elbow',			'DEL'=>8,	'S'=>'+elbow',
133	'HIT'=>'Highhit' },
134{ 'N'=>'Spin',			'DEL'=>8,	'S'=>'+spin',
135	'HIT'=>'Hit' },
136{ 'N'=>'Sweep',			'DEL'=>7,	'S'=>'+sweep',
137	'HIT'=>'Hit' },
138{ 'N'=>'Grenade',		'DEL'=>5,	'S'=>'+grenade,-grenade',
139	'DEL12'=>15, 'DOODAD'=>'ZoliShot' },
140{ 'N'=>'Uppercut',		'DEL'=>7,	'S'=>'+uppercut',
141	'HIT'=>'Uppercut' },
142{ 'N'=>'Throw',			'DEL'=>8,	'S'=>'+throw' },
143
144
145#{ 'N'=>'KillKenny',		'DEL'=>5,	'S'=>'+killkenny', },
146#{ 'N'=>'SpecPunch',		'DEL'=>6,	'S'=>'+specpunch,-specpunch',
147#	'HIT'=>'Uppercut', },
148
149
150# 3. HURT MOVES
151
152{ 'N'=>'Falling',		'DEL'=>12,	'S'=>'+falling, falling 5',
153	'DELN'=>500, 'NEXTN'=>'Laying', 'SITU'=>'Falling', },
154{ 'N'=>'Laying',		'DEL'=>1000,'S'=>'laying n',
155	'SITU'=>'Falling' },
156{ 'N'=>'Getup',			'DEL'=>7,	'S'=>'+getup',
157	'SITU'=>'Falling',
158	'CON5'=>{'down'=>'Onknees'},
159	'CON6'=>{'down'=>'Onknees'},
160},
161{ 'N'=>'Dead',			'DEL'=>10000, 'S'=>'laying 1',
162	'SITU'=>'Falling', 'NEXTST'=>'Dead' },
163
164{ 'N'=>'Swept',			'DEL'=>8,	'S'=>'+swept' },
165
166{ 'N'=>'KneelingPunched', 'DEL'=>5,	'S'=>'+kneelingpunched',
167	'SITU'=>'Crouch', 'NEXTSTN'=>'Onknees' },
168{ 'N'=>'KneelingKicked', 'DEL'=>5,	'S'=>'+kneelingkicked',
169	'SITU'=>'Crouch', 'NEXTSTN'=>'Onknees' },
170
171{ 'N'=>'HighPunched',	'DEL'=>8,	'S'=>'+highpunched' },
172{ 'N'=>'LowPunched',	'DEL'=>5,	'S'=>'+lowpunched' },
173{ 'N'=>'GroinKicked',	'DEL'=>8,	'S'=>'+groinkicked', 'DEL3'=>16 },
174{ 'N'=>'Thrown',		'DEL'=>5,	'S'=>'+thrown' },
175
176{ 'N'=>'SpecPunch',		'DEL'=>7,	'S'=>'+specialb,-specialb',
177	'HIT'=>'Uppercut', }
178);
179
180
181
182# 2. CREATE STATES
183
184foreach $framedesc (@States1)
185{
186	AddStates( \%States, \%FrameLookup, $framedesc );
187}
188
189
190
191# Automatically add NEXTST for states which don't have one.
192
193FixStates( \%FrameLookup, \%States );
194
195TravelingStates( \%FrameLookup, \@Frames, \%States, "falling", 0, 0 );
196TravelingStates( \%FrameLookup, \@Frames, \%States, "won", 0, 0 );
197
198%States = ( FindShorthands( \%States ), %States );
199
200# %::UPiStates = %States;
201# @::UPiFrames = @Frames;
202
203::RegisterFighter( {
204	'ID'			=> 103,
205	'GENDER'		=> 1,
206	'DATAVERSION'	=> 1,
207	'STARTCODE'		=> sub {},
208	'FRAMES'		=> \@Frames,
209	'STATES'		=> \%States,
210	'CODENAME'		=> $codename,
211	'DATASIZE'		=> 6259470,
212
213	    'NAME'  =>'Mr. Smith',
214        'TEAM'  =>'Spontán',
215        'STYLE' =>'beer-fu',
216        'AGE'   =>'23',
217        'WEIGHT'=>'80kg',
218        'HEIGHT'=>'185cm',
219        'SHOE'  =>'44',
220        'STORY' =>
221'Mr. Smith comes from the shadows, where he and his evil, disgraced family of de
222mons resided for such a dementing long time. Now, as the last member of his inge
223nious breed, Mr. Smith takes on the tournament to reclaim every of all possessio
224ns his family lost under the dark ages of The Returning Of The Good Wizards. Uns
225toppable and strong enough to beat a Black Dragon by his own hands, Mr. Smith se
226eks trouble wherever he thinks there could be one.',
227
228        'EMAIL' =>'zaphir@sch.bme.hu',
229
230} );
231
232}
233
234LoadMrsmith();
235
236return 1;
237
238