void MrIceBlock::write(lisp::Writer& writer) { writer.start_list("mriceblock"); WalkingBadguy::write(writer); writer.end_list("mriceblock"); }
void CloudParticleSystem::write(lisp::Writer& writer) { writer.start_list("particles-clouds"); writer.write_int("z-pos", z_pos); writer.end_list("particles-clouds"); }
void SSpiky::write(lisp::Writer& writer) { writer.start_list("sspiky"); WalkingBadguy::write(writer); writer.end_list("sspiky"); }
void Stumpy::write(lisp::Writer& writer) { writer.start_list("stumpy"); WalkingBadguy::write(writer); writer.end_list("stumpy"); }
void Candle::save(lisp::Writer& writer) { MovingSprite::save(writer); writer.write("burning", burning); writer.write("flicker", flicker); writer.write("color", lightcolor.toVector(false)); }
void Spotlight::save(lisp::Writer& writer) { GameObject::save(writer); writer.write("x", position.x); writer.write("y", position.y); writer.write("color", color.toVector(false)); }
void MrTree::write(lisp::Writer& writer) { writer.start_list("mrtree"); WalkingBadguy::write(writer); writer.end_list("mrtree"); }
void GhostParticleSystem::write(lisp::Writer& writer) { writer.start_list("particles-ghosts"); writer.write_int("z-pos", z_pos); writer.end_list("particles-ghosts"); }
void SnowParticleSystem::write(lisp::Writer& writer) { writer.start_list("particles-snow"); writer.write_int("z-pos", z_pos); writer.end_list("particles-snow"); }
void Dart::write(lisp::Writer& writer) { writer.start_list("dart"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("dart"); }
void MoleRock::write(lisp::Writer& writer) { writer.start_list("mole_rock"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("mole_rock"); }
void Yeti::write(lisp::Writer& writer) { writer.start_list("yeti"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("yeti"); }
void MrBomb::write(lisp::Writer& writer) { writer.start_list("mrbomb"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("mrbomb"); }
void SpawnPoint::save(lisp::Writer& writer){ writer.start_list("spawnpoint"); writer.write("x",pos.x); writer.write("y",pos.y); writer.write("name",name,false); writer.end_list("spawnpoint"); }
void MrRocket::write(lisp::Writer& writer) { writer.start_list("mrrocket"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("mrrocket"); }
void SnowSnail::write(lisp::Writer& writer) { writer.start_list("mriceblock"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("snowsnail"); }
void BouncingSnowball::write(lisp::Writer& writer) { writer.start_list("bouncingsnowball"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("bouncingsnowball"); }
void Jumpy::write(lisp::Writer& writer) { writer.start_list("jumpy"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("jumpy"); }
void Totem::write(lisp::Writer& writer) { writer.start_list("totem"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("totem"); }
void SpiderMite::write(lisp::Writer& writer) { writer.start_list("spidermite"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("spidermite"); }
void Zeekling::write(lisp::Writer& writer) { writer.start_list("zeekling"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("zeekling"); }
void Fish::write(lisp::Writer& writer) { writer.start_list("fish"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.end_list("fish"); }
void PlayerStatus::write(lisp::Writer& writer) { switch(bonus) { case NO_BONUS: writer.write_string("bonus", "none"); break; case GROWUP_BONUS: writer.write_string("bonus", "growup"); break; case FIRE_BONUS: writer.write_string("bonus", "fireflower"); break; case ICE_BONUS: writer.write_string("bonus", "iceflower"); break; default: log_warning << "Unknown bonus type." << std::endl; writer.write_string("bonus", "none"); } writer.write_int("fireflowers", max_fire_bullets); writer.write_int("iceflowers", max_ice_bullets); writer.write_int("coins", coins); writer.write_int("max-score-multiplier", max_score_multiplier); }
void Background::save(lisp::Writer& writer) { GameObject::save(writer); switch (alignment) { case LEFT_ALIGNMENT: writer.write("alignment", "left", false); break; case RIGHT_ALIGNMENT: writer.write("alignment", "right", false); break; case TOP_ALIGNMENT: writer.write("alignment", "top", false); break; case BOTTOM_ALIGNMENT: writer.write("alignment", "bottom", false); break; case NO_ALIGNMENT: break; } writer.write("scroll-offset-x", scroll_offset.x); writer.write("scroll-offset-y", scroll_offset.y); writer.write("scroll-speed-x", scroll_speed.x); writer.write("scroll-speed-y", scroll_speed.y); writer.write("speed", speed); if (speed_y != speed){ writer.write("speed_y", speed_y); } writer.write("image", imagefile, false); if (imagefile_top != "") { writer.write("image-top", imagefile_top); } if (imagefile_bottom != "") { writer.write("image-bottom", imagefile_bottom); } }
void BadGuy::save(lisp::Writer& writer) { MovingSprite::save(writer); if(dir == LEFT){ writer.write("direction", "left", false); } else { writer.write("direction", "right", false); } if(dead_script != ""){ writer.write("dead-script", dead_script, false); } }
void Flame::write(lisp::Writer& writer) { writer.start_list("flame"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.write_float("radius", radius); writer.write_float("speed", speed); writer.end_list("flame"); }
void WillOWisp::write(lisp::Writer& writer) { writer.start_list("willowisp"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.write_string("sector", target_sector); writer.write_string("spawnpoint", target_spawnpoint); writer.end_list("willowisp"); }
void Dispenser::write(lisp::Writer& writer) { writer.start_list("dispenser"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); writer.write_float("cycle", cycle); writer.write_string("badguy", badguy); writer.end_list("dispenser"); }
void SecretAreaTrigger::save(lisp::Writer& writer) { MovingObject::save(writer); writer.write("width", bbox.get_width()); writer.write("height", bbox.get_height()); if (fade_tilemap != "") { writer.write("fade-tilemap", fade_tilemap, false); } writer.write("message", message, false); if (script != "") { writer.write("script", script, false); } }
void SnowBall::write(lisp::Writer& writer) { writer.start_list("snowball"); writer.write_float("x", start_position.x); writer.write_float("y", start_position.y); if (fluffy) { // don't give us away at every snowball writer.write_bool("fluffy", true); } writer.end_list("snowball"); }