|
Re: Build a building
[Re: Jaxas]
#264283
05/05/09 12:50
05/05/09 12:50
|
Joined: Oct 2007
Posts: 5,210 İstanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
|
Hey Jaxas, the sentence didnt make much sense, do you mean i take the code as my own and develop it further?
3333333333
|
|
|
Re: Build a building
[Re: Quad]
#264284
05/05/09 12:52
05/05/09 12:52
|
Joined: Mar 2006
Posts: 321 Norway
Eagelina
Senior Member
|
Senior Member
Joined: Mar 2006
Posts: 321
Norway
|
when I run it it is much darker, and when I select something to build, you se the building like shooting from the middle of the screen up to the air, and disapeares. So I dont se what you has taken pictures of. It must be some type of setting in my version. I just bought the commercial A7 a couple of weeks ago. And havent adjusted any settings yet. Wel I figure it out .... always do......
A6 and A7 Commercial ------------------- Programmer always searching for more to learn and understand.
|
|
|
Re: Build a building
[Re: Jaxas]
#264291
05/05/09 13:08
05/05/09 13:08
|
Joined: Oct 2007
Posts: 5,210 İstanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
|
@Jaxas, ah i get it now @Eagelina, if they are flying up, this means that i can't find the ground, and that means either terrain is not properly loaded, or camera is looking somewhere else. i am not sure what can cause this, but updating to 7.77 or removing the #include <default.c> line may help. I am downloading the publish-enabled 7.77 ill upload an executable so you can test if it's same or if it works. (also you can try redownloading, maybe zip is corrupted while downloading) @Toryno, yeah you can use the code as base if you want. --- having update problems, downloading latest update, will post the exe soon.
Last edited by Quadraxas; 05/05/09 13:55.
3333333333
|
|
|
Re: Build a building
[Re: Quad]
#264321
05/05/09 15:51
05/05/09 15:51
|
Joined: Oct 2007
Posts: 5,210 İstanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
|
this is the compiled version of the file script. if you still see the terrain black, maybe your gfx card doesnt support shader model2? if this doesn't work too can you post a screenshot. http://rapidshare.com/files/229473634/code.cd.rar(this is definetely not a problem in the script probably in your pc/GS installation)
3333333333
|
|
|
Re: Build a building
[Re: Quad]
#264330
05/05/09 17:07
05/05/09 17:07
|
Joined: Mar 2006
Posts: 321 Norway
Eagelina
Senior Member
|
Senior Member
Joined: Mar 2006
Posts: 321
Norway
|
this is the compiled version of the file script. if you still see the terrain black, maybe your gfx card doesnt support shader model2? if this doesn't work too can you post a screenshot. http://rapidshare.com/files/229473634/code.cd.rar(this is definetely not a problem in the script probably in your pc/GS installation) Yes this one worked fine. Now I could se everything. Thanks! What did you do? Did you change anything in the sqript? Edit: I did look at the content of the to downloads the first one I downloaded didnt have the terraintex3 , and I also see a skycube in the cd folder. None of these was in the other one. So it is probably those to that did the trick....
Last edited by Eagelina; 05/05/09 17:11.
A6 and A7 Commercial ------------------- Programmer always searching for more to learn and understand.
|
|
|
Re: Build a building
[Re: Eagelina]
#264340
05/05/09 18:05
05/05/09 18:05
|
Joined: Oct 2007
Posts: 5,210 İstanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
|
the files that is not included in first download are taken from your gamestudio folder, i didnt changed anything, even aline, just publised and posted download and install latest version from announcement forum and you should be ok with the first download.
3333333333
|
|
|
Re: Build a building
[Re: Quad]
#264349
05/05/09 19:05
05/05/09 19:05
|
Joined: Apr 2009
Posts: 138 Germany
Toryno
OP
Member
|
OP
Member
Joined: Apr 2009
Posts: 138
Germany
|
Thank you all and thanks for the code But I can't really use it, because my game is a FPS and strategy mix and the only camera option is first person and there's no cursour But this is not my problem. In my game, the building should not be at the mouse cursour befor you build it, but it is in front of the player I also can check if the building is in another building and it becomes red then. My only problem now is that i have not really an idea how i could check if the building is in the map(wmb file, i don't have any terrain in it yet). How could that be done? Edit: Oh, there was a german word
Last edited by Toryno; 05/05/09 19:08.
Thanks for reading, thinking, answering
|
|
|
Re: Build a building
[Re: Toryno]
#264355
05/05/09 19:48
05/05/09 19:48
|
Joined: May 2008
Posts: 331 Lithuania, Vilnius
Jaxas
Senior Member
|
Senior Member
Joined: May 2008
Posts: 331
Lithuania, Vilnius
|
sample:
var id[n]; // n is you buildings array
var i;
...
action building()
{
...
id[i]=1;
my.skill50 = i;
i+=1;
...
while(1)
{
...
wait(1);
}
id[skill50]= 0;
ent_remove(me);
}
...
add action to building. If you want to check building, example church has id[5], then you check if id[5]==1, if it's true, then exist, else, no. if you can't understand what is the array, then try use some variables:
var church;
...
action church()
{
church = 1;
while(1)
{
...
wait(1);
}
church = 0;
ent_remove(me);
}
....
then you just check if church == 1
The smaller the bug, the harder it is to kill. _________________________________________ Forklift DEMO (3dgs)
|
|
|
Moderated by mk_1, Perro, rayp, Realspawn, Rei_Ayanami, rvL_eXile, Spirit, Superku, Tobias, TSG_Torsten, VeT
|