I need an answer because I am a beginner. And I got the players handbook and it does not say a thing about this.
The GM isn't on a team, they’re the referee.
The way Pathfinder, D&D, and similar games work is that there are one or more player characters (the "party") that are controlled by the players.
The GM (DM, in D&D) usually doesn't run a player character (PC), but they are responsible for representing all aspects of the world, all the non-player characters (NPCs) and monsters and stuff, and adjudicating the rules.
So the GM may be controlling a character or creature that is friendly to the PCs, or a character or creature that is hostile to the PCs, or both at once! The GM is the orcs you fight and the friendly cleric that heals you and the rain that falls on you.
GMs aren't supposed to be hostile to you in general; they are generally taught to give the players a fun challenge. It's no good to be "against" the players, because you can always kill PCs just by saying "rocks fall, everyone dies!" The GM is on your team inasmuch as they want everyone to have fun. Because their role is running monsters and the other stuff that you fight, they are often in opposition to you tactically, as they are responsible for the "other team" as part of their job. Some new GMs do get confused by this and decide it's them against the party, but that ends up being a problem that has to be solved by them wising up or their players leaving.
The context of your question isn't clear, so I'll add a note that might be relevant - some GMs, especially new ones, do run a PC of their own that's part of the party, these are referred to as GMPCs (or DMPCs). This is generally frowned upon because of the conflict of interest inherent in doing it, but it happens. That GMPC may be on your side, on your side most of the time, betray you, have other plans - just like any other person in the game world might.
In the sense that everyone wants to have fun, then yes, the GM and players are on the same side. Sometimes you'll find the DM (if they are newer) has the belief that they are AGAINST the players and out to kill them. This can dampen the fun for everyone involved.
Think of it more like the DM is trying to detail a world in which the players have the freedom to roam and have adventures. The goal of a good DM is to let everyone shine and experience the world through their characters eyes.
The GM/DM is the game
No, the DM is not in the same team as you. The DM is in no team at all. He is the world you (your characters) breathe in. You describe what you want to do in that world, the DM will give you the result of your action. He will also give you all possible extra information you might ask him. Because the monsters and NPCs are part of this world, the DM will also be the one to control the monsters and NPCs.
The monsters will usually want to kill your PC, however this does not mean the DM is on the opposing team! His task is to make a fun and challenging game for his players, but also to stick to the rules. So he is also the referee for the game.
Players yes, characters no.
The players and the GM are all on the same team - they are a group that is enjoying the game together, and the actions of everyone should be aligned to that goal.
That does not mean, however that the characters that the players play cannot suffer setbacks, defeat and death. Just like a movie would be boring without the heroes struggling and having to overcome challenges - and in many of the best movies having much of the movie world being against them - the game world is not the characters' friend.
But in the real world, around the gaming table, everyone works towards the same goal - a great enjoyable evening. It's just that the GM's role is different from that of the players.
The GM is no more or less on the players' team than the author of a novel is on their protagonists' team
The GM's and players' interests are aligned on the large scale, in the sense that all want a fun/engaging game experience (presumably).
The GM's and players' interests are not aligned on the small scale, in the sense that the GM will resolve actions, take decisions on behalf of monsters/NPC's without regard to what the players would like, based on what makes sense in the world they've created.
The GM fulfills multiples roles during the game
I'll use a combat encounter as an example, though the principle applies equally in all areas of the game:
I'm a GM planning their adventure, and I've decided that there is a goblin tribe hiding in the ruins the party are exploring. How many goblins? There could be 5 or 50. But I want the players to be able to fight and win, so I decide that this particular tribe is closer to 5 than to 50 in number. I do this because I'm wearing my prepare a game experience that will be fun for everyone-hat: if I were 'on the players' team' I would put in no goblins at all and place unguarded treasure instead (boring to play: not fun), and if I were against them I would put in a thousand unkillable hell-demons instead of a few goblins (killing them instantly: not fun). I do neither of those things, because I am neither for nor against the players: I am for an enjoyable game experience, which generally means challenging but beatable (or whatever effect you're going for in the specific scene).
Later, I'm running the adventure and my players have encountered the goblins. When it is the goblins' turn in combat, I don my play the villains as though they're trying to win-hat: when the goblins take their actions, they will do everything they can (within the rules of the game and within the limits of what the goblins could actually do within the game world) to kill the player characters (or drive them off, or escape from them, or whatever the goblins are trying to accomplish in this scene). It's not that I, the GM, am trying to beat the players. Rather, the goblins are trying to beat the characters, and I play them to the best of my ability.
One of the players - a wizard - takes their turn. They cast a fireball spell at a goblin, but their target happens to be nearly submerged in a pool of standing water. Does it work, or fizzle out? The rules don't specifically say. I don't immediately rule 'Yes, the fireball works as normal because the rules don't specify that it doesn't' (siding with the players) or 'No, fire doesn't burn underwater' (siding against them). I put on my resolve actions and interpret the rules-hat instead and consider the issue. What makes sense in a believable game world? Will the player feel cheated if an option they chose doesn't work as intended? Will either of the options make fireball significantly more or less powerful than the game designers intended? Are there any alternatives I could consider (e.g. let the fireball work but do only half damage)? Any or all of these might factor into my decision.
As a GM you wear many hats. I hope this about clears up which 'team' each of them puts you on!
The answer is "it depends on how you look at it."
At the highest, and possibly most important level, you, the DM, and all the other players want to work together to create an enjoyable experience. At that level they are on your team. If people aren't having fun, they pick up their ball and play with someone else.
And that's where the simple answers end. Because what we have found over thousands and thousands of years of storytelling is that people like conflict. It is likely possible to have enjoyable games without conflict, but it is something we crave. Thus we invent major classes of stories built around conflict. We have "man vs. man" stories such as the struggle vs the Wicked Witch of the West in The Wizard of Oz. We have games that parallel this, such as Chess and Go. We have "man vs. himself" stories such as fight club, where the conflict is within. The Game† is an excellent example of that. And, of course, there is "man vs. nature" where the heroes go up against the forces of an entire world.
And to that end, the DM takes on the duty of creating and shaping conflict. All of it. And upon taking on this scared duty, they cease to be your friend. We love them for not being our friend. Some of them are very good at it.
I think we all try to grapple with this in our own ways. As a computer engineer by trade, I naturally use computers in my metaphors. There's a very important concept in computer science called Turing Completeness. It's an important classification marking how powerful a particular programming language is. However, once you achieve it, there are some painful side effects. It's often very desirable to know whether your program will halt after a while, or if it will process for eternity, never ceasing (until you accidentally trip over the power cable). Many programs we can prove halt. Many programs we can prove loop endlessly. However, there's a class of them which are incredibly hard to prove one way or the other. You are left pondering whether you might have guessed wrong.
The DM is the same way. It's easy to DM in a way which makes you too friendly. It's easy to DM in a way which makes you the enemy of everyone else at the table. But the good DMs make it hard for you to tell. They sit in the grey area between friend and foe, and then ask you to put your life on the line and roll the dice.
I choose the computer science metaphor because it provides a fun twist. It turns out that there are a class of programs that you cannot decide whether they halt or run forever. You can mathematically prove that you cannot decide them one way or another. They are known as "undecidable" programs, and every Turing Complete language has them.
In that grey area between friend and foe, on your team or against your team, there is a fine line where the DM simply isn't provably either. They defy being put into the bin of friend or foe. They must be put in a third bin, and that's where the real fun starts.
†. I have lost the game.
The DM is an interface between the players and the game. He is not the game or the world,. He is neither a player or a teammate.
Without the DM, you would just have boring hardware in the form of rules books, written stories, dices and characters sheets.
The DM is the one person who run the game and handle world, entities and players interactions by the rules and on the story-line. He is:
- The sense of the players (see, touch, hear...)
- The voice of NPC entities
- The motion of things and livings
- The wind in the branches
- The twittering of birds
- The spirit and the mean of everything in the game
- The guardian of the rules
but most importantly and ideally, the DM is:
- A minded and friendly director, who is committed to ensuring that players have fun while respecting the rules and the story he or she has designed and tells.
The later is what distinguishes the most, a DM from an MMORPG computer game engine.
The Game Master isn't exactly on a team, they're more like a combined narrator and arbiter. They have a responsibility to run the game. A good GM will make sure that everyone has fun, and that the players have agency (that their choices and actions have meaningful outcomes). From the Pathfinder RPG Database:
The Pathfinder Roleplaying Game is a tabletop fantasy game in which the players take on the roles of heroes who form a group (or party) to set out on dangerous adventures. Helping them tell this story is the Game Master (or GM), who decides what threats the player characters (or PCs) face and what sorts of rewards they earn for succeeding at their quest. Think of it as a cooperative storytelling game, where the players play the protagonists and the Game Master acts as the narrator, controlling the rest of the world.
According to d20pfsrd, the GM has a number of roles:
- World Builder
- Story Teller
- Game Designer
I haven't played Pathfinder myself (unless you count the Kingmaker game), but Dungeons & Dragons is pretty similar:
- The DM describes the environment.
- The players describe what they want to do.
- The DM narrates the results of their actions.
If you are unfortunate, your GM may be opposed to you. Although I have not had to deal with this personally, I have heard of cases where the GM just seems to be trying to kill the player's characters (I'm guessing Tomb of Horrors is a good example of this).
The GM and Players play together to have fun. So, in that sense, they are on the same team. But, the adventure is ultimately about the Players / Player Characters. So, the GM is a passive-supporter of the Players, in that the GM is providing the struggle the Players have to work through, but is trying to make it a rewarding experience. Hence, the GM may fudge dice rolls that could be seen as unfair or just out-right ruining of the adventure.
The problem is that some GM's get ego's, and think they're directors trying to force the players to act out certain scenes in a play. That's wrong.
Another is the GM thinking the goal is for the Player Characters to just become gods. So, they shovel riches on them and don't challenge them. That's also wrong.
It's a steady balance.
The GM provides the world and the RNG'ing in that world to counter the Players having control over characters. The GM ultimately wants the players to have a good time, but may have to make a decision the players won't like.
You could also view this from Player-to-Player...
Are the players on the same team? Yes, in the sense that they should be trying to create an enjoyable experience for each other.
But, in the game world, one player's character may be stealing and back-stabbing the party. If it's just to be a dick, then it's not enjoyable. But, if there's a valid reason (maybe they're possessed, maybe they're stealing from the party to save them from something else, IE: bad actions with good intentions) it can be enjoyable when others find out.
Ultimately, you can think of gaming as the GM helping the Players write their Characters' story. The GM is a facilitator, so they do help the players and root for them. But, it's their job to challenge them, too.