# phone_selfies

!{ HOW TO USE:
- UNLOCKING A PICTURE:
	There are different types of pictures that can be viewed with the phone. These need to be unlocked for them to become viewable.
	This is done by setting the correct variable to 1 INSIDE the event itself.
	<<npcname>> should be replaced by the name of the npc for who you want to unlock something.	
	- Pictures Sveta gets sent by an npc:
		<<npcname>>[i] = 1
	- Pictures Sveta takes herself with an npc:
		<<npcname>>sveta[i] = 1
	- Explicit pictures from an npc (could include Sveta):
		<<npcname>>sex[i] = 1
	- Pictures Sveta takes of an npc:
		<<npcname>>photo[i] = 1
	- Pictures Sveta takes of herself:
		Here the code is run through the camera option on the phone and it will automatically unlock the correct picture.
- INCREASE THE PICTURE COUNTER IN THIS FILE:
	NPC Pictures:
		As pictures are added the number in 'listretrieve2' inside this file needs to be increased by the amount of pictures you are adding.
		- loopmax:
			For selfies sent by an npc
		- loopmaxsveta:
			For selfies with an npc taken on Sveta''s phone
		- loopmaxsex:
			For explicit selfies
		- loopmaxev:
			For pictures Sveta takes of an npc
	SVETA SELFIES:
		The total amounts are kept in 'telefon', 'Phone_selfie_totals'.
		Increase the correct variable in there to have it added to the phone.
}

