/** * Display the specified resource. * * @param int $id * * @return Response */ public function show($id) { $gameserver = Gameserver::find($id); return View::make('user.gameserver_show', ['gameserver' => $gameserver]); }
public function postStartAction($gsId) { $action = Input::get('action'); $gs = Gameserver::find($gsId); $scripts = $gs->game->scripts; $host = $gs->ipport->ip->ip . ':8080'; /** @var Script $script_f */ $script_f = null; foreach ($scripts as $script) { if ($script->type == $action) { $script_f = $script; } } return Redirect::action('ActionController@getPush')->with('action_data', [$script_f, $host]); }