
596 So.2d 495 (1992)
Michael Eugene JOHNSON, Appellant,
v.
STATE of Florida, Appellee.
No. 91-1145.
District Court of Appeal of Florida, Fifth District.
March 27, 1992.
*496 James B. Gibson, Public Defender, and Paolo G. Annino, Asst. Public Defender, Daytona Beach, for appellant.
Robert A. Butterworth, Atty. Gen., Tallahassee, and Judy Taylor Rush, Asst. Atty. Gen., Daytona Beach, for appellee.
HARRIS, Judge.
Appellant, Michael Eugene Johnson, a juvenile (age 15), appeals from three judgments and sentences rendered May 13, 1991. He was charged by delinquency petitions with the following:
(1) Shooting into an occupied vehicle and causing great bodily harm to the person therein, Samuel Camp (causing victim to lose his arm); and battery on the victim by shooting him with a firearm. This offense occurred on August 17, 1990. The case was later transferred to adult criminal court and designated case no. 90-3514.
(2) Sale or delivery of a controlled substance (cocaine). This offense occurred on October 5, 1990. The case was later transferred to adult criminal court and designated case no. 90-3515.
(3) Possession of a controlled substance (cocaine) and escape. These crimes occurred on September 12, 1990. The case was later transferred to adult criminal court and designated case no. 90-3516.
On March 7, 1991, appellant pled no contest in 90-3514. On March 22, 1991, he pled guilty in the remaining cases. His scoresheet total was 378 points. Legal constraint points were multiplied.
At the sentencing hearing on May 13, 1991, appellant was adjudicated guilty in the three cases. At this time, the trial court made clear that he was inclined to sentence appellant as a youthful offender so that he could be accepted into a boot camp program, although he felt appellant should be on probation for a long period of time. The trial court noted on the record that he believed adult sanctions were appropriate due to the seriousness of the offense and for the protection of the community; because of appellant's age; because one of the crimes was aggressive, violent, premeditated and willful causing severe injury; because one offense consisted of the sale of drugs; because the psychological testing of appellant indicated a street sophistication well beyond his age; and because of the appellant's prior record. He further stated that extended probation was necessary due to the large amount of restitution (approximately $42,000).
At the hearing, both attorneys questioned whether appellant could be sentenced under the Youthful Offender Act[1] to a mixed youthful offender and non-youthful offender sentence totaling 14 years. They concluded that a mixed sentence was possible and worked out a plea agreement which would allow a mixed sentencing scheme of incarceration as a youthful offender followed by 10 years probation as an adult. Appellant was sentenced as follows:
(1) Case No. 3514: Sentenced as an adult to ten years probation on both counts; the same to run concurrent to each other and consecutive to Case Nos. 3515 and 3516.
(2) Case No. 3515: Sentenced as a youthful offender to four years DOC; the same to run concurrent to Case No. 3516.
(3) Case No. 3516: Sentenced as a youthful offender to four years DOC on each *497 count; the same to run concurrent to each other and to Case No. 3515.
He now appeals. We reverse.
Although we commend the court and counsel for attempting to fashion a reasonable (and perhaps effective) sentence, we conclude that the sentence is, nevertheless, illegal.
Section 958.04, Florida Statutes (1990 Supp.) states:
(2) In lieu of other criminal penalties authorized by law and notwithstanding any imposition of consecutive sentences, the court shall dispose of the criminal case as follows:
* * * * * *
(c) The court may impose a split sentence whereby the youthful offender is to be placed on probation or community control upon completion of any specified period of incarceration; however, if the incarceration period is to be served in a department facility other than a probation and restitution center or community residential facility, such period shall be for not less than 1 year or more than 4 years. The period of probation or community control shall commence immediately upon the release of the youthful offender from incarceration. The period of incarceration imposed or served and the period of probation or community control, when added together, shall not exceed 6 years.
In Allen v. State, 526 So.2d 69 (Fla. 1988), the supreme court addressed the certified question:
The issue presented is whether a youth sentenced for multiple felonies under the Youthful Offender Act may be sentenced consecutively so that his total commitment exceeds the six-year youthful offender maximum prescribed in section 958.05, Florida Statutes (1979).
In Allen, a juvenile pled guilty to grand theft and bail bond jumping and was sentenced (under the Youthful Offender Act) to four years imprisonment followed by two years of community control for each offense, the sentences to run consecutively. The court held that the limitation on the time period of confinement is a primary benefit of the youthful offender act. Therefore, consecutive sentences resulting in total commitment of more than six years were illegal. The court went on to state:
Although section 775.021(4) directs that a trial judge may order separate sentences to be served concurrently or consecutively, section 775.021(2), Florida Statutes, states that "[t]he provisions of this chapter are applicable to offenses defined by other statutes, unless the code otherwise provides." Here, the Youthful Offender Act expressly directs that its provisions should be applied in lieu of other penalties.
Accordingly, we hold that once a defendant has been classified a youthful offender, the court must adhere to the six-year cap established by the legislature. If trial courts wish to impose consecutive sentences "for the protection of society," as did the First District in Harmon [v. State, 397 So.2d 1218 (Fla. 1st DCA 1981)], they properly may decline to classify a multiple offender as a youthful offender and sentence him or her as an adult.
Id. at 70-71.
In Dimilta v. State, 590 So.2d 1074 (Fla. 2nd DCA 1991), the defendant was convicted of burglary. At the time he committed the crime, he was on probation for eight previous offenses. He was designated as a youthful offender in the earlier cases and sentenced to two and one-half years incarceration to be followed by five years probation. He was sentenced on violation of probation to four and one-half years incarceration consecutive to the fifteen year burglary term. The district court found the four and one-half year term erroneous. Although the trial court indicated that it had intended to impose adult and youthful offender sentences on some counts and sanctions on others, the district court held such a scheme would be contrary to the intent of the Youthful Offender Act. See, also, Dyer v. State, 534 So.2d 843 (Fla. 5th DCA 1988).
Since we conclude that the sentence is illegal, we remand for further proceedings. *498 Johnson should be permitted to withdraw his plea or, if he stands by his plea, the court must determine whether to sentence him as an adult without reference to the Youthful Offender Act or to limit his sentence as the Act requires.
We also note that scoring of legal constraint points was erroneous. Flowers v. State, 586 So.2d 1058 (Fla. 1991). This should be corrected on remand.
PETERSON and GRIFFIN, JJ., concur.
NOTES
[1]  Section 958.04, Florida Statutes (Supp. 1990).
