Was she simply in the wrong place at the wrong time and got killed accidentally when the basilisk emerged from the plumbing or was it intentional, with Tom leading the basilisk to her?
I believe she was just at the wrong place at the wrong time. Tom M. Riddle didn't expect anyone to be in the toilet as he opened the passageway to the Chamber of Secrets. When Myrtle asked him to leave since she had heard a boy's voice, she saw two yellow eyes and died.
“Oh, it’s you,” she said when she saw Harry. “What do you want this time?”
“To ask you how you died,” said Harry.
Myrtle’s whole aspect changed at once. She looked as though she had never been asked such a flattering question.
“Ooooh, it was dreadful,” she said with relish. “It happened right in here. I died in this very stall. I remember it so well. I’d hidden because Olive Hornby was teasing me about my glasses. The door was locked, and I was crying, and then I heard somebody come in. They said something funny. A different language, I think it must have been. Anyway, what really got me was that it was a boy speaking. So I unlocked the door, to tell him to go and use his own toilet, and then —” Myrtle swelled importantly, her face shining. “I died.”
“How?” said Harry.
“No idea,” said Myrtle in hushed tones. “I just remember seeing a pair of great, big, yellow eyes. My whole body sort of seized up, and then I was floating away. …”
Also Tom was a very intelligent and calculating person. He would never kill someone at the very entrance of the CoS, resulting in him abandoning years spent searching for the place.
It is also shown that he needed to fix the current situation without previous planning when confronted with closing down the school.
Riddle slid off his chair and slouched out of the room. Harry followed him.
Down the moving spiral staircase they went, emerging next to the gargoyle in the darkening corridor. Riddle stopped, and so did Harry, watching him. Harry could tell that Riddle was doing some serious thinking. He was biting his lip, his forehead furrowed.
Then, as though he had suddenly reached a decision, he hurried off
The implication (from Pottermore) is that her death was best described as murder, albeit also accidental.
Riddle released the Basilisk from the Chamber of Secrets with the intention of allowing it to kill. Myrtle wasn't its intended victim, but I think we can assume that Riddle wasn't disappointed since she fit the criteria he was looking for (e.g. Muggle-born) and which allowed him to create his first Horcrux.
It's here that she ran into Voldemort himself, Tom Riddle, who she overheard speaking Parseltongue in order to open the Chamber, which was hidden behind the sinks. Thinking that Riddle was intruding in the girls' bathroom, she opened the stall door to tell him off – only to be confronted with the Chamber of Secrets' Basilisk, whose eyes killed her instantly.
Likely - Riddle was usually more careful.
Though she was a Muggle-born, and thus the type of student he would want to attack, Riddle was usually quite careful to not be caught in his illicit activities.
“Rigidly controlled by Riddle, they were never detected in open wrong-doing, although their seven years at Hogwarts were marked by a number of nasty incidents to which they were never satisfactorily linked, the most serious of which was, of course, the opening of the Chamber of Secrets, which resulted in the death of a girl.”
- Harry Potter and the Half-Blood Prince, Chapter 17 (A Sluggish Memory)
Killing someone right near the entrance to the Chamber of Secrets was extremely risky, as the location of the death would be more likely to lead Hogwarts staff to discover the Chamber. In fact, this is how Harry and Ron found it. Because she died right near it, Myrtle was able to point them right to the entrance.
“Where exactly did you see the eyes?’ said Harry.
‘Somewhere there,’ said Myrtle, pointing vaguely towards the sink in front of her toilet.
Harry and Ron hurried over to it. Lockhart was standing well back, a look of utter terror on his face. It looked like an ordinary sink. They examined every inch of it, inside and out, including the pipes below. And then Harry saw it: scratched on the side of one of the copper taps was a tiny snake.
‘That tap’s never worked,’ said Myrtle brightly, as he tried to turn it.”
- Harry Potter and the Chamber of Secrets, Chapter 16 (The Chamber of Secrets)
This would be a terrible choice for a planned kill. Therefore, it makes more sense that Riddle had expected to be alone in the bathroom and Myrtle was just unfortunate enough to be in it at the time he was attempting to open the Chamber.