In this case it sounds like your play style is off because your build may be off. It's important to remember how you build, you aren't going to beat a ranged carry in pure ranged DPS battle. Honestly you should use your range skills quickly and drop in as hammer form as you gain mana per hit and armor and mr passively while in it.
Since this is mostly a late game thing I'll give you an idea on how your build should look in the end.
Trinity Force: Self explanatory, sheen proc works wonders with all your abilities and on hits, mana is vital to you, HP, AD, Slow for the rare moments one of your slows are down, movement speed off zeal gives a fairly high movement speed even when off your stance switch ghost
Heart of Gold/Randuins Omen: More hp to put on top of the trinity force, the GP5 for heart of gold early adds up especially if you grab a philo early on (You should jayce ate some mana cost nerfs so he's hungry for mana). The randuins cripples the enemy team once you jump in with the hammer and the armor ensures physicals won't just eat you.
Merc Treads: Must have, need the MR to round out the build and the tenacity for when you jump in is vital
Banshee Veil: I've removed maw and swapped for this after some gold efficiency charts and general theorycrafting. The flat health all the time is better than the shield on the basis it takes all damage. The Mr is higher and the mana gives you more room to spam and fight in team fights. It also makes you virtually impossible to initiate on and most of the AOE damage you take in a fight is from magic. The damage loss is negligible on the basis you might actually survive the team fight.
Last Whisper: Absolute must have, for pure physical damage nothing trumps last whisper especially end game. At 30 Armor on the enemy is does more damage than an unstacked bloodthirster and at 103 it does more than a fully stacked bloodthirster and it's cheaper. You may want this before maw, if so, grab a hexdrinker for the MR, AD and shield and go straight for this.
Completely up to you: This last item slot is for whatever you need to counter the opposing team. Need to survive poke? Force of nature. Want to sponge more damage and go in earlier? Warmogs. Need more damage? Black Cleaver/IE/Bloodthirster
This is by no means a build order, you may only want sheen early and then rush randuins. This is a final build idea. Remember a massive portion of your damage is your skills and only half are actually affected by AD so building tanky early on can let you still hurt.
As Jayce you are the most dynamic character on the field and you need a firm grasp as to what your team needs from you. If they need a damage sponge early on in engages, you need to build for that. If they've got a nasty nocturne eating your AD carry, you sit by that AD carry until noc arrives and you knock him away with your hammer and leap onto him afterwards. You've got an initiate? You throw your gate down and shoot your Q into them and hammer leap in while popping randuins and eat their AD carry. Don't forgot that your hammer stance gives you mana on hit and Armor and MR passively while in it.
For most engages you'll want to start in ranged mode, land a quick gate followed by Q as well as a sheen proc and the on hit MR/AR reduction from the ranged swap and then leap in on a squishy or keep a tanky dps off your AD carry with your hammer stance and the CC from it. I highly suggest smart casting with jayce otherwise it takes too long to use all these abilities and then join the fray, cause otherwise your tank/other tanky dps will die.
If you notice this build leans heavily towards being a tanky dps, the reason for this is because his damage can all be put out in a fast barrage and then you can quickly close the distance afterwards. As far as being a ranged carry, Jayce has one of the lowest attack ranges and no steroids besides a fast three shot. His DPS is not so great honestly. He's more of a tanky dps that can attack from range. Don't forgot about his ranged skills as you need to jump between using all of his abilities all the time, don't just AA unless you are nothing but cooldowns or are OOM.