Can I take the PA pre-license course if I'm still in High School?

Yes, you are allowed to take (and complete) the 75-hour Pennsylvania real estate salespersons course while you are still in high school.
The Real Estate Commission only requires you to be at least 18 years old and hold a high school diploma (or an equivalent diploma) by the time you apply for your real estate license.