# beg1
if $ARGS[0] = 'start':
	cla
	*clr
	clr
	gs 'stat'
	minut += 60
	kolsorev += 1
	razdtumbler = 0
	begmon = month

	if razradbeg = 0:
		'You write in a group beginners.'

		act 'Go to the track':gt 'beg1', 'br'
	elseif razradbeg = 1:
		'You write in a group treterazryadnikov.'

		act 'Go to the track':gt 'beg1', '3'
	elseif razradbeg = 2:
		'You recorded in the second group of bits. City Championship.'

		act 'Go to the track':gt 'beg1', '2'
	elseif razradbeg = 3:
		'You recorded in the first group of bits. Championship field.'

		act 'Go to the track':gt 'beg1', '1'
	elseif razradbeg = 4:
		'You write in the CCM group. Championship region.'

		act 'Go to the track':gt 'beg1', 'kms'
	elseif razradbeg = 5:
		'You write in the group Masters of Sports. Russian Championship.'

		act 'Go to the track':gt 'beg1', 'ross'
	elseif razradbeg >= 6 and razradbeg < 16:
		'You write in the group International Master of Sports. Qualifying competition for access to the European Championship.'

		act 'Go to the track':gt 'beg1', 'kval'
	elseif razradbeg = 16:
		if razradbegK < 8:
			cla
			razradbegK = 0
			razradbeg = 6
			'You have not been qualified for the European Championship.'

			! WD: Argument is 'dressing room'
			act 'Leave':gt 'fit', 'dressing room'
		elseif razradbegK >= 8:
			cla
			razradbegK = 0
			razradbeg = 6
			'You write for the European Championship.'

			act 'Go to the track':gt 'beg1', 'evro'
		end
	end
end

if $ARGS[0] = 'br':
	cla
	beg += 1
	fat -= 10
	begplus = beg + speed + vital + rand(1, 20)
	begminus = salo/2 + rand(1, 20)
	begresult = begplus - begminus
	'<center><img src="images/etogame/begsor.jpg"></center>'
	'Women''s 400 meters race. You change clothes and go out on the track. Get up at the start. Distributed starting shot.'

	if begresult <= 0:'You barely managed to reach the finish line, what place is really there, of course you are the last.'
	if begresult > 0 and begresult < 10:'You are not bad ran for dilettante course, as ranked last 8th place.'
	if begresult >= 10 and begresult < 20:'You fought hard, but managed to take only 7 penultimate place.'
	if begresult >= 20 and begresult < 30:'You fought hard, but only managed to take 6th place.'
	if begresult >= 30 and begresult < 40:'You fought hard, but only managed to take 5th place.'
	if begresult >= 40 and begresult < 50:'You fought hard, but only managed to take 4th place.'
	if begresult >= 50 and begresult < 60:bronzebeg += 1 & money += 100 & 'You fought hard and managed to take 3rd place prize. You get a bronze medal and a prize of 100 rubles'
	if begresult >= 60 and begresult < 70:silverbeg += 1 & money += 500 & 'You fought hard and managed to take the 2nd place prize. You get a silver medal and a prize of 500 rubles'
	if begresult >= 70:razradbeg = 1 & goldbeg += 1 & money += 1000 & 'You fought hard and managed to take 1st place. You get a gold medal, a prize of 1, 000 rubles and third sports category on the run.'

	act 'Leave':gt 'fit', 'dressing room'
end

if $ARGS[0] = '3':
	cla
	beg += 1
	fat -= 10
	begplus = beg + speed + vital + rand(1, 20)
	begminus = salo/2 + rand(1, 20)
	begresult = begplus - begminus
	'<center><img src="images/etogame/begsor.jpg"></center>'
	'You change clothes and go out on the track. Get up at the start. Distributed starting shot.'

	if begresult <= 0:'You barely managed to reach the finish line, what place is really there, of course you are the last.'
	if begresult > 0 and begresult < 70:'You are not bad ran for dilettante course, as ranked last 8th place.'
	if begresult >= 70 and begresult < 80:'You fought hard, but managed to take only 7 penultimate place.'
	if begresult >= 80 and begresult < 90:'You fought hard, but only managed to take 6th place.'
	if begresult >= 90 and begresult < 100:'You fought hard, but only managed to take 5th place.'
	if begresult >= 100 and begresult < 110:'You fought hard, but only managed to take 4th place.'
	if begresult >= 110 and begresult < 120:bronzebeg += 1 & money += 500 & 'You fought hard and managed to take 3rd place prize. You get a bronze medal and a prize of 500 rubles'
	if begresult >= 120 and begresult < 130:silverbeg += 1 & money += 1000 & 'You fought hard and managed to take the 2nd place prize. You get a silver medal and a prize of 1, 000 rubles'
	if begresult >= 130:razradbeg = 2 & goldbeg += 1 & money += 2000 & 'You fought hard and managed to take 1st place. You get a gold medal, a prize of 2, 000 rubles and 2nd sports category on the run.'

	act 'Leave':gt 'fit', 'dressing room'
end

