-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.cpp
98 lines (89 loc) · 11.3 KB
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
#include <iostream>
#include "Utility/Paragraph.h"
#include "Utility/Text.h"
#include "Parser/Parser.h"
#include "Parser/TwitterParser.h"
#include "Indexer/Indexer.h"
#include "Scraper/Scraper.h"
std::string txt = "Earlier in the week we ran both words and video discussing and demonstrating the first hour of Arkane’s upcoming shoot-o-explorey game Prey [official site], but today we’re doing both. Here’s the first of two videos in which I commentate as I play through said opening hour, pointing out some of the details you or I might have missed and generally chatting about how it all works.\n"
"I don’t generally do much in the way of video, so please excuse its relative ramshackleness and the fact that I don’t holler WHAT’S UP GUYS on a regular basis. Relaxed Dad Plays Games Dot Com.\n"
"\n"
"Again, if you’d rather just watch the whole thing without some muttery European all over it, you can find that here. And all being well, part two of this will be up SOON™. Cheerio!\n"
"How can you kill a man? I don’t mean, how can you manage to do it then live with it, with yourself and with what society thinks of you. More like, what cool weapons and special abilities can you use? A new trailer for Mass Effect Andromeda [official site] answers that question for BioWare’s upcoming shoot-o-RPG. Demonstrating with gameplay snippets, it goes over how weapons from different places use different tech, how you’re free to use every weapon and learn every skill, and how you can cower behind anything you please. Have a look:\n"
"I dig that! It seems to have the not-awful action of Mass Effect 3 with more of the build choices and freedom from the first game. Heck, the open skill trees seem more free.\n"
"\n"
"BioWare have recently bopped up profiles of our future spacefriends, by the way. You can read all about Krogan brawler Nakmor Drack, Turian tank Vetra Nyx, Asari gunslinger Peebee, biotic human Cora Harper, and the jumpjetting Liam Kosta. You can meet ’em in this trailer too.\n"
"\n"
"Mass Effect Andromeda is due March 21st in North America and and other places but whaaat we need to wait, even buying digitally? Origin lists a UK release time of 11pm on March 22nd. Boo to that. This is total bobbins, Ian Arts.\n"
"With Aer still somehow not out yet, I needs me some more flying about a pretty place games. Spotting Copoka [Steam page] in the waterfall of Steam releases I wondered if it might keep me going. Not really, no. Here’s wot I think:\n"
"\n"
"Copoka ends up as one of those nice ideas that just doesn’t quite come together. I’ve argued before that there need to be far more games about flying around as a bird, so it would be churlish for me to entirely dismiss this. The problem is, there are too many problems, from the bugginess of the game, the lack of proper satisfaction with the flight controls, and a narrative concept that doesn’t hold together. On some levels I want to be more generous – this is a small indie game costing less than a pint of warm ale, and in many ways very pleasant. But on another I’m really annoyed by how it has described itself:\n"
"Now that’s game I wanted to play. That is not a description of Copoka. It is with some bitter irony that I notice the developers are called “Inaccurate Interactive”.\n"
"\n"
"This is in fact a very small enclosed city, which you can see all of from your starting point in the middle, with no meaningful notion of exploration at all. There’s nothing hidden, nothing revealed by looking over there, no openness in any understanding of the term. It feels like what might be the first level of a larger game, instead used four times in a row as the only level of a very small game. Again, small indie game – but bad description. But take that limited (although sprawling, and very lovingly detailed) city and then let me play as a bird seeking out sticks and twigs to build a nest! That sounds adorable and splendid. But it’s not that either. It’s in fact a game about flying toward building-sized sparkling lights around the city and picking up four lots of four shiny objects, and carrying them back to your already-built nest. Yes, one of these four madly twinkling objects in each round is a twig, but no, that’s not what was described. Along the way there are 12 bonus feathers to fly into, which speed you up (barely noticeably), but I found ten of these without trying, and an eleventh after a quick look.\n"
"\n"
"The real point to it all is to overhear conversations between denizens of the city as you float about. It seems there’s a fascistic leader in place in what appears to perhaps be a banana republic, with a burgeoning rebellion planning to rise up. Each time you collect four items the story advances forward (with no noticeable change beyond the conversations taking place), so you can listen in again by flying near clouds of white feathers. But fly away from them and they stop or fade out, which is utterly infuriating since there’s nothing to actually do during these unanimated chats. You just have to sit your bird there, being bored for a bit. The characters in the world are a lovely design, and the whole place is very pretty. It has some great music, and it plays in dynamically dependent upon where you’re flying in the city. But it’s glitchy as all hell, flight not letting you satisfactorily swoop and swish as you might like, with your bird unable to take off from far too many places it can land, and clearly there is such a high expectation that you’ll get stuck clipped into the world that it monitors for it and respawns you after a few seconds. But I think more problematic is the story, an attempt to, I dunno – discuss? – regime change and totalitarianism, but I guess the polite word to describe it is “sophomoric”. The more accurate might be “bad”. In the end, it felt to me more of a piece of apologism for a dictatorship! I think that might be more to do with being badly handled than deliberate political intent. But still.\n"
"\n"
"Again, so much of this criticism really wouldn’t feel relevant if the game’s own storefront (if it has its own website, I cannot find it) didn’t describe something totally other than what’s being sold. This is not an open world game, there’s absolutely no exploring, and you don’t gather twigs to build a nest.\n"
"\n"
"Copoka is out now for Windows via Steam for £3.20/$4/€4.\n"
"Have You Played? is an endless stream of game retrospectives. One a day, every day of the year, perhaps for all time.\n"
"\n"
"Despite not having previously felt as thought I needed one, I picked a Steam Link dirt-cheap in the sales, more out of curiosity than anything else. It’s pretty good – unless you try to use it over WiFi.\n"
"\n"
"I can only presume you know what a Steam Link is already, but just in case: it’s a small (about 6×4″) box that plugs into your telly and can stream games from your PC to said telly – i.e. for those situations where a really long HDMI cable just isn’t viable. Some PC games require a keyboard, mouse and hunched posture. Some PC games are better suited to sitting back on a sofa and looking at a big screen.\n"
"\n"
"I guess this is going to be more a piece of advice than a set of opinions. If you’re at all interested in a Steam Link, or Steam Home Streaming in general, be aware that you will almost certainly experience poor results if you try and play it over a wireless connection. What’s happening is that your PC is turning the game into a video stream on the fly, and as such it transmitting vast amounts of data constantly. You need a super-fast connection for that, and right now only a hard-wired ethernet cable can achieve that.\n"
"\n"
"Use a cable and the experience is so much better – a infinitely crisper picture, less lag, almost no sudden spikes or collapse into a mess of smeary shapes. And the Steam Link provides a mostly elegant Steam Big Picture UI for it too. When it works, it feels as though in-home streaming is a solved problem. When it doesn’t work, which is usually over wifi, it feels as though we’re light-years away from getting it right.\n"
"\n"
"These things are ace, but use a cable. Even if it means drilling. Trust me.\n"
"A dramatic new trailer for Warhammer 40,000: Dawn of War 3 [official site] is here, which means lots of Space Marines and Eldar wanking on about prophecies, some wandering world, the Spear of Khaine, lords, betrayal, and other gubbins until Orks roll up looking for “da pointy stikk.” Bless your murderous hearts, Orks. This cinematic-o-gameclip video introduces the broad story in Relic’s RTS and yes, it does basically boil down to finding a pointy stick. But what better item to fight over? If you can win a fight without a pointy stick, just imagine how powerful you’ll be once you get one!\n"
"I’m obviously a big fan of Orks in 40K, those fun-loving fungoid cockneys, but I do realise they need contrast. Without this Eldar warpwaffle and Space Marine duty bollocks, Orks would just be kooky. I want that spear too, I do. I hope it gives some wild stat bonuses. I would murder forty thousand people for a big damage bonus or stun.\n"
"\n"
"Anyway, here’s that prophecy from Farseer Taldeer:\n"
"\n"
"Fiery skies shall light the way\n"
"Blood shall spill over the wandering world\n"
"The spear of Khaine shall call the wayfarers\n"
"And the storm prince shall unite them.\n"
"\n"
"I dream of a future where the cyber becomes so fractured and divorced from context that this is seen as an actual prophecy. Some will see it as evidence of how quaint we were but others will treat it as actual prophecy from Olden Times when everyone was just so much more in tune with the universe. But which event will the futurefolk think this prophesies? Keep an eye on the news as the future unfolds, gang!\n"
"\n"
"In the short-term future, Dawn of War 3 is due later this year.\n"
"";
std::string txt2 = "Hi my name is. Hi your name is";
int main() {
Parser parser;
Text text = parser.parse(txt2);
Indexer indexer;
indexer.add(text);
std::vector<Word> words = indexer.getWordsLike(Word("my"));
std::cout << "Words like: i\n";
for(Word word : words){
std::cout << word.getWord() << " \n";
}
std::cout << std::endl;
Scraper scraper = Scraper();
//std::string res = scraper.scrape("www.stream.twitter.com/1.1/statuses/sample.json");
//1.1/statuses/sample.json
//API KEY:
//FkBVBjVaM436y6kH0IID2RvUU
//API SECRET:
//0ioiwnidfN2qdCrIXtCiHvcRQXB8nYy5HypPIUMh8fhlBL0OcP
//ACCESS TOKEN:
//3254148759-4MK41JN673vq8YAUN740YZsybBfaCiHakkT7vq7
//ACCES TOKEN SECRET
//HMhx2BzSPsFjQauSfmmiOcG04nOZ12kCL5lhqGmnO0rZA
//std::string ret = scraper.scrape("www.stream.twitter.com", "/1.1/statuses/sample.json");
std::string ret = scraper.scrape("www.stream.twitter.com", "/");
std::cout << ret << std::endl;
return 0;
TwitterParser tParser;
std::string res = scraper.search("trump");
std::cout << res << std::endl;
Text txt = tParser.parse(res);
std::cout << txt.to_string() << std::endl;
// std::cout << "\n\n\n\n\nResponse: " << res << std::endl;
return 0;
}