If %HP% = 30 Then
Msg "You already have full HP"
You'll have to forgive me, I haven't used ASL (Again) for a long long time. But it's something similar to this.
With potions... say a potion healed 10 HP, and you have 25 HP, you could have it check every time the potion heals 1 point that you're not going over 30, or you could have the potion check,
if %HP% > 20 Then
Msg "You can not heal yet"
Else
Do Heal
Again you'll have to excuse my VB syntax there, not used ASL in some time, but you can get a good idea of what to do there, although my suggestion is indeed basic. One of the more experienced ASL users will probably give you a better suggestion.