Realistic Cooking System

I am currently in the progress of creating a cafe and wanted to make a realistic cooking system but I don’t really know where to begin with the scripting.

Could anyone please help with creating a system like that or linking me to a video displaying a system such as this as I can not seem to find one.

2 Likes

@RomanEmpireThe1st Well that would depend what are you cooking for popcorn you can use cframe and instances. But I dont exactly know what your looking for.

1 Like

So I’ve got a menu and was thinking of making the system to make the items on that menu.

I’ll attach photos of the menu below.
image
image
image

1 Like

Ok and do you have an example of how you want it to look cooking?

1 Like

Something like on RT2 with the animations that you get there while cooking something.

Well in RT2 the creator uses whats called Input service, so that way when you hit lets say F while cooking it does this.

keybindfunction

if key.Pressed == “F” then
stir:Play()
And so on.

1 Like

I don’t know how realistic you are aiming, but awhile back I made some pretty nifty “cooking” animations similar to the one below:

They did not take that long to make, nor was I an experienced animator by any means. All you need to do is have each component be separated (The lettuce/tomato objects have their slices unioned off) and animate them accordingly.

14 Likes

do you mean realistic as in good animations or realistic as in you’re literally cooking?

for literal cooking, using an oven/microwave (scripting it) would be pretty easy, however, as for cutting it may be a bit difficult. i would personally make a invisible brick that follows the player’s mouse (cutting board should be viewed top-down) and if it goes through the part fast enough it should create a thin negative part that is between the 2 points where the mouse collided and union with the other part(s) that were touched, seperating them. Once they are done cutting you could probably union all the pieces with eachother and save the object like that.

i don’t really know how someone would do this but its kinda how i think you could do them (dont know how to tackle using a frying pan, etc.)

I’m fairly sure that Restaurant Tycoon 2 uses context action service actually, but @Ultraw would have to confirm that.

Pros of ContextActionService

  • You can bind actions and unbind actions instead of if statements. ex.
--untested btw
local contextAction = game:GetService("ContextActionService")

contextAction:BindAction("Print key pressed", function(actionName, inputState, input)

end, false, Enum.KeyCode.W)
  • Its simpler to check what key was pressed if you’re only looking for one
  • tons of other stuff I don’t have time to list right now

Cons

  • I think there’s more input types in UserInputService but I don’t now :grimacing:
  • probably more I dont know of.

Conclusion

Bassically theres more pros than cons so I would suggest using context action service :slight_smile:

1 Like

ContextActionService and UserInputService both use the same input types, they aren’t different. ContextActionService boasts bindings as well as doing so at certain priorities, while UIS supports the majority of input-based functionality.

You can do pretty much anything with UserInputService that you can with ContextActionService, bar priority binding.

1 Like

I was thinking more microwave and oven than frying pan. Although I don’t know where to start really.

Well there arent any tutorials or resources abput any cooking system, you should be paying an scripter and animator.

A lack of resources exists because this is a very specific game system that only a small portion of games use or want and the games that do use them differ from each other widely.

No one should feel obligated to shell out money for scripters and animators when you can learn how to do that yourself. That’s why this thread exists.

2 Likes