#how to change the text in billboard UI with a script?

1 messages · Page 1 of 1 (latest)

craggy blade
#

im making all of france and it takes a long time to name the cities is there a script i can put here to change text?

#

I want to put a script there

vagrant cliff
#
-- Table of city names (can be changed at any time)
local CityNames = {
    Paris = "country",
    Orleans = "america",
    Orleans2 = "australia2"
}

-- Function to update the TextLabels for all cities
local function UpdateCityNames()
    local parent = script.Parent
    -- Paris
    local Paris = parent:FindFirstChild("Paris")
    if Paris and Paris:FindFirstChild("Attachment") and Paris.Attachment:FindFirstChild("BillboardGui") and Paris.Attachment.BillboardGui:FindFirstChild("TextLabel") then
        Paris.Attachment.BillboardGui.TextLabel.Text = CityNames.Paris or "Paris"
    end

    -- Orleans
    local Orleans = parent:FindFirstChild("Orleans")
    if Orleans and Orleans:FindFirstChild("Attachment") and Orleans.Attachment:FindFirstChild("BillboardGui") and Orleans.Attachment.BillboardGui:FindFirstChild("TextLabel") then
        Orleans.Attachment.BillboardGui.TextLabel.Text = CityNames.Orleans or "Orleans"
    end

    -- Orleans2
    local Orleans2 = parent:FindFirstChild("Orleans 2")
    if Orleans2 and Orleans2:FindFirstChild("Attachment") and Orleans2.Attachment:FindFirstChild("BillboardGui") and Orleans2.Attachment.BillboardGui:FindFirstChild("TextLabel") then
        Orleans2.Attachment.BillboardGui.TextLabel.Text = CityNames.Orleans2 or "Orleans 2"
    end
end

-- Call once on script run
UpdateCityNames()

-- Example: Change names at runtime
-- CityNames.Paris = "New Paris"
-- CityNames.Orleans = "New Orleans"
-- CityNames.Orleans2 = "New Orleans 2"
-- UpdateCityNames()
#

@craggy blade

#

do u need anything else?

craggy blade
#

thanks

#

ill test it rn

#

1 thing

#

i pressed f8 im bugged now idk what do i do

#

cant click

vagrant cliff
#

uh

vagrant cliff
#

?

craggy blade
#

but my progress wont save

#

theres a green outline on my game

carmine ivyBOT
#

studio** You are now Level 1! **studio

craggy blade
#

cant save

vagrant cliff
#

cant u close place

vagrant cliff
craggy blade
#

alr

vagrant cliff
craggy blade
#

just a white screen when ipresed close place

#

done

#

lets see

#

ok everything saved

vagrant cliff
#

wait did it close

#

good

#

tell me if it works

craggy blade
#

this is all

#

i have done

#

how do i use it tho

vagrant cliff
#

oh

#

so its more than 3

#

ok

craggy blade
#

yeah ive done a lot since

vagrant cliff
#

gimmie like 15 - 40 mins and ill get back to u when ive added all of the cities

carmine ivyBOT
#

studio** You are now Level 4! **studio

vagrant cliff
craggy blade
#

yeah im doing all of europe

craggy blade
#

i dont think you get what i meant

vagrant cliff
vagrant cliff
craggy blade
#

let me show you

craggy blade
vagrant cliff
craggy blade
#

nvm

#

its cos like i wanted a script so like i can paste it into a city and i customize the name fast instead of having to go to properties and stuff

#

but ngl i got used to it

#

already

#

but i still have a lot of questions

#

ill ping when i ask the question cos i kinda forgot

vagrant cliff
vagrant cliff
craggy blade
#

btw

#

im trying to make a rts game based of nations roleplay remastered but a little more complex

#

like war system instead of troops painting the map for you

#

and factories

carmine ivyBOT
#

studio** You are now Level 2! **studio

craggy blade
#

and land gives you natural resourses

#

to use in factories

vagrant cliff
vagrant cliff
craggy blade
#

yeah i have no experience

vagrant cliff
craggy blade
vagrant cliff
craggy blade
vagrant cliff
craggy blade
craggy blade
craggy blade
#

its cos im gonna make all of europe

vagrant cliff
#

dont learn both forget what i just said

craggy blade
#

yeah i have been trying

#

to learn scripting

vagrant cliff
craggy blade
#

yeah

vagrant cliff
#

id reccomend, you learn something, then mess around with it for a day

#

so you reinforce ur learning

#

biggest mistake ive done

#

i wasted a whole year because of that

craggy blade
#

because theres this game on roblox with so much potental called nations roleplay remastered almost reaching 1k players yet it is VERY wonky and horribly made

#

thanks for the advice

vagrant cliff
craggy blade
craggy blade
vagrant cliff
craggy blade
#