if $ARGS[0] = 'selfies':
	menu_off = 0
	gs 'telefon', 'Phone_selfie_totals'
	*clr & cla
	
	!!These variables determine which selfietypes need to be checked
	clovar = 1
	undvar = 1
	nudvar = 1
	swimvar = 0
	bathvar = 0
	showervar = 0
	titflashvar = 1
	assflashvar = 1
	pussyflashvar = 1
	
	'<center><h4><font color="maroon">Photo library</font></h4></center>'
	*nl
	'Selfies'
	'<a href="exec:gt ''phone_selfies'', ''bathroom''">Bathroom selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''bedroom''">Bedroom selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''kitchen''">Kitchen selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''livingroom''">Livingroom selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''changingroom''">Changingroom selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''park''">Park selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''lockerroom''">Lockerroom selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''beach''">Beach selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''gym''">Gym selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''dance''">Dance selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''classroom''">Classroom selfies</a>'
	'<a href="exec:gt ''phone_selfies'', ''misc''">Misc selfies</a>'
	*nl
	'Family and friends'
	'<a href="exec:gt ''phone_selfies'', ''family''">Family</a>'
	'<a href="exec:gt ''phone_selfies'', ''school''">School friends</a>'
	'<a href="exec:gt ''phone_selfies'', ''teacher''">Teachers</a>'
	'<a href="exec:gt ''phone_selfies'', ''pavlovsk''">Pavlovsk friends</a>'
	'<a href="exec:gt ''phone_selfies'', ''city''">City friends</a>'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'listretrieve':
	!!Loop for clothed selfies, dynamics set variables as mixing them in loop instructions is bad
	if clovar = 1:
		'<center><b>Clothed selfies</b></center>'
		*nl
		temp_clocnt = 1
		dynamic 'temp_loop = <<$phone_loc>>_cloloop'
		dynamic 'temp_total = <<$phone_loc>>_clotot'
		:temp_loop
			!!setting value to unmixed variable so it can be checked in the if below
			dynamic '$phone_locval = <<$phone_loc>>_closelfie[<<temp_clocnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''clothed'', ''<<temp_clocnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/clothed/<<temp_clocnt>>.jpg"     height="150" /></a>  '
			temp_clocnt += 1
		if temp_clocnt <= temp_total: jump'temp_loop'
	end
	
	!!Loop for swimwear selfies, dynamics set variables as mixing them in loop instructions is bad
	if swimvar = 1:
		'<center><b>Swimwear selfies</b></center>'
		*nl
		temp_clocnt = 1
		dynamic 'temp_loop1 = <<$phone_loc>>_swimloop'
		dynamic 'temp_total = <<$phone_loc>>_swim'
		:temp_loop1
			!!setting value to unmixed variable so it can be checked in the if below
			dynamic '$phone_locval = <<$phone_loc>>_swim[<<temp_clocnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''bikini'', ''<<temp_clocnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/bikini/<<temp_clocnt>>.jpg"     height="150" /></a>  '
			temp_clocnt += 1
		if temp_clocnt <= temp_total: jump'temp_loop1'
	end
		
	!!loop for underwear selfies
	if undvar = 1:
		'<center><b>Underwear selfies</b></center>'
		*nl
		temp_undcnt = 1
		dynamic 'temp_loop2 = <<$phone_loc>>_undloop'
		dynamic 'temp_total = <<$phone_loc>>_undtot'
		:temp_loop2
			dynamic '$phone_locval = <<$phone_loc>>_undselfie[<<temp_undcnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''underwear'', ''<<temp_undcnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/underwear/<<temp_undcnt>>.jpg"     height="150" /></a>  '
			temp_undcnt += 1
		if temp_undcnt <= temp_total: jump'temp_loop2'
	end

	!!loop for nude selfies
	if nudvar = 1:
		'<center><b>Nude selfies</b></center>'
		*nl
		temp_nudcnt = 1
		dynamic 'temp_loop3 = <<$phone_loc>>_nudloop'
		dynamic 'temp_total = <<$phone_loc>>_nudtot'
		:temp_loop3
			dynamic '$phone_locval = <<$phone_loc>>_nudselfie[<<temp_nudcnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''nude'', ''<<temp_nudcnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/nude/<<temp_nudcnt>>.jpg"     height="150" /></a>  '
			temp_nudcnt += 1
		if temp_nudcnt <= temp_total: jump'temp_loop3'
	end
	
	!!loop for bath selfies
	if bathvar = 1:
		'<center><b>Bath selfies</b></center>'
		*nl
		temp_bathcnt = 1
		dynamic 'temp_loop4 = <<$phone_loc>>_bathloop'
		dynamic 'temp_total = <<$phone_loc>>_bathtot'
		:temp_loop4
			dynamic '$phone_locval = <<$phone_loc>>_bathselfie[<<temp_bathcnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''bath'', ''<<temp_bathcnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/bath/<<temp_bathcnt>>.jpg"     height="150" /></a>  '
			temp_bathcnt += 1
		if temp_bathcnt <= temp_total: jump'temp_loop4'
	end
	
	!!loop for shower selfies
	if showervar = 1:
		'<center><b>Shower selfies</b></center>'
		*nl
		temp_showercnt = 1
		dynamic 'temp_loop5 = <<$phone_loc>>_showerloop'
		dynamic 'temp_total = <<$phone_loc>>_showertot'
		:temp_loop5
			dynamic '$phone_locval = <<$phone_loc>>_showerselfie[<<temp_showercnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''shower'', ''<<temp_showercnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/shower/<<temp_showercnt>>.jpg"     height="150" /></a>  '
			temp_showercnt += 1
		if temp_showercnt <= temp_total: jump'temp_loop5'
	end
	
	!!loop for flashing tits selfies
	if titflashvar = 1:
		'<center><b>Flashing tits selfies</b></center>'
		*nl
		temp_flashtitscnt = 1
		dynamic 'temp_loop6 = <<$phone_loc>>_titflashloop'
		dynamic 'temp_total = <<$phone_loc>>_titflash'
		:temp_loop6
			dynamic '$phone_locval = <<$phone_loc>>_titflash[<<temp_flashtitscnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''titflash'', ''<<temp_flashtitscnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/titflash/<<temp_flashtitscnt>>.jpg"     height="150" /></a>  '
			temp_flashtitscnt += 1
		if temp_flashtitscnt <= temp_total: jump'temp_loop6'
	end
	
	!!loop for flashing ass selfies
	if assflashvar = 1:
		'<center><b>Flashing ass selfies</b></center>'
		*nl
		temp_flashasscnt = 1
		dynamic 'temp_loop7 = <<$phone_loc>>_assflashloop'
		dynamic 'temp_total = <<$phone_loc>>_assflash'
		:temp_loop7
			dynamic '$phone_locval = <<$phone_loc>>_assflash[<<temp_flashasscnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''assflash'', ''<<temp_flashasscnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/assflash/<<temp_flashasscnt>>.jpg"     height="150" /></a>  '
			temp_flashasscnt += 1
		if temp_flashasscnt <= temp_total: jump'temp_loop7'
	end
	
	!!loop for flashing pussy selfies
	if pussyflashvar = 1:
		'<center><b>Flashing pussy selfies</b></center>'
		*nl
		temp_flashpussycnt = 1
		dynamic 'temp_loop8 = <<$phone_loc>>_pussyflashloop'
		dynamic 'temp_total = <<$phone_loc>>_pussyflash'
		:temp_loop8
			dynamic '$phone_locval = <<$phone_loc>>_pussyflash[<<temp_flashpussycnt>>]'
			if $phone_locval = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show'', ''pussyflash'', ''<<temp_flashpussycnt>>''"><img src="images/pc/selfies/<<$phone_loc>>/pussyflash/<<temp_flashpussycnt>>.jpg"     height="150" /></a>  '
			temp_flashpussycnt += 1
		if temp_flashpussycnt <= temp_total: jump'temp_loop8'
	end
