我有點麻煩搞清楚如何匹配這個正則表達式模式。我想要做的是匹配技能名稱,而不是右側的描述。如何使用正則表達式匹配左側的文本?
Earthstone Creating a physical link to the powers of the earth.
Recall Earthstone Recalling the Earthstone to your hands.
Earthsense Seeing through darkness.
Walkwater Walking on water as if it were stone.
Hand of Eden Channeling powers of the earth.
Dustblast Blasting dust at someone.
Earthquake Creating an earthquake underneath someone.
Stonewall Creating a large wall of stone.
Earth Strength Protective earth magics.
Sandstorm Whipping up a great storm of sand.
Pelting Using the earth to stun your opponent.
Quicksand Causing the earth to take hold of someone.
Stone Encasing someone in stone.
Flesh Releasing someone from stone.
Rockstrike Pelting an enemy with rocks.
Tremor Causing target to lose balance or focus.
Stoneskin Turning your skin to stone.
Gravity Increasing the gravitational pull in an area.
Golem Summoning a stone golem to fight for you.
Pillar of Salt A huge pillar of salt to lift you out of danger.
Landslide Causing a devastating landslide.
Soul of Earth Drawing strength from mountains.
爲了進一步解釋,每個左邊的文本是一種技巧,右邊的句子是描述。我怎樣才能匹配技能?
正則表達式無法比擬不規則的文字。如果您使用'\ t'(製表符)分隔符,則可以在製表符之前獲取所有文本。 –
技能和描述之間的特徵是什麼?除非是空間以外的東西,否則看起來你運氣不好。 –
這是所有的空間,沒有選項卡。 –