Gamestudio Links
Zorro Links
Newest Posts
Newbie Questions
by AndrewAMD. 12/05/23 10:56
Zorro Trader GPT
by TipmyPip. 12/04/23 11:34
Square root rule
by Smallz. 12/02/23 09:15
RTest not found error
by TipmyPip. 12/01/23 21:43
neural function for Python to [Train]
by TipmyPip. 12/01/23 14:47
Xor Memory Problem.
by TipmyPip. 11/28/23 14:23
Training with command line parameters
by TipmyPip. 11/26/23 08:42
Combine USD & BTC Pairs In Asset Loop
by TipmyPip. 11/26/23 08:30
AUM Magazine
Latest Screens
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Who's Online Now
6 registered members (AndrewAMD, alibaba, fairtrader, ozgur, TipmyPip, Quad), 622 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
fairtrader, hus, Vurtis, Harry5, KelvinC
19019 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
shaders on LAN #95088
10/19/06 16:20
10/19/06 16:20
Joined: Jul 2006
Posts: 783
London, UK
sheefo Offline OP
User
sheefo  Offline OP
User

Joined: Jul 2006
Posts: 783
London, UK
How can I make a shader appear on the client.

I have "initialize_shaders" function which is called from main, which sets up the shader for my terrain.

Re: shaders on LAN [Re: sheefo] #95089
10/19/06 19:43
10/19/06 19:43
Joined: Mar 2004
Posts: 202
Germany
zSteam_ Offline
Member
zSteam_  Offline
Member

Joined: Mar 2004
Posts: 202
Germany
hello
test this
Code:
 
entity* terrain;

function main()
{
...
ifdef client;
...
while(!terrain){wait(1);}
{
terrain.material=multitex;
endif;
...
}

action terrain_LOL
{
terrain=me;
...
}



hope this is helpfull


A6 Commercial 6.50.6
Re: shaders on LAN [Re: zSteam_] #95090
10/19/06 19:48
10/19/06 19:48
Joined: Jan 2004
Posts: 2,013
The Netherlands
E
Excessus Offline
Expert
Excessus  Offline
Expert
E

Joined: Jan 2004
Posts: 2,013
The Netherlands
The action in zStreams code will only be executed on the server. Either the terrain must be created localy (ent_createlocal) on the client, or dplay_localfunction must be on.

Re: shaders on LAN [Re: Excessus] #95091
10/19/06 19:55
10/19/06 19:55
Joined: Mar 2004
Posts: 202
Germany
zSteam_ Offline
Member
zSteam_  Offline
Member

Joined: Mar 2004
Posts: 202
Germany
oh right (for the server (reason: pointer)) sry


A6 Commercial 6.50.6
Re: shaders on LAN [Re: zSteam_] #95092
10/19/06 20:18
10/19/06 20:18
Joined: Jul 2006
Posts: 783
London, UK
sheefo Offline OP
User
sheefo  Offline OP
User

Joined: Jul 2006
Posts: 783
London, UK
ent_createlocal works but I don't know if it is the best way to create a terrain for a LAN RTS.

Re: shaders on LAN [Re: sheefo] #95093
10/19/06 20:29
10/19/06 20:29
Joined: Mar 2004
Posts: 202
Germany
zSteam_ Offline
Member
zSteam_  Offline
Member

Joined: Mar 2004
Posts: 202
Germany
u must use handles, but i dont know how to use it

sry for bad english ^^


A6 Commercial 6.50.6
Re: shaders on LAN [Re: zSteam_] #95094
10/19/06 21:15
10/19/06 21:15
Joined: Jul 2006
Posts: 783
London, UK
sheefo Offline OP
User
sheefo  Offline OP
User

Joined: Jul 2006
Posts: 783
London, UK
I can "ent_create" it only on the server now but the shader doesn't want to work.

zSteam, handles sound like a good idea, but I too don't know how. These are material handles were talking about, right?

BTW, I tried "ent_sendnow(my)" but it doesn't work.

Re: shaders on LAN [Re: sheefo] #95095
10/21/06 00:33
10/21/06 00:33
Joined: Aug 2001
Posts: 2,320
Alberta, Canada
William Offline
Expert
William  Offline
Expert

Joined: Aug 2001
Posts: 2,320
Alberta, Canada
Place "dplay_localfunction = on;" before your level load. This sets everything loaded in the level to local, then have your shaders applied through the level entities actions. If your loading an entity for only one computer use ent_createlocal. If it's for all computers, use ent_create and apply the material to each entity on each client thru use of proc_local, proc_client, and server side functions. However, all this has been covered many times before; i'd reccomend doing some searchs in the multiplayer forum, the majority(if not all) of your Q's would probably have already been answered.


Check out Silas. www.kartsilas.com

Hear my band Finding Fire - www.myspace.com/findingfire

Daily dev updates - http://kartsilas.blogspot.com/

Moderated by  HeelX, Spirit 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1