end

if $ARGS[0] = 'listretrieve2':
	if numnpc = 1:
		'<center><h4><font color="maroon">Dimka pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/dimka/'
		$imgloc = 'images/characters/pavlovsk/school/boy/dimka/selfies/'
		$selfienpc = 'dimka'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 2:
		'<center><h4><font color="maroon">Artem pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/artem/'
		$imgloc = 'images/characters/pavlovsk/school/boy/artem/selfies/'
		$selfienpc = 'artem'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 3:
		'<center><h4><font color="maroon">Ivan pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/ivan/'
		$imgloc = 'images/characters/pavlovsk/school/boy/ivan/selfies/'
		$selfienpc = 'ivan'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 4:
		'<center><h4><font color="maroon">Igor pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/igor/'
		$imgloc = 'images/characters/pavlovsk/school/boy/igor/selfies/'
		$selfienpc = 'igor'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 5:
		'<center><h4><font color="maroon">Fedor pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/fedor/'
		$imgloc = 'images/characters/pavlovsk/school/boy/fedor/selfies/'
		$selfienpc = 'fedor'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 6:
		'<center><h4><font color="maroon">Petka pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/petka/'
		$imgloc = 'images/characters/pavlovsk/school/boy/petka/selfies/'
		$selfienpc = 'petka'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 7:
		'<center><h4><font color="maroon">Lesco pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/lesco/'
		$imgloc = 'images/characters/pavlovsk/school/boy/lesco/selfies/'
		$selfienpc = 'lesco'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 8:
		'<center><h4><font color="maroon">Svyatoslav pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/svyatoslav/'
		$imgloc = 'images/characters/pavlovsk/school/boy/svyatoslav/selfies/'
		$selfienpc = 'svyatoslav'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 9:
		'<center><h4><font color="maroon">Vitek pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/vitek/'
		$imgloc = 'images/characters/pavlovsk/school/boy/vitek/selfies/'
		$selfienpc = 'vitek'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 10:
		'<center><h4><font color="maroon">Dan pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/dan/'
		$imgloc = 'images/characters/pavlovsk/school/boy/dan/selfies/'
		$selfienpc = 'dan'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 11:
		'<center><h4><font color="maroon">Vasily pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/vasily/'
		$imgloc = 'images/characters/pavlovsk/school/boy/vasily/selfies/'
		$selfienpc = 'vasily'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 12:
		'<center><h4><font color="maroon">Julia pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/julia/'
		$imgloc = 'images/characters/pavlovsk/school/boy/julia/selfies/'
		$selfienpc = 'julia'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 13:
		'<center><h4><font color="maroon">Lariska pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/lariska/'
		$imgloc = 'images/characters/pavlovsk/school/boy/lariska/selfies/'
		$selfienpc = 'lariska'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 14:
		'<center><h4><font color="maroon">Katja pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/katja/'
		$imgloc = 'images/characters/pavlovsk/school/boy/katja/selfies/'
		$selfienpc = 'katja'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 15:
		'<center><h4><font color="maroon">Vicky pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/vicky/'
		$imgloc = 'images/characters/pavlovsk/school/boy/vicky/selfies/'
		$selfienpc = 'vicky'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 16:
		'<center><h4><font color="maroon">Natasha pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/natasha/'
		$imgloc = 'images/characters/pavlovsk/school/boy/natasha/selfies/'
		$selfienpc = 'natasha'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 17:
		'<center><h4><font color="maroon">Inna pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/inna/'
		$imgloc = 'images/characters/pavlovsk/school/boy/inna/selfies/'
		$selfienpc = 'inna'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 18:
		'<center><h4><font color="maroon">Christina pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/christina/'
		$imgloc = 'images/characters/pavlovsk/school/boy/christina/selfies/'
		$selfienpc = 'christina'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 19:
		'<center><h4><font color="maroon">Lina pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/lina/'
		$imgloc = 'images/characters/pavlovsk/school/boy/lina/selfies/'
		$selfienpc = 'lina'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 20:
		'<center><h4><font color="maroon">Lena pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/lena/'
		$imgloc = 'images/characters/pavlovsk/school/boy/lena/selfies/'
		$selfienpc = 'lena'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 21:
		'<center><h4><font color="maroon">Lera pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/lera/'
		$imgloc = 'images/characters/pavlovsk/school/boy/lera/selfies/'
		$selfienpc = 'lera'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 22:
		'<center><h4><font color="maroon">Bella pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/bella/'
		$imgloc = 'images/characters/pavlovsk/school/boy/bella/selfies/'
		$selfienpc = 'bella'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 23:
		'<center><h4><font color="maroon">Albina pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/albina/'
		$imgloc = 'images/characters/pavlovsk/school/boy/albina/selfies/'
		$selfienpc = 'albina'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 24:
		'<center><h4><font color="maroon">Pauline pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/pauline/'
		$imgloc = 'images/characters/pavlovsk/school/boy/pauline/selfies/'
		$selfienpc = 'pauline'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 25:
		'<center><h4><font color="maroon">Sonia pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/sonia/'
		$imgloc = 'images/characters/pavlovsk/school/girl/sonia/selfies/'
		$selfienpc = 'sonia'
		loopmaxev = 0
		loopmax = 45
		loopmaxsveta = 25
		loopmaxsex = 9
	elseif numnpc = 26:
		'<center><h4><font color="maroon">Anatoly pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/anatoly/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/anatoly/selfies/'
		$selfienpc = 'anatoly'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 28:
		'<center><h4><font color="maroon">Stepfather pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/vladimir/'
		$imgloc = 'images/characters/pavlovsk/resident/vladimir/selfies/'
		$selfienpc = 'vladimir'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 29:
		'<center><h4><font color="maroon">Mother pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/mom/'
		$imgloc = 'images/characters/pavlovsk/resident/mom/selfies/'
		$selfienpc = 'mom'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 33:
		'<center><h4><font color="maroon">Anya pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/anya/'
		$imgloc = 'images/characters/pavlovsk/resident/anya/selfies/'
		$selfienpc = 'anya'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 34:
		'<center><h4><font color="maroon">Kolka pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/kolka/'
		$imgloc = 'images/characters/pavlovsk/resident/kolka/selfies/'
		$selfienpc = 'kolka'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 35:
		'<center><h4><font color="maroon">Father pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/???/'
