Villager Chat

Villager Chat [Paid] 2.1.5

have bought this a while ago (not logged in) and i have same problem with pigeonpeanit, how can i get update?
redownload it from the order link in ko-fi and it should give you the updated version!
 
Hi there! Love this chat overlay so much. However, I was wondering if it's possible to set a default villager for all chatters and then assign villagers manually later per chatter?

I could probably noodle around and figure something out, but I was wondering if that was an approved way that wouldn't break everything.
 
Hi there! Love this chat overlay so much. However, I was wondering if it's possible to set a default villager for all chatters and then assign villagers manually later per chatter?

I could probably noodle around and figure something out, but I was wondering if that was an approved way that wouldn't break everything.
hmmm, yea I guess if you wanted to remove the randomness entirely then you can do this:

open villager.js and find the getVillager function:
JavaScript:
// gets the user's randomly assigned villager
function getVillager(user) {
  const { userName } = user

  // get the assigned villager from this session
  let storedUserData = userData[userName]

  // if this was the first chat from the user during this session, they
  // don't have any stored data, so create new stored data for them
  if (!storedUserData) {
    storedUserData = { villagerName: randomVillagerName() }

    // store the user data so that the user will always have the same color
    userData[userName] = storedUserData
  }

  return villagerData[storedUserData.villagerName]
}

and on the line where it uses randomVillagerName(), give it a specific villager name surrounded in quotes instead, like this:
JavaScript:
storedUserData = { villagerName: 'Ankha' }
 
Is it possible to have certain Villagers from the villager chat only be available to people who have it as their Permanent Villager Assignment? so for example if I had 1 person manually set to Coco, could I make it that no one else could be Coco through simply joining and/or rerolling?
 
Is it possible to have certain Villagers from the villager chat only be available to people who have it as their Permanent Villager Assignment? so for example if I had 1 person manually set to Coco, could I make it that no one else could be Coco through simply joining and/or rerolling?
Alright it requires a bit of JavaScript modification but I figured it out. So in villager.js, first you want to find this:
JavaScript:
const userData = {
  zaytri: {
    villagerName: 'Ankha',
  },
}


And change it to this:
JavaScript:
const permanentUserData = {
  zaytri: {
    villagerName: 'Ankha',
  },
}

const userData = { ...permanentUserData }

This allows the code to keep a copy of the initial permanent user data separate from the user data used for random assignment.

Then, find the randomVillagerName function, which looks like this:
JavaScript:
function randomVillagerName() {
  const villagers = Object.values(villagerData)
  const villagerCount = villagers.length

  return villagers[randomInteger(0, villagerCount - 1)].name
}

And change it to this:
JavaScript:
function randomVillagerName() {
  const permanentVillagers = Object.values(permanentUserData).map(user => user.villagerName)
  const villagers = Object.values(villagerData).filter((villager) => {
    return !permanentVillagers.includes(villager.name)
  })
  const villagerCount = villagers.length

  return villagers[randomInteger(0, villagerCount - 1)].name
}

Which lets it filter out the villager names used in the permanent villager assignment.
 
Hi!
I'm super interested by your villager overlay, for the customizable options... also I don't know anything about coding 😅
I would like to know if it's possible to fix the position of the bubbles? I would like them to pop randomly but between several places on my overlay, were caracters are drawn 🧐
(Edit: i've not bought it yet because I would really need that option for my new overlay project)
 
Hi!
I'm super interested by your villager overlay, for the customizable options... also I don't know anything about coding 😅
I would like to know if it's possible to fix the position of the bubbles? I would like them to pop randomly but between several places on my overlay, were caracters are drawn 🧐
(Edit: i've not bought it yet because I would really need that option for my new overlay project)
Could you show me a sketch of what that would look like?
 
Hi!
Here is a part of the project I'm working on ↓

What I'm looking for is to make the chat bubble pop and desappear randomly between defined places, with the viewer name and other options your allowed (VIP badges...). That would be "fixing" the places where they can appear on the overlay, like anchors 🧐
I would like to add the caracters we use too insted of the villager faces, I'm not sure if it would work, like this one : archer animé vid telliam émote.gif test.jpg
 
Hi!
Here is a part of the project I'm working on ↓

What I'm looking for is to make the chat bubble pop and desappear randomly between defined places, with the viewer name and other options your allowed (VIP badges...). That would be "fixing" the places where they can appear on the overlay, like anchors 🧐
I would like to add the caracters we use too insted of the villager faces, I'm not sure if it would work, like this one : View attachment 24View attachment 23
perfect I understand it now

I can make that work, but due to the technical complexity and personalization of this request, it would need to be done as a custom commission. My commission details are here: https://ko-fi.com/zaytri/commissions
 
Zaytri updated Villager Chat with a new update entry:

Now with settings!

v2.0.0 introduces a settings screen, where you can customize Villager Chat all you want!

PltOW77.png

Read the rest of this update entry...
 
hiii <3
im trying to figure out how to add sound effects to the messages, i also tried to add a custom villager image.
for both it always showed 1700053281251.png
for the sound i tried both mp3 and wav, for the image i tried png and a link from imgur

i put it into the chat folder and i tried create a folder within there called Assets but both did not work too :c

where is this widget assets folder?
i cant seem to find it.
 
hiii <3
im trying to figure out how to add sound effects to the messages, i also tried to add a custom villager image.
for both it always showed View attachment 27
for the sound i tried both mp3 and wav, for the image i tried png and a link from imgur

i put it into the chat folder and i tried create a folder within there called Assets but both did not work too :c

where is this widget assets folder?
i cant seem to find it.
you'll need to create the assets folder
make sure it's lowercase, like this:

dJ3iKg2.png


Edit: I added an assets folder with a README.txt inside there for v2.0.1 (can't put empty folders in a ZIP file), hopefully that should clear up future confusion.
 
Last edited:
Back
Top