added missions

#

wanna join the roblox studio to see what i got so far

vagrant cliff
vagrant cliff
#

add me

craggy blade
#

alr

vagrant cliff
#

subzero44tb

craggy blade
#

alr

#

i added u

vagrant cliff
#

alr

craggy blade
#

added

vagrant cliff
#

u adding me?

craggy blade
#

yeah

vagrant cliff
#

i don see it

#

oh nvm

#

found it

craggy blade
#

alr

#

@vagrant cliff

#

for a real time strategy game

vagrant cliff
#

so are there gonna be like little armies or smth

craggy blade
#

like this

#

basically like this but better:

#

wait ur listening to kanye west lol

#

i started watching yt but i was listening to my kanye west playlist for the last few hours

vagrant cliff
carmine ivyBOT
#

studio** You are now Level 5! **studio

vagrant cliff
craggy blade
craggy blade
#

thanks

vagrant cliff
craggy blade
#

yeah

vagrant cliff
craggy blade
#

alr

vagrant cliff
#

wt if u make them little balls instead

#

instead of cyclinders?

#

or nah?

craggy blade
#

YOO

#

hmm

#

alr bet

vagrant cliff
#

alr

#

if u want to tho

#

ts is just a suggestin

#

suggestion

craggy blade
#

yeah its good

#

btw

vagrant cliff
craggy blade
#

im making everything with small squares

vagrant cliff
craggy blade
#

then mashing them into provinces

#

each province belongs to 1 city

vagrant cliff
craggy blade
vagrant cliff
#

ohh so like little states?

#

i think

vagrant cliff
#

i think

craggy blade
carmine ivyBOT
#

studio** You are now Level 3! **studio

craggy blade
vagrant cliff
#

i think these go into the camera thing

#

@craggy blade

craggy blade
#

yeah it might have come from the custom sky i put

vagrant cliff
craggy blade
#

alright tanks

vagrant cliff
craggy blade
#

my plan originally was to only use these

#

they get like bigger by 4 each time

vagrant cliff
craggy blade
#

like made by each other

#

yk what i mean

vagrant cliff
#

<-- this idiot gets it

craggy blade
#

but i genually dont know what whent wrong

vagrant cliff
craggy blade
#

cos like i started having to extend the small squares bigger

#

or smaller

craggy blade
#

like im not using the 1x1 or 4x4 anymore

vagrant cliff
craggy blade
#

i started stretching them thats not what i wanted i dont know what went wrong

vagrant cliff
craggy blade
#

but i had to cos the 1x1 nor 4x4 wouldnt fit like this

craggy blade
vagrant cliff
craggy blade
#

it dont matter but im gonna try doing that for the future countries

vagrant cliff
vagrant cliff
craggy blade
#

alright thank you i appreciate your help

#

1 question

vagrant cliff
craggy blade
#

how do i replace the cities with the circles the best way?

vagrant cliff
#

i might have an idea

#

lemme try it on one to see if it works

#

but i will hop off for a bit cuz ive been on all day

#

after i try it

vagrant cliff
craggy blade
craggy blade
#

thanks

#

im gonna consider doing the map from scratch

#

and only use these

#

no stretching

#

but tomorrow

#

rn im burnt out

#

ive been working on this all day

#

anyways ill update you in dms cys

#

cya

#

yk what

carmine ivyBOT
#

studio** You are now Level 4! **studio

craggy blade
#

at this point

#

might just re do

#

the cities too and use the circles that u wanted instead ngl

#

so i basically didnt do anything today other than find the europe map image in the background to base the map out of

#

but i learnt skill ig and now ik what to do

vagrant cliff
craggy blade
#

alr

#

thanks man

craggy blade
vagrant cliff
#

It's like 6 for me

#

6pm

vagrant cliff
vagrant cliff
#

@craggy blade u awake?

#

ill work on ur game a bit

vagrant cliff
#

@craggy blade i jus got on th game, i added a to-do list so u can put in ur stuff, i find it kinda helpful, u dont need to use it but still

craggy blade
#

mb i feel asleep

#

gtg to school

vagrant cliff
carmine ivyBOT
#

studio** You are now Level 6! **studio

craggy blade
#

im back from school

craggy blade
#

@vagrant cliff

#

wanna work on the game later?

craggy blade
#

@vagrant cliff

vagrant cliff
# craggy blade

Oh bru I was at school, do U wanna work on it over the weekends? Btw wts Ur time zone do we can find out a time to work on it together?

vagrant cliff
#

@craggy blade

vagrant cliff
#

I think

#

I forgor 💀

vagrant cliff
vagrant cliff
#

others

vagrant cliff
#

@craggy blade want to do it over the weekends when we're both on?

craggy blade
craggy blade
#

yeah

vagrant cliff