国产精品天干天干,亚洲毛片在线,日韩gay小鲜肉啪啪18禁,女同Gay自慰喷水

歡迎光臨散文網(wǎng) 會(huì)員登陸 & 注冊(cè)

【ME】|≡]| 腳本

2022-12-02 12:55 作者:--Reisen--  | 我要投稿

可以自由使用,但請(qǐng)注明來源,遵守 License。

AvZ 版本:avz1 221001

/*
MIT License

Copyright (c) 2022 Reisen

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/

#include "avz.h"
#include "avz_more.h"
#include "showme/sm.h"

// ----------------------------------------------------------------
#include <algorithm>
#include <cmath>
#include <set>
#include <utility>
#include <vector>
#include "avz.h"
#include "GetZombieAbscissas.h"

using namespace AvZ;

namespace __cob_manager_internal {
struct cob_list_t {
 ? ?private:
 ? ?int type;

 ? ?public:
 ? ?Grid pos;
 ? ?int col;

 ? ?cob_list_t(Grid g) : type(0), pos(g) {}
 ? ?cob_list_t(int r, int c) : type(0), pos({r, c}) {}
 ? ?cob_list_t(int c) : type(1), col(c) {}

 ? ?bool is_pos() const { return type == 0; }
 ? ?bool is_col() const { return type == 1; }
};

using p_row_t = unsigned;
using pd_row_t = double;
using col_t = float;

const int garg_x[387] = {845, 844, 844, 844, 843, 843, 843, 842, 842, 842, 841, 841, 841, 840, 840, 840, 840, 839, 839, 839, 838, 838, 838, 837, 837, 837, 836, 836, 836, 836, 835, 835, 835, 834, 834, 834, 833, 833, 833, 832, 832, 832, 832, 831, 831, 831, 830, 830, 830, 829, 829, 829, 828, 828, 828, 828, 827, 827, 827, 826, 826, 826, 825, 825, 825, 825, 824, 824, 824, 823, 823, 823, 822, 822, 822, 822, 821, 821, 821, 821, 821, 820, 820, 820, 820, 820, 819, 819, 819, 819, 819, 818, 818, 818, 818, 818, 817, 817, 817, 817, 816, 816, 816, 816, 816, 815, 815, 815, 815, 815, 814, 814, 814, 814, 814, 813, 813, 813, 813, 813, 812, 812, 812, 812, 812, 811, 811, 811, 811, 811, 810, 810, 810, 810, 810, 809, 809, 809, 809, 809, 808, 808, 808, 808, 808, 807, 807, 807, 807, 806, 806, 806, 805, 805, 805, 805, 804, 804, 804, 803, 803, 803, 802, 802, 802, 802, 801, 801, 801, 800, 800, 800, 799, 799, 799, 799, 798, 798, 798, 797, 797, 797, 796, 796, 796, 796, 795, 795, 795, 794, 794, 794, 793, 793, 793, 793, 792, 792, 792, 791, 791, 791, 790, 790, 790, 789, 789, 789, 789, 789, 789, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 786, 786, 786, 786, 786, 786, 786, 786, 786, 786, 786, 786, 786, 785, 785, 785, 785, 785, 785, 785, 785, 784, 784, 784, 784, 784, 784, 784, 784, 784, 783, 783, 783, 783, 783, 783, 783, 783, 782, 782, 782, 782, 782, 782, 782, 782, 782, 781, 781, 781, 781, 781, 781, 781, 781, 781, 780, 780, 780, 780, 780, 780, 780, 780, 779, 779, 779, 779, 779, 779, 779, 779, 779, 778, 778, 778, 778, 778, 778, 778, 778, 777, 777, 777, 777, 777, 777, 776, 776, 776, 776, 776, 776, 775, 775, 775, 775, 775, 775, 774, 774, 774, 774, 774, 774, 773, 773, 773, 773, 773};
}; // namespace __cob_manager_internal

__cob_manager_internal::p_row_t operator "" _r(unsigned long long x) { return x; }
__cob_manager_internal::pd_row_t operator "" _r(long double x) { return x; }
__cob_manager_internal::col_t operator "" _c(long double x) { return x; }
__cob_manager_internal::col_t operator "" _c(unsigned long long x) { return x; }

enum BehaviorWhenFail {
 ? ?RAISE_ERROR,
 ? ?WAIT_UNTIL_RECOVER
};

struct PDArgs {
 ? ?int t1, t2;
 ? ?__cob_manager_internal::pd_row_t rows;
 ? ?__cob_manager_internal::col_t col1 = 9, col2 = -1;
};

class CobManager {
 ? ?private:
 ? ?PaoOperator po;
 ? ?std::vector<__cob_manager_internal::cob_list_t> cob_list;
 ? ?int last_refresh_cob_list = 0;
 ? ?using rc_t = std::pair<int, float>;
 ? ?using p_row_t = __cob_manager_internal::p_row_t;
 ? ?using pd_row_t = __cob_manager_internal::pd_row_t;
 ? ?using col_t = __cob_manager_internal::col_t;

 ? ?void refresh_cob_list() {
 ? ? ? ?InsertOperation([this](){
 ? ? ? ? ? ?if(last_refresh_cob_list == GetMainObject()->gameClock())
 ? ? ? ? ? ? ? ?return;
 ? ? ? ? ? ?InsertGuard _(false);
 ? ? ? ? ? ?std::set<Grid> fixed_cobs;
 ? ? ? ? ? ?for(auto c : cob_list)
 ? ? ? ? ? ? ? ?if(c.is_pos())
 ? ? ? ? ? ? ? ? ? ?fixed_cobs.insert(c.pos);
 ? ? ? ? ? ?std::set<int> cobs[8];
 ? ? ? ? ? ?for(auto& p : alive_plant_filter)
 ? ? ? ? ? ? ? ?if(p.type() == COB_CANNON)
 ? ? ? ? ? ? ? ? ? ?cobs[p.col()].insert(p.row() + 1);
 ? ? ? ? ? ?std::vector<Grid> pao_list;
 ? ? ? ? ? ?for(auto c : cob_list)
 ? ? ? ? ? ? ? ?if(c.is_pos() && cobs[c.pos.col - 1].count(c.pos.row))
 ? ? ? ? ? ? ? ? ? ?pao_list.push_back(c.pos);
 ? ? ? ? ? ? ? ?else if(c.is_col())
 ? ? ? ? ? ? ? ? ? ?for(auto r : cobs[c.col - 1])
 ? ? ? ? ? ? ? ? ? ? ? ?if(!fixed_cobs.count({r, c.col}))
 ? ? ? ? ? ? ? ? ? ? ? ? ? ?pao_list.push_back({r, c.col});
 ? ? ? ? ? ?po.resetPaoList(pao_list);
 ? ? ? ? ? ?last_refresh_cob_list = GetMainObject()->gameClock();
 ? ? ? ?});
 ? ?}

 ? ?int get_launch_time(int row) {
 ? ? ? ?if(RangeIn(GetMainObject()->scene(), {4, 5}))
 ? ? ? ? ? ?return 387;
 ? ? ? ?else if(RangeIn(GetMainObject()->scene(), {2, 3}))
 ? ? ? ? ? ?return RangeIn(row, {3, 4}) ? 378 : 373;
 ? ? ? ?else
 ? ? ? ? ? ?return 373;
 ? ?}

 ? ?void launch(int row, float col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?refresh_cob_list();
 ? ? ? ?po.setNextPao(1);
 ? ? ? ?if(b == WAIT_UNTIL_RECOVER)
 ? ? ? ? ? ?po.recoverPao(row, col);
 ? ? ? ?else if(RangeIn(GetMainObject()->scene(), {4, 5}))
 ? ? ? ? ? ?po.roofPao(row, col);
 ? ? ? ?else
 ? ? ? ? ? ?po.pao(row, col);
 ? ?}

 ? ?std::vector<int> parse_rows(p_row_t rows) {
 ? ? ? ?std::vector<int> result;
 ? ? ? ?while(rows) {
 ? ? ? ? ? ?result.push_back(rows % 10);
 ? ? ? ? ? ?rows /= 10;
 ? ? ? ?}
 ? ? ? ?std::reverse(result.begin(), result.end());
 ? ? ? ?return result;
 ? ?}

 ? ?std::pair<p_row_t, p_row_t> parse_rows_pd(pd_row_t rows) {
 ? ? ? ?unsigned p_rows = rows, n = log10(p_rows) + 1;
 ? ? ? ?auto d_rows = llround((rows - p_rows) * pow(10, 12 - n));
 ? ? ? ?while(d_rows && d_rows % 10 == 0)
 ? ? ? ? ? ?d_rows /= 10;
 ? ? ? ?return {p_rows, d_rows};
 ? ?}

 ? ?void launch_smart_d(int row) {
 ? ? ? ?InsertOperation([=](){
 ? ? ? ? ? ?auto mo = GetMainObject();
 ? ? ? ? ? ?int delay_t = get_launch_time(row);
 ? ? ? ? ? ?int col = 773 - 126;
 ? ? ? ? ? ?if(mo->refreshCountdown() <= 200)
 ? ? ? ? ? ? ? ?col = __cob_manager_internal::garg_x[delay_t - mo->refreshCountdown()] - 126;
 ? ? ? ? ? ?else
 ? ? ? ? ? ? ? ?for(auto& z : alive_zombie_filter)
 ? ? ? ? ? ? ? ? ? ?if(z.type() == GIGA_GARGANTUAR &&
 ? ? ? ? ? ? ? ? ? ? ? z.standState() == mo->wave() &&
 ? ? ? ? ? ? ? ? ? ? ? row - 2 <= z.row() && z.row() <= row) {
 ? ? ? ? ? ? ? ? ? ? ? ?auto x = GetZombieAbscissas((Zombie*)&z - mo->zombieArray(), delay_t);
 ? ? ? ? ? ? ? ? ? ? ? ?if(x.empty())
 ? ? ? ? ? ? ? ? ? ? ? ? ? ?continue;
 ? ? ? ? ? ? ? ? ? ? ? ?col = std::min(col, int(x[delay_t]) - 126);
 ? ? ? ? ? ? ? ? ? ?}
 ? ? ? ? ? ?launch(row, col / 80.0);
 ? ? ? ?});
 ? ?}

 ? ?public:
 ? ?CobManager(const std::vector<__cob_manager_internal::cob_list_t>& c = {1, 2, 3, 4, 5, 6, 7, 8}) : cob_list(c) {}

 ? ?// In Queue
 ? ?void set_cob_list(const std::vector<__cob_manager_internal::cob_list_t>& c) {
 ? ? ? ?InsertOperation([=](){ cob_list = c; });
 ? ?}

 ? ?// In Queue
 ? ?void operator()(p_row_t rows, col_t col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?for(auto r : parse_rows(rows)) {
 ? ? ? ? ? ?Delay(-get_launch_time(r));
 ? ? ? ? ? ?if(col >= 0)
 ? ? ? ? ? ? ? ?launch(r, col, b);
 ? ? ? ? ? ?else
 ? ? ? ? ? ? ? ?launch_smart_d(r);
 ? ? ? ? ? ?Delay(get_launch_time(r));
 ? ? ? ?}
 ? ?}

 ? ?// In Queue
 ? ?void operator()(std::vector<rc_t> rcs, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?for(auto rc : rcs)
 ? ? ? ? ? ?operator()(rc.first, rc.second, b);
 ? ?}

 ? ?// In Queue
 ? ?void p(int time, int wave, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?SetTime(time, wave);
 ? ? ? ?operator()(RangeIn(GetMainObject()->scene(), {2, 3}) ? 25 : 24, 9);
 ? ?}

 ? ?// In Queue
 ? ?void p(int time, int wave, p_row_t rows, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?SetTime(time, wave);
 ? ? ? ?operator()(rows, 9, b);
 ? ?}

 ? ?// In Queue
 ? ?void p(int time, int wave, col_t col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?SetTime(time, wave);
 ? ? ? ?operator()(RangeIn(GetMainObject()->scene(), {2, 3}) ? 25 : 24, col, b);
 ? ?}

 ? ?// In Queue
 ? ?void p(int time, int wave, p_row_t rows, col_t col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?SetTime(time, wave);
 ? ? ? ?operator()(rows, col, b);
 ? ?}

 ? ?// In Queue
 ? ?void d(int time, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?Delay(time);
 ? ? ? ?operator()(RangeIn(GetMainObject()->scene(), {2, 3}) ? 14 : 15, -1, b);
 ? ?}

 ? ?// In Queue
 ? ?void d(int time, p_row_t rows, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?Delay(time);
 ? ? ? ?operator()(rows, -1, b);
 ? ?}

 ? ?// In Queue
 ? ?void d(int time, col_t col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?Delay(time);
 ? ? ? ?operator()(RangeIn(GetMainObject()->scene(), {2, 3}) ? 14 : 15, col, b);
 ? ?}

 ? ?// In Queue
 ? ?void d(int time, p_row_t rows, col_t col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?Delay(time);
 ? ? ? ?operator()(rows, col, b);
 ? ?}

 ? ?void pd(int t_, int d_, int wave, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?p(t_, wave, b);
 ? ? ? ?d(d_, b);
 ? ?}

 ? ?void pd(int t_, int d_, int wave, pd_row_t rows, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?auto rows_ = parse_rows_pd(rows);
 ? ? ? ?p(t_, wave, rows_.first, b);
 ? ? ? ?d(d_, rows_.second, b);
 ? ?}

 ? ?void pd(int t_, int d_, int wave, col_t col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?p(t_, wave, b);
 ? ? ? ?d(d_, col, b);
 ? ?}

 ? ?void pd(int t_, int d_, int wave, std::pair<float, float> col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?p(t_, wave, col.first, b);
 ? ? ? ?d(d_, col.second, b);
 ? ?}

 ? ?void pd(int t_, int d_, int wave, pd_row_t rows, col_t col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?auto rows_ = parse_rows_pd(rows);
 ? ? ? ?p(t_, wave, rows_.first, b);
 ? ? ? ?d(d_, rows_.second, col, b);
 ? ?}

 ? ?void pd(int t_, int d_, int wave, pd_row_t rows, std::pair<float, float> col, BehaviorWhenFail b = RAISE_ERROR) {
 ? ? ? ?auto rows_ = parse_rows_pd(rows);
 ? ? ? ?p(t_, wave, rows_.first, col.first, b);
 ? ? ? ?d(d_, rows_.second, col.second, b);
 ? ?}
};
// ----------------------------------------------------------------

using namespace std;
using namespace AvZ;

MainObject* mo;
class : GlobalVar {
 ? ?public:
 ? ?void beforeScript() {
 ? ? ? ?mo = GetMainObject();
 ? ?}
} __mo_manager;

template <class... Ts>
void Card(const vector<PlantType>& plant_types, Ts... args) {
 ? ?for(auto p: plant_types)
 ? ? ? ?Card(p, args...);
}

void Card(vector<PlantType> plant_types, vector<Position> args) {
 ? ?for(auto p: plant_types)
 ? ? ? ?Card(p, args);
}

CobManager wind({1, 3, 7, {3, 1}}), wind3({3, 1, 7, {3, 1}}), norm({7}), tbs({{3, 1}, 1, 3, 7});

/*
間C8u: IPP-PP|PP|IPP-PP|NDD*|PPDA|PPDc 1280|1318
*/

