"I might not be here by the date of the court."
Just FYI, there could be several court appearances in connection with a divorce (esp. in NY, where grounds must be proven in all cases).
"My question is if it matters whether I show up"
Matters to whom? The court won't care. It will simply proceed with the case as a default matter.
"do they need my presence to get us divorced?"
"If no,what happens?"
The case will proceed as a default matter. Your husband will have his say, and you won't, and the court will decide if he has proven the alleged grounds for the divorce.