0
Good afternoon, I’m developing a naval battle game in JAVA using Primefaces to make the front end. I would like a help to assemble a commandButton that when clicked, it triggers a function that will return if the house selected by the user is empty or if not, which ship is allocated there and then it subtiates the image that has in this commandButton by the image of the ship.
<h:commandButton image="/resources/images/agua.png" style="width:100%"/>
The biggest difficulty would be in this exchange of an image for another if someone can give a little help :)