void Script() {
 ? ?OpenMultipleEffective('Q', MAIN_UI);
 ? ?SetZombies({ZOMBIE, POLE_VAULTING_ZOMBIE, ZOMBONI, POGO_ZOMBIE, JACK_IN_THE_BOX_ZOMBIE, LADDER_ZOMBIE, CATAPULT_ZOMBIE, GARGANTUAR, GIGA_GARGANTUAR});
 ? ?SelectCards({ICE_SHROOM, M_ICE_SHROOM, DOOM_SHROOM, CHERRY_BOMB, JALAPENO, FLOWER_POT, KERNEL_PULT, COB_CANNON, PUMPKIN, WALL_NUT});
 ? ?cresc::AverageSpawn({ZOMBIE, POLE_VAULTING_ZOMBIE, ZOMBONI, POGO_ZOMBIE, JACK_IN_THE_BOX_ZOMBIE, LADDER_ZOMBIE, FOOTBALL_ZOMBIE, CATAPULT_ZOMBIE, GARGANTUAR, GIGA_GARGANTUAR});
 ? ?SetTime(-599, 1); plant_fixer.start(PUMPKIN); plant_fixer.resetFixHp(4000 / 3);
 ? ?WriteMemory(0.36f, 0x679670);

 ? ?for(int w : {2, 8, 11, 17}) {
 ? ? ? ?SetTime(624, w); wind(2, 8.6); wind3(4, 8.6);
 ? ? ? ?SetTime(w == 17 ? 1092 : 1080); wind(2, 9); norm(4, 9);
 ? ?}

 ? ?for(int w : {3, 9, 12, 18}) {
 ? ? ? ?SetTime(225, w); wind(2, 9); norm(4, 9);
 ? ? ? ?SetTime(601 + 1); Ice3(-1);
 ? ? ? ?Delay(-419); Card(M_ICE_SHROOM, 3, 6);
 ? ?}

 ? ?for(int w : {4, 13}) {
 ? ? ? ?SetTime(688, w); wind(2, 8.5125); norm(4, 8.5125);
 ? ? ? ?SetTime(1118); wind(2, 9); norm(4, 9);
 ? ?}

 ? ?for(int w : {5, 14}) {
 ? ? ? ?int r = (w == 5 ? 2 : 3);
 ? ? ? ?SetTime(182 - 150, w); Card(FLOWER_POT, r, 9);
 ? ? ? ?SetTime(215 - 100, w); Card(DOOM_SHROOM, r, 9);
 ? ? ? ?SetTime(401); tbs(2, 9); wind(4, 9);
 ? ? ? ?Delay(-359 + 205); Shovel(3, 1); Card(KERNEL_PULT, 3, 1);
 ? ? ? ?Delay(751); Card(KERNEL_PULT, 3, 2); Card(COB_CANNON, 3, 1);
 ? ?}

 ? ?for(int w : {6, 15}) {
 ? ? ? ?SetTime(282 - 100, w); Card({FLOWER_POT, JALAPENO}, 5, 9);
 ? ? ? ?SetTime(299, w); wind(2, 9); norm(4, 9);
 ? ? ? ?SetTime(451); wind(2, 9);
 ? ? ? ?SetTime(452 - 100); Card(CHERRY_BOMB, 5, 9);
 ? ?}

 ? ?for(int w : {1, 7, 16}) {
 ? ? ? ?SetTime(359, w); tbs(2, 9); norm(4, 9);
 ? ? ? ?SetTime(579); wind(3, 9);
 ? ? ? ?SetTime(440); Card(FLOWER_POT, 1, 9);
 ? ? ? ?SetTime(601 + 1 - 100); Card(ICE_SHROOM, 3, 6);
 ? ?}

 ? ?SetTime(467, 10); tbs(234, 9);
 ? ?SetTime(468); Card(FLOWER_POT, 1, 9);
 ? ?SetTime(667 + 1 - 100); Card(ICE_SHROOM, 3, 6);
 ? ?SetTime(700, 11); Card(FLOWER_POT, 5, 9);

 ? ?wind.p(601 + 696, 9);
 ? ?wind(24, 9, WAIT_UNTIL_RECOVER);
 ? ?wind.p(2130, 9);

 ? ?wind.p(688, 19);
 ? ?SetTime(1080); wind(2, 9); norm(4, 9);
 ? ?wind.p(1340, 19, 2415_r, WAIT_UNTIL_RECOVER);
 ? ?wind.p(2380, 19, 2_r);
 ? ?Delay(-99); Card({FLOWER_POT, CHERRY_BOMB}, 4, 9);

 ? ?InsertTimeOperation(-1, 20, [](){ WriteMemory(0.23f, 0x679670); });
 ? ?SetTime(1 - 100); Card(ICE_SHROOM, 3, 6);
 ? ?SetTime(34 - 100); Card(DOOM_SHROOM, 4, 9);
 ? ?SetTime(674); wind(2, 4.5); norm(4, 4.5);
 ? ?wind.p(1173, 20);
 ? ?wind.p(1340, 20);
 ? ?wind(115, 9, WAIT_UNTIL_RECOVER);
}

