[Solved]Could not create cutscene controller

Place to get help with not working mods / modding interface.
Post Reply
User avatar
WIZ4
Fast Inserter
Fast Inserter
Posts: 209
Joined: Thu Apr 07, 2016 1:36 pm
Contact:

[Solved]Could not create cutscene controller

Post by WIZ4 »

I'm trying to create a cutscene:

Code: Select all

function cutscene(player)
	local waypoint = {
	position = {x=100,y=100},
	transition_time = 1000,
	time_to_wait = 1000
	}
	player.set_controller{  --line 546
		type = defines.controllers.cutscene,
		waypoints = waypoint, 
		final_transition_time = 1000}
And when I call this function, I get an error:

Code: Select all

/c cutscene(game.player)
Screenshot_6.jpg
Screenshot_6.jpg (45.9 KiB) Viewed 730 times
What is wrong with the position provided?
Last edited by WIZ4 on Tue Apr 02, 2019 12:44 pm, edited 1 time in total.
My native language is russian. Sorry if my messages are difficult to read.

User avatar
WIZ4
Fast Inserter
Fast Inserter
Posts: 209
Joined: Thu Apr 07, 2016 1:36 pm
Contact:

Re: Could not create cutscene controller

Post by WIZ4 »

I forgot to put a waypoint in the table. Problem solved

Code: Select all

	local waypoint = {{
		position = {x=90,y=89},
		transition_time = 1000,
		time_to_wait = 1000
	}}
My native language is russian. Sorry if my messages are difficult to read.

Post Reply

Return to “Modding help”