Skin geometry cached

Discussion in 'Development' started by Error202, May 8, 2019.

  1. Error202

    Error202 Spider Jockey

    Messages:
    39
    I use skin for NPC... Than I change geometry for that skin.
    But always show old geometry... Why?
     
  2. Muqsit

    Muqsit Chicken

    Messages:
    1,533
    GitHub:
    muqsit
    I ran into this issue as well. Seems like the client caches the geometry, no idea why :|
    For now, I'm changing the geometry name everytime I update the geometry by concatenating random string to the name.
    PHP:
    public function createNewGeometry(string $geometry_namestring $geometry_data) : array{
        
    $random uniqid();
        
    $geometry json_decode($geometry_datatrue);
        
    $geometry[$geometry_name $random] = $geometry[$geometry_name];
        unset(
    $geometry[$geometry_name]);

        return [
    $geometry_name $random$geometry];
    }

    [
    $new_geometry_name$new_geometry_data] = $this->createNewGeometry($geometry_name$geometry_data);

    // use $new_geometry_name, $new_geometry_data
     
    Error202 and GamakCZ like this.
  3. Error202

    Error202 Spider Jockey

    Messages:
    39

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.