SMShowMe sm;

void Draw() {
 ? ?auto& bar_painter = sm.getPainter();
 ? ?for(auto& p : alive_plant_filter)
 ? ? ? ?if(p.type() == COB_CANNON && p.col() == 2) {
 ? ? ? ? ? ?double rate = 1.0 * p.hp() / p.hpMax();
 ? ? ? ? ? ?bar_painter.drawBar(p.xi() + 80, p.yi() - 10, rate, 120, 8, 1, 0xFF00FF00, SMPainter::RIGHT, {rate});
 ? ? ? ?}
}


【ME】|≡]| 腳本的評(píng)論 (共 條)

分享到微博請(qǐng)遵守國家法律
玛多县| 化州市| 柘荣县| 临漳县| 竹山县| 桃园市| 射阳县| 衡东县| 安西县| 阳曲县| 南靖县| 凌云县| 班戈县| 嘉善县| 陆丰市| 靖远县| 新民市| 星子县| 虞城县| 湖南省| 舞阳县| 资兴市| 泸溪县| 高州市| 尼木县| 美姑县| 芦山县| 雷州市| 凤冈县| 荔浦县| 黄石市| 漳浦县| 武陟县| 东宁县| 平谷区| 高台县| 于田县| 安龙县| 江西省| 林口县| 工布江达县|