gravity+jump problem unity 3d

Hello. I have the following problem: Gravity instead of pulling the player down pulls him up and the player does not jump when i press the G button. Please help solve the problem and fix it.

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
using UnityEngine.SceneManagement;

public class FPSInput : MonoBehaviour
{

    private CharacterController charcon;
    public float speed = 6f;
    public float gravity = 9.81f;
    public float jumpForce = 100f;

    private Vector3 movement;


    void Start()
    {
        movement = Vector3.zero;
        charcon = GetComponent < CharacterController > ();
    }

    void Update()
    {

        Movement();
    }

    void Movement()
    {

        movement = new Vector3(Input.GetAxis("Horizontal"), 0, Input.GetAxis("Vertical"));

        movement *= speed;

        if (Input.GetKeyDown(KeyCode.G))
        {
            movement.y *= jumpForce;
        }
        else
        {
            movement.y -= gravity;
        }
        charcon.Move(movement * Time.deltaTime);
    }
}

Hello,

Your object is not jumping because you set at the start of the function set y value to 0 movement = new Vector3(Input.GetAxis("Horizontal"), 0, Input.GetAxis("Vertical")); and then you multiply (zero) by jumpForce movement.y *= jumpForce;(maybe you wanted += instead of *=) . About why your character moves up, i can’t answer based on your description, maybe in inspector you have set gravity to a negative value.