| 653 | } |
| 654 | |
| 655 | static void StartObject(ObjectInfo *obj) |
| 656 | { |
| 657 | InitFlare(obj, ID_FLARE_ITEM); |
| 658 | |
| 659 | for (int objectNumber = ID_SEARCH_OBJECT1; objectNumber <= ID_SEARCH_OBJECT4; objectNumber++) |
| 660 | InitSearchObject(obj, objectNumber); |
| 661 | |
| 662 | obj = &Objects[ID_TWOBLOCK_PLATFORM]; |
| 663 | if (obj->loaded) |
| 664 | { |
| 665 | obj->Initialize = InitializeTwoBlockPlatform; |
| 666 | obj->control = TwoBlockPlatformControl; |
| 667 | obj->SetHitEffect(true); |
| 668 | } |
| 669 | |
| 670 | for (int objectNumber = ID_RAISING_BLOCK1; objectNumber <= ID_RAISING_BLOCK4; objectNumber++) |
| 671 | { |
| 672 | obj = &Objects[objectNumber]; |
| 673 | if (obj->loaded) |
| 674 | { |
| 675 | obj->Initialize = InitializeRaisingBlock; |
| 676 | obj->control = ControlRaisingBlock; |
| 677 | obj->SetHitEffect(true); |
| 678 | } |
| 679 | } |
| 680 | |
| 681 | obj = &Objects[ID_EXPANDING_PLATFORM]; |
| 682 | if (obj->loaded) |
| 683 | { |
| 684 | obj->Initialize = InitializeExpandingPlatform; |
| 685 | obj->control = ControlExpandingPlatform; |
| 686 | obj->SetHitEffect(true); |
| 687 | } |
| 688 | |
| 689 | obj = &Objects[ID_ELECTRICAL_LIGHT]; |
| 690 | if (obj->loaded) |
| 691 | { |
| 692 | obj->control = ElectricalLightControl; |
| 693 | obj->Initialize = InitializeElectricalLight; |
| 694 | obj->meshSwapSlot = ID_ELECTRICAL_LIGHT; |
| 695 | } |
| 696 | |
| 697 | obj = &Objects[ID_PULSE_LIGHT]; |
| 698 | if (obj->loaded) |
| 699 | { |
| 700 | obj->control = PulseLightControl; |
| 701 | obj->Hidden = true; |
| 702 | } |
| 703 | |
| 704 | obj = &Objects[ID_STROBE_LIGHT]; |
| 705 | if (obj->loaded) |
| 706 | obj->control = StrobeLightControl; |
| 707 | |
| 708 | obj = &Objects[ID_COLOR_LIGHT]; |
| 709 | if (obj->loaded) |
| 710 | { |
| 711 | obj->control = ColorLightControl; |
| 712 | obj->Hidden = true; |
no test coverage detected