<?xml version="1.0" encoding="us-ascii"?><InstanceReport xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><Version>2.4.0.8</Version><ReportLongName>0020 - Disclosure - 13. Related Party Transactions</ReportLongName><DisplayLabelColumn>true</DisplayLabelColumn><ShowElementNames>false</ShowElementNames><RoundingOption /><HasEmbeddedReports>false</HasEmbeddedReports><Columns><Column FlagID="0"><Id>1</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><CurrencyCode /><FootnoteIndexer /><hasSegments>false</hasSegments><hasScenarios>false</hasScenarios><MCU><KeyName /><CurrencySymbol /><contextRef><ContextID>From2012-07-01to2013-06-30</ContextID><EntitySchema>http://www.sec.gov/CIK</EntitySchema><EntityValue>0000098618</EntityValue><PeriodDisplayName /><PeriodType>duration</PeriodType><PeriodStartDate>2012-07-01T00:00:00</PeriodStartDate><PeriodEndDate>2013-06-30T00:00:00</PeriodEndDate><Segments /><Scenarios /></contextRef><UPS /><CurrencyCode /><OriginalCurrencyCode /></MCU><CurrencySymbol /><Labels><Label Key="CalendarSupplement" Id="0" Label="12 Months Ended" /><Label Key="Calendar" Id="1" Label="Jun. 30, 2013" /></Labels></Column></Columns><Rows><Row FlagID="0"><Id>1</Id><IsAbstractGroupTitle>true</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><Level>1</Level><ElementName>us-gaap_RelatedPartyTransactionsAbstract</ElementName><ElementPrefix>us-gaap_</ElementPrefix><IsBaseElement>true</IsBaseElement><BalanceType>na</BalanceType><PeriodType>duration</PeriodType><IsReportTitle>false</IsReportTitle><IsSegmentTitle>false</IsSegmentTitle><IsCalendarTitle>false</IsCalendarTitle><IsEquityPrevioslyReportedAsRow>false</IsEquityPrevioslyReportedAsRow><IsEquityAdjustmentRow>false</IsEquityAdjustmentRow><IsBeginningBalance>false</IsBeginningBalance><IsEndingBalance>false</IsEndingBalance><IsReverseSign>false</IsReverseSign><FootnoteIndexer /><Cells><Cell FlagID="0" ContextID="" UnitID=""><Id>1</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText /><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat></Cell></Cells><ElementDataType>xbrli:stringItemType</ElementDataType><SimpleDataType>string</SimpleDataType><IsTotalLabel>false</IsTotalLabel><UnitID>0</UnitID><Label>Related Party Transactions [Abstract]</Label></Row><Row FlagID="0"><Id>2</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><Level>2</Level><ElementName>us-gaap_RelatedPartyTransactionsDisclosureTextBlock</ElementName><ElementPrefix>us-gaap_</ElementPrefix><IsBaseElement>true</IsBaseElement><BalanceType>na</BalanceType><PeriodType>duration</PeriodType><IsReportTitle>false</IsReportTitle><IsSegmentTitle>false</IsSegmentTitle><IsCalendarTitle>false</IsCalendarTitle><IsEquityPrevioslyReportedAsRow>false</IsEquityPrevioslyReportedAsRow><IsEquityAdjustmentRow>false</IsEquityAdjustmentRow><IsBeginningBalance>false</IsBeginningBalance><IsEndingBalance>false</IsEndingBalance><IsReverseSign>false</IsReverseSign><FootnoteIndexer /><Cells><Cell FlagID="0" ContextID="From2012-07-01to2013-06-30" UnitID=""><Id>1</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText>&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;&lt;b&gt;&lt;i&gt;&lt;u&gt;Employment agreements&lt;/u&gt;&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;On October 10, 2011, the Company entered
into employment agreements with the Company&amp;#146;s Chief Executive Officer and Chief Financial Officer. The agreements have severance
provisions and are effective through December 31, 2014. In addition, the Company and the parties had agreed to defer certain compensation
due in calendar 2011 to calendar 2012. At June 30, 2012 all deferred amounts had been paid. Prior to December 31, 2011, the Company
also agreed to defer the January 1, 2012 salary reductions discussed in the agreements due to anticipated increased business activity.
The effective date of the salary reduction is currently on hold and will be reviewed on a quarterly basis. No accrual has been
made for the severance provisions as the likelihood of payment is considered remote. See the Company&amp;#146;s Form 10-K for the
fiscal year ended June 30, 2011 for the full agreements.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;&lt;b&gt;&lt;i&gt;&lt;u&gt;Stock options granted&lt;/u&gt;&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;On June 18, 2013, the Company granted
five-year stock options to directors, officers and employees to acquire 425,000 shares of the Company&amp;#146;s common stock at an
exercise price of $.50 per share.&amp;#160; The stock options were 100% vested upon grant.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;&lt;b&gt;&lt;i&gt;&lt;u&gt;American Citizenship Center,
LLC &amp;#160; &lt;/u&gt;&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;On January 6, 2012, the Company agreed
to provide a $300,000 working capital loan to American Citizenship Center, LLC (&amp;#147;ACC&amp;#148;), a related party company that
provides 1) proprietary, automated on-line assistance for eligible immigrants to prepare for and obtain US citizenship; and 2)
assistance in preparing and filing for Deferred Action for Undocumented Youth under a new policy developed by the Department of
Homeland Security designed to allow certain people who did not intentionally violate immigration law to continue to live and work
in the United States. The Company received a $300,000 Note and a two year warrant to purchase 240,000 membership units (currently
would equate to approximately 20% ownership) of ACC at an exercise price of $1.25 per unit. The Note accrues interest at 7.5% (paid
quarterly) on the outstanding balance, was payable in monthly installments of $75,000 commencing on March 31, 2013 and continuing
until paid in full, provides for Alanco to have board of director representation and is secured by all assets and properties of
ACC. At both June 30, 2013 and June 30, 2012, Mr. Robert Kauffman, CEO of Alanco, was a personal investor in the membership units
and owned approximately 10% of ACC.&lt;/p&gt;

