Confusion with proof about a fact $\mathbb{P}$-name Let $\mathbb{P}$ be poset.
Let $B$ be a set. We say that a $\mathbb{P}$-name $\dot{b}$  is a nice name for member of $B$ if there is a maximal antichain $A\subseteq\mathbb{P}$ and a function $h:A\rightarrow{B}$ such that $ p\Vdash\dot{b}=h(p)$ for all $p\in{A}$. Here, we abuse of the notation and say $\dot{b}=\left<{A,h}\right>$ . 
Let $D, B$ be sets. We say that a $\mathbb{P}$-name $\dot{z}$ is a nice name for a function from $D$ into $B$ if there is $\left<{A_{d},h_{d}}\right>_{d \in D}$ such that $\dot{z}(d)=\left<{A_{d},h_{d}}\right>$(as a nice name) for all $d\in D$, that is, $A_{d}$ is a maximal antichain and $h_{d}:A_{d}\to B$ such that $ p\Vdash\dot{z}(d)=h_{d}(p)$ for all $p \in A_{d}$. Here, we abuse of the notation and say $\dot{z}(d)=\left<{A_{d},h_{d}}\right>_{d}$ . 
Let $p \in \mathbb{P}$ and  $\tau$ be a $\mathbb{P}$-name such that $p \Vdash \tau \in \check{B}$. Then there exist a nice name $\dot{b}$ for an object in $B$ such that $p \Vdash \dot{b} = \tau.$
Also if  $\sigma$  be a $\mathbb{P}$-name such that $p \Vdash \sigma:\check{D}\to \check{B}$ Then there exist a nice name $\dot{z}$ for a function from $D$ into $B$ such that $p \Vdash \dot{z} = \sigma.$
I am studying the book Kunen and I'm a little confused when defining a $\mathbb{P}$-name. 
Is not a question at research but can give me a suggestion how to solve this.
It is a simple fact for you ,I have not been able to resolve. 
A suggestion of how to define $\dot{b}$ and $\dot{z}$. Thanks
 A: I'll outline the argument for $\dot b$; the case of $\dot z$ uses the same idea.  Given a name $\tau$ such that $1\Vdash\tau\in\check B$, let $D$ be the set of conditions that  decide a value for $\tau$; that is, $q\in D$ iff there is some element $x\in B$ such that $q\Vdash\tau=\check x$.  Verify that $D$ is dense in $\mathbb P$.  Let $A$ be an antichain that is maximal among antichains $\subseteq D$, and verify that $A$ is also a maximal antichain in $\mathbb P$ (because $D$ is dense).  Define $h:A\to B$ by sending any $q\in A$ to the $x\in B$ such that $q\Vdash\tau=\check x$.  Then $A$ and $h$ constitute a nice name $\dot b$.  Each $q\in A$ forces both $\tau$ and $\dot b$ to equal $h(q)$, and so each $q\in A$ forces $\tau=\dot b$.  Because $A$ is a maximal antichain, no condition can force $\tau\neq\dot b$ (because such a condition would be incompatible with everything in $A$), and therefore $1\Vdash\tau=\dot b$.  
If you only have some condition $p$ (rather than 1) forcing $\tau\in\check B$, then you'll only get a nice name $(A,H)$ in the weaker sense that $A$ is maximal among antichains of extensions of $p$.
