1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Images in forms not loading

Discussion in 'Development' started by Atomization, May 27, 2019.

  1. Atomization

    Atomization Baby Zombie

    Messages:
    120
    GitHub:
    iAtomPlaza
    using form API, the images only load if i open another app on on pc and then switch back to mc; using "url" Screenshot (11).png
     
  2. Error202

    Error202 Spider Jockey

    Messages:
    39
    I have this problem too... Only resource pack helped me
     
  3. Atomization

    Atomization Baby Zombie

    Messages:
    120
    GitHub:
    iAtomPlaza
    I dont want to use images from packs because i have some custom images i want to use
     
  4. Error202

    Error202 Spider Jockey

    Messages:
    39
    I am too... I added custom image files with custom names to the textures/items folder and just specified the file path.
     
  5. Atomization

    Atomization Baby Zombie

    Messages:
    120
    GitHub:
    iAtomPlaza
    how might i do this?
     
  6. Error202

    Error202 Spider Jockey

    Messages:
    39
    1. Copy your images to folder texture/items in texturepack
    [​IMG]

    2. Set images paths (image files without extensions)
    PHP:
    $form = new SimpleForm(function (Player $player$data) use ($config$plugin) {
        
    $result $data;
        if(
    $result === null){ // Closed form without submitting
            
    return;
        }
        
    // SOME ACTIONS
    });
    $form->setTitle('DIALOG TITLE');
    $form->setContent('DIALOG CONTENT TEXT');

    $form->addButton('First Image'Form::IMAGE_TYPE_PATH'textures/items/av1');
    $form->addButton('Seconf Image'Form::IMAGE_TYPE_PATH'textures/items/av2');
    ...
    $player->sendForm($form);
    P.S. I create small texturepack with only my images...
     
  7. Levi

    Levi Skeleton

    Messages:
    955
    GitHub:
    captainleviftw
    Will the players have to download the texture pack with the images?
     
  8. iCirgio

    iCirgio Slime

    Messages:
    92
    GitHub:
    lolnova
    Most likely yes they do have to download it before joining the srver
     
  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.