!! Where are these located?
		$imgloc = 'images/characters/pavlovsk/resident/???/selfies/'
		$selfienpc = 'father'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 54:
		'<center><h4><font color="maroon">Uncle Misha pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/misha/'
		$imgloc = 'images/characters/pavlovsk/resident/misha/selfies/'
		$selfienpc = 'misha'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 56:
		'<center><h4><font color="maroon">Roma pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/roma/'
		$imgloc = 'images/characters/pavlovsk/resident/roma/selfies/'
		$selfienpc = 'roma'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 57:
		'<center><h4><font color="maroon">Rex pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/rex/'
		$imgloc = 'images/characters/pavlovsk/resident/rex/selfies/'
		$selfienpc = 'rex'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 69:
		'<center><h4><font color="maroon">Mikhail pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/mikhail/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/mikhail/selfies/'
		$selfienpc = 'coachmikhail'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 54:
		'<center><h4><font color="maroon">Sergey pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/sergey/'
		$imgloc = 'images/characters/pavlovsk/resident/sergey/selfies/'
		$selfienpc = 'sergey'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 128:
		'<center><h4><font color="maroon">Makar pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/makar/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/makar/selfies/'
		$selfienpc = 'makar'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 129:
		'<center><h4><font color="maroon">Serafim pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/serafim/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/serafim/selfies/'
		$selfienpc = 'serafim'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 130:
		'<center><h4><font color="maroon">Ilya pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/ilya/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/ilya/selfies/'
		$selfienpc = 'ilya'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 131:
		'<center><h4><font color="maroon">Viktor pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/viktor/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/viktor/selfies/'
		$selfienpc = 'viktor'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 132:
		'<center><h4><font color="maroon">Ruslan pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/ruslan/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/ruslan/selfies/'
		$selfienpc = 'ruslan'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 133:
		'<center><h4><font color="maroon">Rolan pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/rolan/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/rolan/selfies/'
		$selfienpc = 'rolan'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 134:
		'<center><h4><font color="maroon">Aleksandrina pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/aleksandrina/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/aleksandrina/selfies/'
		$selfienpc = 'aleksandrina'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 135:
		'<center><h4><font color="maroon">Yeva pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/yeva/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/yeva/selfies/'
		$selfienpc = 'yeva'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 136:
		'<center><h4><font color="maroon">Olga pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/olga/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/olga/selfies/'
		$selfienpc = 'olga'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 137:
		'<center><h4><font color="maroon">Raven pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/raven/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/raven/selfies/'
		$selfienpc = 'raven'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 138:
		'<center><h4><font color="maroon">Arina pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/arina/'
		$imgloc = 'images/characters/pavlovsk/school/teacher/arina/selfies/'
		$selfienpc = 'arina'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 139:
		'<center><h4><font color="maroon">Stasya pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/stasya/'
		$imgloc = 'images/characters/pavlovsk/school/boy/stasya/selfies/'
		$selfienpc = 'stasya'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 140:
		'<center><h4><font color="maroon">Lizaveta pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/lizaveta/'
		$imgloc = 'images/characters/pavlovsk/school/boy/lizaveta/selfies/'
		$selfienpc = 'lizaveta'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 141:
		'<center><h4><font color="maroon">Veronika pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/veronika/'
		$imgloc = 'images/characters/pavlovsk/school/boy/veronika/selfies/'
		$selfienpc = 'veronika'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 142:
		'<center><h4><font color="maroon">Zinaida pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/zinaida/'
		$imgloc = 'images/characters/pavlovsk/school/boy/zinaida/selfies/'
		$selfienpc = 'zinaida'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 143:
		'<center><h4><font color="maroon">Alyona pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/alyona/'
		$imgloc = 'images/characters/pavlovsk/school/boy/alyona/selfies/'
		$selfienpc = 'alyona'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 144:
		'<center><h4><font color="maroon">Anushka pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/anushka/'	
		$imgloc = 'images/characters/pavlovsk/school/girl/anushka/selfies/'
		$selfienpc = 'anushka'
		loopmaxev = 6
		loopmax = 22
		loopmaxsveta = 2
		loopmaxsex = 7
	elseif numnpc = 145:
		'<center><h4><font color="maroon">Ekaterina pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/ekaterina/'
		$imgloc = 'images/characters/pavlovsk/school/boy/ekaterina/selfies/'
		$selfienpc = 'ekaterina'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 146:
		'<center><h4><font color="maroon">Marcus pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/marcus/'
		$imgloc = 'images/characters/pavlovsk/school/boy/marcus/selfies/'
		$selfienpc = 'marcus'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 147:
		'<center><h4><font color="maroon">Andrey pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/andrey/'
		$imgloc = 'images/characters/pavlovsk/school/boy/andrey/selfies/'
		$selfienpc = 'andrey'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 148:
		'<center><h4><font color="maroon">Mefodiy pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/mefodiy/'
		$imgloc = 'images/characters/pavlovsk/school/boy/mefodiy/selfies/'
		$selfienpc = 'mefodiy'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 149:
		'<center><h4><font color="maroon">Lazar pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/lazar/'
		$imgloc = 'images/characters/pavlovsk/school/boy/lazar/selfies/'
		$selfienpc = 'lazar'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 150:
		'<center><h4><font color="maroon">Erast pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/erast/'
		$imgloc = 'images/characters/pavlovsk/school/boy/erast/selfies/'
		$selfienpc = 'erast'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 151:
		'<center><h4><font color="maroon">Evgeny pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/evgeny/'
		$imgloc = 'images/characters/pavlovsk/school/boy/evgeny/selfies/'
		$selfienpc = 'evgeny'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 152:
		'<center><h4><font color="maroon">Feofan pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/feofan/'
		$imgloc = 'images/characters/pavlovsk/school/boy/feofan/selfies/'
		$selfienpc = 'feofan'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 153:
		'<center><h4><font color="maroon">Gerasim pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/gerasim/'
		$imgloc = 'images/characters/pavlovsk/school/boy/gerasim/selfies/'
		$selfienpc = 'gerasim'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 154:
		'<center><h4><font color="maroon">Radomir pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/radomir/'
		$imgloc = 'images/characters/pavlovsk/school/boy/radomir/selfies/'
		$selfienpc = 'radomir'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 155:
		'<center><h4><font color="maroon">Lavrenti pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/lavrenti/'
		$imgloc = 'images/characters/pavlovsk/school/boy/lavrenti/selfies/'
		$selfienpc = 'lavrenti'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 156:
		'<center><h4><font color="maroon">Arkadi pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/arkadi/'
		$imgloc = 'images/characters/pavlovsk/school/boy/arkadi/selfies/'
		$selfienpc = 'arkadi'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 157:
		'<center><h4><font color="maroon">Roman pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/roman/'
		$imgloc = 'images/characters/pavlovsk/school/boy/roman/selfies/'
		$selfienpc = 'roman'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 158:
		'<center><h4><font color="maroon">Valentin pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/valentin/'
		$imgloc = 'images/characters/pavlovsk/school/boy/valentin/selfies/'
		$selfienpc = 'valentin'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 159:
		'<center><h4><font color="maroon">Petia pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/petia/'
		$imgloc = 'images/characters/pavlovsk/school/boy/petia/selfies/'
		$selfienpc = 'petia'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 165:
		'<center><h4><font color="maroon">Vanya pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/vanya/'
		$imgloc = 'images/characters/pavlovsk/school/boy/vanya/selfies/'
		$selfienpc = 'vanya'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	elseif numnpc = 189:
		'<center><h4><font color="maroon">Nikolai pictures</font></h4></center>'
		$photoloc = 'images/pc/pictures/nikolai/'
		$imgloc = 'images/characters/pavlovsk/school/boy/nikolai/selfies/'
		$selfienpc = 'nikolai'
		loopmaxev = 0
		loopmax = 0
		loopmaxsveta = 0
		loopmaxsex = 0
	else
		!! New npcs with selfies should be included above
	end
	
	if loopmaxev > 0:
		*nl
		'<center><b>Pictures</b></center>'
		*nl
		
		i = 1
		:temp_loopev
            dynamic '$selfie = <<$selfienpc>>photo[<<i>>]'
			if $selfie = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show2'', ''<<$photoloc>>'', ''<<i>>''"><img src="<<$photoloc>><<i>>.jpg"     height="150" /></a>  '
            i += 1
        if i <= loopmax: jump'temp_loopev'
	end
	
	if loopmax > 0:
		*nl
		'<center><b>Regular selfies</b></center>'
		*nl
		
		i = 1
		:temp_loopselfies
            dynamic '$selfie = <<$selfienpc>>[<<i>>]'
			if $selfie = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show2'', ''<<$imgloc>>'', ''<<i>>''"><img src="<<$imgloc>><<i>>.jpg"     height="150" /></a>  '
            i += 1
        if i <= loopmax: jump'temp_loopselfies'
	end
	
	if loopmaxsveta > 0:
		*nl
		'<center><b>Selfies with me</b></center>'
		*nl
		
		i = 1
		:temp_loopselfiessveta
			dynamic '$selfie = <<$selfienpc>>sveta[<<i>>]'
			if $selfie = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show2'', ''<<$imgloc>>sveta/'', ''<<i>>''"><img src="<<$imgloc>>sveta/<<i>>.jpg"     height="150" /></a>  '
			i += 1
		if i <= loopmaxsveta: jump'temp_loopselfiessveta'
	end
	
	if loopmaxsex > 0:
		*nl
		'<center><b>Sex selfies</b></center>'
		*nl
		
		i = 1
		:temp_loopselfiessex
			dynamic '$selfie = <<$selfienpc>>sex[<<i>>]'
			if $selfie = 1: *p '<a href="exec: gs ''phone_selfies_popup'', ''show2'', ''<<$imgloc>>sex/'', ''<<i>>''"><img src="<<$imgloc>>sex/<<i>>.jpg"     height="150" /></a>  '
			i += 1
		if i <= loopmaxsex: jump'temp_loopselfiessex'
	end
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end