if $ARGS[0] = '2':
	cla
	beg += 1
	fat -= 10
	begplus = beg + speed + vital + rand(1, 20)
	begminus = salo/2 + rand(1, 20)
	begresult = begplus - begminus
	'<center><img src="images/etogame/begsor.jpg"></center>'
	'Women''s 400 meters race. You change clothes and go out on the track. Get up at the start. Distributed starting shot.'

	if begresult <= 0:'You barely managed to reach the finish line, what place is really there, of course you are the last.'
	if begresult > 0 and begresult < 130:'You are not bad ran for dilettante course, as ranked last 8th place.'
	if begresult >= 130 and begresult < 140:'You fought hard, but managed to take only 7 penultimate place.'
	if begresult >= 140 and begresult < 150:'You fought hard, but only managed to take 6th place.'
	if begresult >= 150 and begresult < 160:'You fought hard, but only managed to take 5th place.'
	if begresult >= 160 and begresult < 170:'You fought hard, but only managed to take 4th place.'
	if begresult >= 170 and begresult < 185:bronzebeg += 1 & money += 1000 & 'You fought hard and managed to take 3rd place prize. You get a bronze medal and a prize of 1, 000 rubles'
	if begresult >= 185 and begresult < 200:silverbeg += 1 & money += 2000 & 'You fought hard and managed to take the 2nd place prize. You get a silver medal and a prize of 2, 000 rubles'
	if begresult >= 200:razradbeg = 3 & goldbeg += 1 & money += 3000 & 'You fought hard and managed to take 1st place. You get a gold medal, a prize of 3000 rubles and 1st sports category on the run. You become the champion of the city on the run.'

	act 'Leave':gt 'fit', 'dressing room'
end

if $ARGS[0] = '1':
	cla
	beg += 1
	fat -= 10
	begplus = beg + speed + vital + rand(1, 20)
	begminus = salo/2 + rand(1, 20)
	begresult = begplus - begminus
	'<center><img src="images/etogame/begsor.jpg"></center>'
	'Women''s 400 meters race. You change clothes and go out on the track. Get up at the start. Distributed starting shot.'

	if begresult <= 0:'You barely managed to reach the finish line, what place is really there, of course you are the last.'
	if begresult > 0 and begresult < 200:'You are not bad ran for dilettante course, as ranked last 8th place.'
	if begresult >= 200 and begresult < 210:'You fought hard, but managed to take only 7 penultimate place.'
	if begresult >= 210 and begresult < 220:'You fought hard, but only managed to take 6th place.'
	if begresult >= 230 and begresult < 240:'You fought hard, but only managed to take 5th place.'
	if begresult >= 240 and begresult < 250:'You fought hard, but only managed to take 4th place.'
	if begresult >= 250 and begresult < 260:bronzebeg += 1 & money += 2000 & 'You fought hard and managed to take 3rd place prize. You get a bronze medal and a prize of 2, 000 rubles'
	if begresult >= 260 and begresult < 270:silverbeg += 1 & money += 3000 & 'You fought hard and managed to take the 2nd place prize. You get a silver medal and a prize of 3, 000 rubles'
	if begresult >= 270:razradbeg = 4 & goldbeg += 1 & money += 4000 & 'You fought hard and managed to take 1st place. You get a gold medal, a prize of 4000 rubles and the title of the CCM on the run. You become a champion of the region.'

	act 'Leave':gt 'fit', 'dressing room'
end

if $ARGS[0] = 'kms':
	cla
	beg += 1
	fat -= 10
	begplus = beg + speed + vital + rand(1, 20)
	begminus = salo/2 + rand(1, 20)
	begresult = begplus - begminus
	'<center><img src="images/etogame/begsor.jpg"></center>'
	'Women''s 400 meters race. You change clothes and go out on the track. Get up at the start. Distributed starting shot.'

	if begresult <= 0:'You barely managed to reach the finish line, what place is really there, of course you are the last.'
	if begresult > 0 and begresult < 270:'You are not bad ran for dilettante course, as ranked last 8th place.'
	if begresult >= 270 and begresult < 280:'You fought hard, but managed to take only 7 penultimate place.'
	if begresult >= 280 and begresult < 290:'You fought hard, but only managed to take 6th place.'
	if begresult >= 290 and begresult < 300:'You fought hard, but only managed to take 5th place.'
	if begresult >= 300 and begresult < 310:'You fought hard, but only managed to take 4th place.'
	if begresult >= 310 and begresult < 320:bronzebeg += 1 & money += 3000 & 'You fought hard and managed to take 3rd place prize. You get a bronze medal and a prize of 3, 000 rubles'
	if begresult >= 320 and begresult < 330:silverbeg += 1 & money += 4000 & 'You fought hard and managed to take the 2nd place prize. You get a silver medal and a prize of 4, 000 rubles'
	if begresult >= 330:razradbeg = 5 & goldbeg += 1 & money += 5000 & 'You fought hard and managed to take 1st place. You get a gold medal, a prize of 5000 rubles and the title of Master of Sports in the run. You become a champion of the region.'

	act 'Leave':gt 'fit', 'dressing room'
end

