1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 2<html> 3 4<head> 5<META http-equiv="Content-Type" content="text/html; charset=windows-1252"> 6<META http-equiv="Content-Style-Type" content="text/css"> 7<META name="GENERATOR" content="IBM WebSphere Studio Homepage Builder Version 7.0.0.0 for Windows"> 8<title>DWC_CheckFriendKey</title> 9<LINK rel="stylesheet" href="../css/nitro.css" type="text/css"> 10</head> 11 12<body> 13<a name="dwc__account_8h_15d6cddf8fc5964570ae6de624fda280c"></a> 14<h1 align="left">DWC_CheckFriendKey</h1> 15<h2>Syntax</h2> 16 17<dl> 18 <dd> 19<CODE>#include <dwc.h></CODE><BR> 20 <BR> 21 <PRE><CODE>BOOL <a href=DWC_CheckFriendKey.html#dwc__account_8h_15d6cddf8fc5964570ae6de624fda280c>DWC_CheckFriendKey</a>(const DWCUserData *userdata, 22 u64 friend_key);</CODE></PRE></dd> 23</dl> 24 25<h2>Arguments</h2> 26 27<TABLE border="1" width="100%"> 28 <TBODY> 29 30 <TR> 31<TD width="13%"><EM><STRONG>userdata</STRONG></EM></TD> 32<TD width="87%">Pointer to the <CODE>DWCUserData</CODE> structure that stores user data.</TD> 33 </TR> 34 35 <TR> 36<TD width="13%"><EM><STRONG>friend_key</STRONG></EM></TD> 37<TD width="87%">Friend code.</TD> 38 </TR> 39 40 </TBODY> 41</TABLE> 42 43<h2>Return Values</h2> 44 45<TABLE border="1" width="100%"> 46 <TBODY> 47 48 <TR> 49<TD width="13%"><EM><STRONG>TRUE</STRONG></EM></TD> 50<TD width="87%">Valid.</TD> 51 </TR> 52 53 <TR> 54<TD width="13%"><EM><STRONG>FALSE</STRONG></EM></TD> 55<TD width="87%">Invalid.</TD> 56 </TR> 57 58 </TBODY> 59</TABLE> 60 61<H2>Description</H2> 62<p>Checks the validity of the friend code specified by <CODE>friend_key</CODE>. When adding a friend code to the friend roster, use <A href="DWC_CreateFriendKeyToken.html"><CODE>DWC_CreateFriendKeyToken</CODE></A> to create friend data based on that friend code.</p><p>If the user enters an invalid code, either prompt the user to re-enter the information, or display an input error.</p><p>In RVLDWC1.4.15, the algorithm for generating friend codes was changed. Note that there is no compatibility with friend codes generated using previous versions. To check the validity of friend codes generated using previous versions, use the <a href=DWC_CheckFriendKeyLegacy.html#dwc__account_8h_1d768ea90966de9be2d05250d94b4e201><CODE>DWC_CheckFriendKeyLegacy</CODE></a> function.</p> 63 64<h2>See Also</h2> 65<p> 66 67<CODE><A href="DWC_CreateFriendKey.html">DWC_CreateFriendKey</A></CODE> 68 69<CODE><A href="DWC_CheckFriendKeyLegacy.html">DWC_CheckFriendKeyLegacy</A></CODE> 70 71</p> 72 73<H2>Revision History</H2> 74<DL> 75 76<DT><para>1.4.15</DT> 77<DD>Added a precaution to reflect modification of the creation algorithm.</DD> 78 79</DL> 80<hr><p>CONFIDENTIAL</p></body> 81</html> 82