&lt;p style="font: 12pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify; text-indent: 0.5in"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;During fiscal year ended June 30, 2013,
Alanco agreed to amend the loan agreement increasing the maximum amount available under the loan to $400,000. The additional availability
was granted under similar terms and conditions to the original agreement and was used by ACC to open an office in Los Angeles,
CA. Under the amended promissory note, the outstanding principal shall be reduced to at least $300,000 on or before December 31,
2013 and $100,000 on or before March 31, 2014. The remaining balance shall be due in full on or before June 30, 2014. In consideration
for the loan, Alanco received an additional warrant to acquire 60,000 units of ACC at $1.25 per unit and the expiration date for
all warrants issued to Alanco was extended to August 31, 2016. The Company considered the value of the ACC warrants to be immaterial
at both June 30, 2013 and 2012 due to the startup nature of ACC and the significant premium (39%) of the exercise price compared
to the most recent stock sales. Therefore, no value has been recorded for these warrants. At June 30, 2013 and 2012, ACC had an
outstanding note balances under Alanco&amp;#146;s commitment of $375,000 and $300,000 respectively.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;&lt;b&gt;&amp;#160;&lt;/b&gt;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;At June 30, 2013, the Company also
had unpaid receivables due from ACC in the amount of $32,800, consisting of $27,000 in billings for accounting services and $5,800
representing one quarter of interest. Subsequent to year end ACC made payments bringing balances current.&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 24.75pt; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;&lt;b&gt;&lt;i&gt;&lt;u&gt;Notes payable &amp;#150; Other,
related party&lt;/u&gt;&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;&amp;#160;&lt;/p&gt;

&lt;p style="font: 8pt Times New Roman, Times, Serif; margin: 0 0 0 27pt; text-align: justify"&gt;At June 30, 2012, notes payable included
an unsecured convertible note due to the Company&amp;#146;s Chief Financial Officer. The note was a 10 day demand note in the amount
of $28,000, bearing interest at 8% per annum, issued for additional working capital. The note was convertible into Class A Common
Stock at $2.24 per share. Related interest expense for fiscal 2013 and 2012 was $2,300 and $1,700, respectively. The note and accrued
interest were paid in full prior to June 30, 2013.&lt;/p&gt;</NonNumbericText><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat></Cell></Cells><ElementDataType>nonnum:textBlockItemType</ElementDataType><SimpleDataType>na</SimpleDataType><ElementDefenition>The entire disclosure for related party transactions. Examples of related party transactions include transactions between (a) a parent company and its subsidiary; (b) subsidiaries of a common parent; (c) and entity and its principal owners; and (d) affiliates.</ElementDefenition><ElementReferences>Reference 1: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 850

 -SubTopic 10

 -Section 50

 -Paragraph 4

 -URI http://asc.fasb.org/extlink&amp;oid=6457730&amp;loc=d3e39622-107864



Reference 2: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 850

 -SubTopic 10

 -Section 50

 -Paragraph 3

 -URI http://asc.fasb.org/extlink&amp;oid=6457730&amp;loc=d3e39603-107864



Reference 3: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 850

 -SubTopic 10

 -Section 50

 -Paragraph 1

 -URI http://asc.fasb.org/extlink&amp;oid=6457730&amp;loc=d3e39549-107864



Reference 4: http://www.xbrl.org/2003/role/presentationRef

 -Publisher SEC

 -Name Regulation S-X (SX)

 -Number 210

 -Section 04

 -Paragraph b

 -Article 3A



Reference 5: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 235

 -SubTopic 10

 -Section S99

 -Paragraph 1

 -Subparagraph (SX 210.4-08.(k))

 -URI http://asc.fasb.org/extlink&amp;oid=26873400&amp;loc=d3e23780-122690



Reference 6: http://www.xbrl.org/2003/role/presentationRef

 -Publisher SEC

 -Name Regulation S-X (SX)

 -Number 210

 -Section 08

 -Paragraph k

 -Article 4



Reference 7: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 850

 -SubTopic 10

 -Section 50

 -Paragraph 6

 -URI http://asc.fasb.org/extlink&amp;oid=6457730&amp;loc=d3e39691-107864



Reference 8: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 850

 -SubTopic 10

 -Section 50

 -Paragraph 5

 -URI http://asc.fasb.org/extlink&amp;oid=6457730&amp;loc=d3e39678-107864



</ElementReferences><IsTotalLabel>false</IsTotalLabel><UnitID>0</UnitID><Label>RELATED PARTY TRANSACTIONS</Label></Row></Rows><Footnotes /><IsEquityReport>false</IsEquityReport><ReportName>13. Related Party Transactions</ReportName><MonetaryRoundingLevel>UnKnown</MonetaryRoundingLevel><SharesRoundingLevel>UnKnown</SharesRoundingLevel><PerShareRoundingLevel>UnKnown</PerShareRoundingLevel><ExchangeRateRoundingLevel>UnKnown</ExchangeRateRoundingLevel><HasCustomUnits>true</HasCustomUnits><IsEmbedReport>false</IsEmbedReport><IsMultiCurrency>false</IsMultiCurrency><ReportType>Sheet</ReportType><RoleURI>http://alanco.com/role/RelatedPartyTransactions</RoleURI><NumberOfCols>1</NumberOfCols><NumberOfRows>2</NumberOfRows></InstanceReport>