if $ARGS[0] = 'ross':
	cla
	beg += 1
	fat -= 10
	begplus = beg + speed + vital + rand(1, 20)
	begminus = salo + rand(1, 20)
	begresult = begplus - begminus
	'<center><img src="images/etogame/begsor.jpg"></center>'
	'Women''s 400 meters race. You change clothes and go out on the track. Get up at the start. Distributed starting shot.'

	if begresult <= 0:'You barely managed to reach the finish line, what place is really there, of course you are the last.'
	if begresult > 0 and begresult < 330:'You are not bad ran for dilettante course, as ranked last 8th place.'
	if begresult >= 330 and begresult < 340:'You fought hard, but managed to take only 7 penultimate place.'
	if begresult >= 340 and begresult < 350:'You fought hard, but only managed to take 6th place.'
	if begresult >= 350 and begresult < 360:'You fought hard, but only managed to take 5th place.'
	if begresult >= 360 and begresult < 370:'You fought hard, but only managed to take 4th place.'
	if begresult >= 370 and begresult < 380:bronzebeg += 1 & money += 4000 & 'You fought hard and managed to take 3rd place prize. You get a bronze medal and a prize of 4, 000 rubles'
	if begresult >= 380 and begresult < 390:silverbeg += 1 & money += 5000 & 'You fought hard and managed to take the 2nd place prize. You get a silver medal and a prize of 5, 000 rubles'
	if begresult >= 390:razradbeg = 6 & goldbeg += 1 & money += 6000 & 'You fought hard and managed to take 1st place. You get a gold medal, a prize of 6000 rubles and the title of International Master of Sports on the run. You become the champion of Russia.'

	act 'Leave':gt 'fit', 'dressing room'
end

if $ARGS[0] = 'kval':
	cla
	beg += 1
	fat -= 10
	razradbeg += 1
	begplus = beg + speed + vital + rand(1, 20)
	begminus = (salo * 2) + rand(1, 20)
	begresult = begplus - begminus
	'<center><img src="images/etogame/begsor.jpg"></center>'
	'Women''s 400 meters race. You change clothes and go out on the track. Get up at the start. Distributed starting shot.'

	if begresult <= 0:'You barely managed to reach the finish line, what place is really there, of course you are the last.'
	if begresult > 0 and begresult < 450:'You are not bad ran for dilettante course, as ranked last 8th place.'
	if begresult >= 450 and begresult < 500:'You fought hard, but managed to take only 7 penultimate place.'
	if begresult >= 500 and begresult < 550:'You fought hard, but only managed to take 6th place.'
	if begresult >= 550 and begresult < 600:'You fought hard, but only managed to take 5th place.'
	if begresult >= 600 and begresult < 650:'You fought hard, but only managed to take 4th place.'
	if begresult >= 650 and begresult < 700:razradbegK += 1 & bronzebeg += 1 & money += 5000 & 'You fought hard and managed to take 3rd place prize. You get a bronze medal and a prize of 5, 000 rubles'
	if begresult >= 700 and begresult < 800:razradbegK += 1 & silverbeg += 1 & money += 10000 & 'You fought hard and managed to take the 2nd place prize. You get a silver medal and a prize of 10, 000 rubles'
	if begresult >= 800:razradbegK += 1 & goldbeg += 1 & money += 15000 & 'You fought hard and managed to take 1st place. You get a gold medal, a prize of 15 thousand rubles.'

	act 'Leave':gt 'fit', 'dressing room'
end

if $ARGS[0] = 'evro':
	cla
	beg += 1
	fat -= 10
	razradbeg += 1
	begplus = beg + speed + vital + rand(1, 20)
	begminus = (salo * 3) + rand(1, 20)
	begresult = begplus - begminus
	'<center><img src="images/etogame/begsor.jpg"></center>'
	'Women''s 400 meters race. You change clothes and go out on the track. Get up at the start. Distributed starting shot.'

	if begresult <= 0:
		'You barely managed to reach the finish line, what place is really there, of course you are the last.'
	elseif begresult < 450:
		'You are not bad ran for dilettante course, as ranked last 8th place.'
	elseif begresult < 600:
		'You fought hard, but managed to take only 7 penultimate place.'
	elseif begresult < 800:
		'You fought hard, but only managed to take 6th place.'
	elseif begresult < 1000:
		'You fought hard, but only managed to take 5th place.'
	elseif begresult < 1300:
		'You fought hard, but only managed to take 4th place.'
	elseif begresult < 1800:
		razradbegEB += 1
		money += 10000
		'You fought hard and managed to take 3rd place prize. You get a bronze medal and a prize of 10 thousand rubles'
	elseif begresult < 2500:
		razradbegES += 1
		money += 15000
		'You fought hard and managed to take the 2nd place prize. You get a silver medal and a prize of 15, 000 rubles'
	else
		razradbegEG += 1
		money += 20000
		'You fought hard and managed to take 1st place. You get a gold medal, a prize of 20 thousand rubles. You are the champion of Europe.'
	end

	act 'Leave':gt 'fit', 'dressing room'
end

--- beg1 ---------------------------------

