Help! I dont understand what im doing wrong with my gravity

Hello. I’m pretty new to Godot nearly 1 month of first of using the engine and i have ran in to a problem .
until now i have only made simple games following tutorials making games where you can move in all four directions and so i thought its finally time to make a platformer .
So i started following a tutorial by heartbeast
and thing were going pretty smoothly until i tried adding gravity and things just stopped working
i added gravity like in the tutorial and my charecter woundnt move left or right i have to press the up button more than once for the charecter to jump.
Here is the code please someone help i hhave spent hours trying to fix it and im loosing my mind :

extends CharacterBody2D
var Velocity = Vector2.ZERO
const acc = 150
const fric = 170
var Direct_x 
func _physics_process(delta):
	apply_gravity()
	if Input.is_action_just_pressed('ui_up'):
		Velocity.y -= 150
	Direct_x = Input.get_action_strength('ui_right')-Input.get_action_strength('ui_left')
	if Direct_x == 0 :
		friction()
	else:
		accelaration(Direct_x)
	move_and_collide(Velocity*delta)
func accelaration(amount):
	Velocity.x = move_toward(Velocity.x,acc*amount,10)
func friction():
	Velocity.x = move_toward(Velocity.x,0,25)
func apply_gravity():
	Velocity.y += 4

Btw i used move_and_collide() here cause move_and_slide() dosent take in arguments anymore and i know velocity is now built in and i tried using move_and_slide() but the movement was very wired so i switched over to move and collide()

Also Can anyone tell me how i can use is_on_floor with move_and_collide()?