if $ARGS[0] = 'bathroom':
	'<center><h4><font color="maroon">Bathroom selfies</font></h4></center>'
	$phone_loc = 'bathroom'
	gs 'telefon', 'Phone_selfie_totals'
	bathvar = 1
	showervar = 1
	*nl
	gs 'phone_selfies', 'listretrieve'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'bedroom':
	'<center><h4><font color="maroon">Bedroom selfies</font></h4></center>'
	$phone_loc = 'bedroom'
	*nl
	gs 'phone_selfies', 'listretrieve'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'kitchen':
	'<center><h4><font color="maroon">Kitchen selfies</font></h4></center>'
	$phone_loc = 'kitchen'
	*nl
	gs 'phone_selfies', 'listretrieve'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'livingroom':
	'<center><h4><font color="maroon">Livingroom selfies</font></h4></center>'
	$phone_loc = 'livingroom'
	*nl
	gs 'phone_selfies', 'listretrieve'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'changingroom':
	'<center><h4><font color="maroon">Changingroom selfies</font></h4></center>'
	$phone_loc = 'changingroom'
	*nl
	gs 'phone_selfies', 'listretrieve'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'park':
	'<center><h4><font color="maroon">Park selfies</font></h4></center>'
	$phone_loc = 'park'
	*nl
	gs 'phone_selfies', 'listretrieve'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'lockerroom':
	'<center><h4><font color="maroon">Lockerroom selfies</font></h4></center>'
	$phone_loc = 'lockerroom'
	*nl
	gs 'phone_selfies', 'listretrieve'
		
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'beach':
	'<center><h4><font color="maroon">Beach selfies</font></h4></center>'
	$phone_loc = 'beach'
	clovar = 0
	undvar = 0
	swimvar = 1
	*nl
	gs 'phone_selfies', 'listretrieve'
		
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'gym':
	'<center><h4><font color="maroon">Gym selfies</font></h4></center>'
	$phone_loc = 'gym'
	*nl
	gs 'phone_selfies', 'listretrieve'
		
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'classroom':
	'<center><h4><font color="maroon">Classroom selfies</font></h4></center>'
	$phone_loc = 'school_classroom'
	nudvar = 0
	*nl
	gs 'phone_selfies', 'listretrieve'
		
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'dance':
	'<center><h4><font color="maroon">Dance selfies</font></h4></center>'
	$phone_loc = 'dance'
	undvar = 0
	nudvar = 0
	*nl
	gs 'phone_selfies', 'listretrieve'
		
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'misc':
	'<center><h4><font color="maroon">Misc selfies</font></h4></center>'
	$phone_loc = 'dance'
	undvar = 0
	nudvar = 0
	*nl
	gs 'phone_selfies', 'listretrieve'
		
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'family':
	'<center><h4><font color="maroon">Family members</font></h4></center>'
	$textgrup = ''
	count1 = 0
	i = 1
	'<center><table cellspacing="3">'
	:familygruploop	
		if count1 = 6 : $textgrup += '<tr>'

		if npc_grupTipe['A<<i>>'] = 7 and npc_selfieon['A<<i>>'] = 1:
			count1 += 1
			$textgrup += '' + '<td bgcolor=<<$bcolor2>> align="center"><img  height="100" src="images/pc/npc_headshots/<<i>>.jpg"><br>' + $npc_selfie['A<<i>>']
		end
		if count1< 6 and npc_grupTipe['A<<i>>'] = 7:
			$textgrup += '</td>'
		elseif count1 = 6 and npc_grupTipe['A<<i>>'] = 7:
			$textgrup +='</td></tr><tr>' & count1 = 0
		end
		i += 1
	if i <= aarraynumber:jump 'familygruploop'

	'<<$textgrup>>'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'school':
	'<center><h4><font color="maroon">School friends</font></h4></center>'
	$textgrup = ''
	count1 = 0
	i = 1
	'<center><table cellspacing="3">'
	:schoolgruploop	
		if count1 = 6 : $textgrup += '<tr>'

		if (npc_grupTipe['A<<i>>'] = 1 or npc_grupTipe['A<<i>>'] = 2 or npc_grupTipe['A<<i>>'] = 3 or npc_grupTipe['A<<i>>'] = 4 or npc_grupTipe['A<<i>>'] = 5) and npc_selfieon['A<<i>>'] = 1:
			count1 += 1
			$textgrup += '' + '<td bgcolor=<<$bcolor2>> align="center"><img  height="100" src="images/pc/npc_headshots/<<i>>.jpg"><br>' + $npc_selfie['A<<i>>']
		end
		if count1< 6 and (npc_grupTipe['A<<i>>'] = 1 or npc_grupTipe['A<<i>>'] = 2 or npc_grupTipe['A<<i>>'] = 3 or npc_grupTipe['A<<i>>'] = 4 or npc_grupTipe['A<<i>>'] = 5):
			$textgrup += '</td>'
		elseif count1 = 6 and (npc_grupTipe['A<<i>>'] = 1 or npc_grupTipe['A<<i>>'] = 2 or npc_grupTipe['A<<i>>'] = 3 or npc_grupTipe['A<<i>>'] = 4 or npc_grupTipe['A<<i>>'] = 5):
			$textgrup +='</td></tr><tr>' & count1 = 0
		end
		i += 1
	if i <= aarraynumber:jump 'schoolgruploop'

	'<<$textgrup>>'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'teacher':
	'<center><h4><font color="maroon">Teachers</font></h4></center>'
	$textgrup = ''
	count1 = 0
	i = 1
	'<center><table cellspacing="3">'
	:teachergruploop	
		if count1 = 6 : $textgrup += '<tr>'

		if npc_grupTipe['A<<i>>'] = 6 and npc_selfieon['A<<i>>'] = 1:
			count1 += 1
			$textgrup += '' + '<td bgcolor=<<$bcolor2>> align="center"><img  height="100" src="images/pc/npc_headshots/<<i>>.jpg"><br>' + $npc_selfie['A<<i>>']
		end
		if count1< 6 and npc_grupTipe['A<<i>>'] = 6:
			$textgrup += '</td>'
		elseif count1 = 6 and npc_grupTipe['A<<i>>'] = 6:
			$textgrup +='</td></tr><tr>' & count1 = 0
		end
		i += 1
	if i <= aarraynumber:jump 'teachergruploop'

	'<<$textgrup>>'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'pavlovsk':
	'<center><h4><font color="maroon">Pavlovsk friends</font></h4></center>'
	$textgrup = ''
	count1 = 0
	i = 1
	'<center><table cellspacing="3">'
	:pavgruploop	
		if count1 = 6 : $textgrup += '<tr>'

		if npc_grupTipe['A<<i>>'] = 8 and npc_selfieon['A<<i>>'] = 1:
			count1 += 1
			$textgrup += '' + '<td bgcolor=<<$bcolor2>> align="center"><img  height="100" src="images/pc/npc_headshots/<<i>>.jpg"><br>' + $npc_selfie['A<<i>>']
		end
		if count1< 6 and npc_grupTipe['A<<i>>'] = 8:
			$textgrup += '</td>'
		elseif count1 = 6 and npc_grupTipe['A<<i>>'] = 8:
			$textgrup +='</td></tr><tr>' & count1 = 0
		end
		i += 1
	if i <= aarraynumber:jump 'pavgruploop'

	'<<$textgrup>>'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

if $ARGS[0] = 'city':
	'<center><h4><font color="maroon">City friends</font></h4></center>'
	
	act 'Back': gt 'phone_selfies', 'selfies'
	!gt $loc, $metka
	act 'Stop watching selfies': gt '<<$menu_loc>>', '<<$menu_arg>>'
end

--- phone_selfies ---------------------------------