Warning: ob_start(): function 'compress_handler' not found or invalid function name in /www/htdocs/xfmantis/core.php on line 18
0002325: alle Basisbaugrafiken bei Spielstart laden - Mantis
Mantis Bugtracker

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0002325 [X-Force] Allgemein feature N/A 20.08.09 13:52 24.09.09 03:00
Reporter Natter View Status public  
Assigned To Natter
Priority normal Resolution fixed  
Status closed   Product Version V0.915b04
Summary 0002325: alle Basisbaugrafiken bei Spielstart laden
Description Ich weiß zwar nicht genau, wie das am besten umzusetzen ist, aber imho sollten alle passenden Grafiken (von der Auflösung passend) ab Spielstart für den Basisbau verfügbar sein, und nicht erst, nachdem ein entsprechendes Gebäude erforscht wurde. Ist vor allem für gescriptete Gebäude mit eigener Grafik wichtig.
Additional Information
Attached Files

- Relationships

- Notes
23.08.09 13:44

Yesterday I find that base building grafik is loading on DXBaseBuilder.pas strings 495-516

    for Dummy:=0 to high(FloorImages) do

    for Dummy:=0 to basis_api_GetEinrichtungCount-1 do
      with basis_api_GetEinrichtung(Dummy) do
        if RoomTyp=rtHangar then
It load only images of existing buildings and floor.

I suggest to add after shown fragment code like this.
    for Dummy := 0 to science_api_GetProjectCount - 1 do
      with forsch_api_GetProjectByIndex(dummy) do
        if TypeID=ptEinrichtung then
          if RoomTyp=rtHangar then AddImage(BuildImageBase,1,1)
          else AddImage(BuildImageBase,UnitWidth,UnitHeight);

But this part is need only for first lauch (it load all grafiks and don't need to reload). I didn't touch any else code.
Fragment checked with Zitadelle building and at least with it work.

Can this be helpful?

Best regards
24.08.09 02:36

It would work - but imho it's not perfect. What if you want to create a room per script with an Image never used for a normal building/Project?
24.08.09 02:51

I added:

    for Dummy:=0 to high(BaseBuildingImagesSmall) do

    for Dummy:=0 to high(BaseBuildingImagesLarge) do

  // Bsaisbaugrafiken aus Spielsatz laden

  for Dummy:=0 to fArchiv.Count-1 do
    if (Copy(TempName,1,Pos(':',TempName)-1)='BasisBau') then
      AddImage('user\'+TempName,Bitmap2.Width div ObjektSize,Bitmap2.Height div ObjektSize);

for Dummy:=0 to basis_api_GetEinrichtungCount-1 do ... is not used any more. Hopefully their is no problem with rtHangar ^^

- Issue History
Date Modified Username Field Change
20.08.09 13:52 Natter New Issue
20.08.09 13:52 Natter Summary alle Basisbaugrafiken bei Spielstzart laden => alle Basisbaugrafiken bei Spielstart laden
23.08.09 13:44 gnfalex Note Added: 0004234
24.08.09 02:36 Natter Note Added: 0004235
24.08.09 02:51 Natter Status new => resolved
24.08.09 02:51 Natter Fixed in Version  => V0.915b05
24.08.09 02:51 Natter Resolution open => fixed
24.08.09 02:51 Natter Assigned To  => Natter
24.08.09 02:51 Natter Note Added: 0004236
24.09.09 03:00 Gast Status resolved => closed

Mantis 1.0.7[^]
Copyright © 2000 - 2007 Mantis Group
Powered by Mantis Bugtracker