Discuss Scratch

hatdevo
Scratcher
2 posts

how do i make a sliding fnaf office?

just wondering! im making my own scratch fnaf fan game, but i dont know how to make a sliding office.
Masterscratch1117
Scratcher
500+ posts

how do i make a sliding fnaf office?

its pretty easy just do this for the office:
when [ right arrowv] key pressed
if <(x position) < [number]> then
change x by (10)
end

same thing for the other side except invert the numbers
hatdevo
Scratcher
2 posts

how do i make a sliding fnaf office?

Thanks but can you also tell me how to do it with the cursor?

Last edited by hatdevo (Sept. 13, 2023 02:35:22)

INSERT-USER_NAME
Scratcher
1000+ posts

how do i make a sliding fnaf office?

Huh, that's funny, I'm doing the same thing, small world I guess.

I managed to get mine working, and it was fairly simple, you can use it if you want. and you don't need to give credit

Also, please note that if you decide to use a different office, you may need to change a few things regarding the size and how far the office can go (the aforementioned is in the “move” custom block)

Oh, and there may be some unused code and useless variables, I just copied the project I was working on and deleted everything but the office sprite.

Last edited by INSERT-USER_NAME (Sept. 13, 2023 02:51:36)

Skmish
Scratcher
85 posts

how do i make a sliding fnaf office?

Yeah pretty much everyone else is saying this but, you need to make a sprite just a tiny bit bigger than the stage itself and have it be controlled by either mouse movements or arrow keys by using the script this guy made…

Masterscratch1117 wrote:

when [ right arrowv] key pressed
if <(x position) < [number]> then
change x by (10)
end
qwertycodechamp90411
Scratcher
100+ posts

how do i make a sliding fnaf office?

Be careful and try to avoid actually mentioning fnaf. Correct me if I'm wrong, but I'm pretty sure scratch banned fnaf projects.
JacksterBobster
Scratcher
91 posts

how do i make a sliding fnaf office?

qwertycodechamp90411 wrote:

Be careful and try to avoid actually mentioning fnaf. Correct me if I'm wrong, but I'm pretty sure scratch banned fnaf projects.
Don't worry, they didn't. They said that as long as the projects are made to be friendly to all users (no violence, gore, etc.) then the projects are okay.

Anyway, I have a solution to this:

forever
if <(mouse x) > [200]> then //change this to adjust where the mouse needs to be to scroll
change [office x v] by (20) //change this to make it scroll faster
end
if <(mouse y) < [-200]> then
change [office x v] by (20)
end
set x to ((0) - (office x))
end

All you need to do now is make sure that the office sprite is large enough to scroll like this and to put a limit on the office x variable so that the scrolling stops at the edges.
Masterscratch1117
Scratcher
500+ posts

how do i make a sliding fnaf office?

ohh maybe
when green flag clicked
forever
if <([x pos v] of [mouse sprite v]) < [0]> then
if <[x positon]> < [number]> then
change x by (10)
end
end
end
Tanuki-T
Scratcher
30 posts

how do i make a sliding fnaf office?

a simple scrolling script could be

when I receive [gamestart]
forever
set x to ((mouse x) * (modify -0.1 till it looks good))
end

or if you want it to really look like fnaf

when I receive [gamestart]
forever
change x by ((mouse x) * (modify -0.1 till it looks good))
if <(x position) > [left of office]> then
set x to (left of office)
end
if <(x position) > [right of office]> then
set x to (right of office)

i also have a project on my profile incase you are confused

Last edited by Tanuki-T (Sept. 13, 2023 15:46:37)

alvinmetaltalon
Scratcher
1 post

how do i make a sliding fnaf office?

i need help you can see the edges of my office any sugestions
imnotveteran
Scratcher
16 posts

how do i make a sliding fnaf office?

ill need it for my next fnaf game
say [how my name says, im not veteran on scratch] for (2) secs
imnotveteran
Scratcher
16 posts

how do i make a sliding fnaf office?

when green flag clicked
say [idk what im doing] for (2) secs
switch backdrop to [office v]

Powered by DjangoBB