Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » how do i make a sliding fnaf office?
- hatdevo
-
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
-
500+ posts
how do i make a sliding fnaf office?
its pretty easy just do this for the office:
same thing for the other side except invert the numbers
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
-
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
-
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.
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
-
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…
when [ right arrowv] key pressed
if <(x position) < [number]> then
change x by (10)
end
- qwertycodechamp90411
-
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
-
91 posts
how do i make a sliding fnaf office?
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. Be careful and try to avoid actually
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
-
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
-
30 posts
how do i make a sliding fnaf office?
a simple scrolling script could be
or if you want it to really look like fnaf
i also have a project on my profile incase you are confused
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
-
1 post
how do i make a sliding fnaf office?
i need help you can see the edges of my office any sugestions
- imnotveteran
-
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
-
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]
- Discussion Forums
- » Help with Scripts
-
» how do i make a sliding fnaf office?