lfnetwork.com mark read register faq members calendar

Thread: Persistant
Thread Tools Display Modes
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Old 06-19-2006, 05:22 PM   #1
alexx860
Rookie
 
alexx860's Avatar
 
Join Date: Nov 2003
Location: France, Brittany
Posts: 79
Persistant

Hi!
I'm making a command for walking on water. When you type /walkonwater, it sets ent->client->pers.walkonwater to qtrue. No problem here. But how do I retrieve walkonwater variable in bg_***.c files?? There is no ent->client's but only pm->ps ...

Thanks in advance
alexx860


150+ GMail invitations! PM me if you want one

alexx860 is offline   you may: quote & reply,
Old 06-19-2006, 08:03 PM   #2
Vruki Salet
Junior Member
 
Vruki Salet's Avatar
 
Join Date: Aug 2005
Location: Somewhere else entirely
Posts: 443
#ifdef QAGAME

g_entities[pm->ps->clientNum].client->pers.walkonwater

#endif

Put your code between the #ifdef QAGAME and #endif tags and use g_entities[pm->ps->clientNum].client instead of ent->client. That works for me anyway.
Vruki Salet is offline   you may: quote & reply,
Old 06-20-2006, 04:52 AM   #3
alexx860
Rookie
 
alexx860's Avatar
 
Join Date: Nov 2003
Location: France, Brittany
Posts: 79
OK, I'll try that, but what is QAGAME??


150+ GMail invitations! PM me if you want one

alexx860 is offline   you may: quote & reply,
Old 06-20-2006, 06:06 AM   #4
alexx860
Rookie
 
alexx860's Avatar
 
Join Date: Nov 2003
Location: France, Brittany
Posts: 79
Sorry for double post but it work very well TYVM
But I'm curious and I want to know what is QAGAME ^_^


150+ GMail invitations! PM me if you want one

alexx860 is offline   you may: quote & reply,
Old 06-20-2006, 08:50 AM   #5
ensiform
The Stig
 
ensiform's Avatar
 
Join Date: Nov 2004
Location: Sawtooth Cauldron
Posts: 1,241
Current Game: Borderlands 2
QAGAME is the server module, CGAME is the client module, and you need to do that in QAGAME as he said. however that seems like something that would affect pmove and would need to predict it on the client?


iojamp project lead / coder
ensiform is offline   you may: quote & reply,
Old 06-20-2006, 10:32 AM   #6
Vruki Salet
Junior Member
 
Vruki Salet's Avatar
 
Join Date: Aug 2005
Location: Somewhere else entirely
Posts: 443
I'd like to know more about that ensiform. How would you do that and what would happen if you didn't?
Vruki Salet is offline   you may: quote & reply,
Old 06-20-2006, 01:21 PM   #7
ensiform
The Stig
 
ensiform's Avatar
 
Join Date: Nov 2004
Location: Sawtooth Cauldron
Posts: 1,241
Current Game: Borderlands 2
you would send the variable over to the client somehow

if you didnt do it, things may look a tad bit funny because the client doesnt know about it, thats one of the reasons why the JA+ "optional" client plugin is more or less actually required. because for 1, people look absoultely retarded if you don't and it can cause you (the client) to not see proper effects of say, a pmove type change


iojamp project lead / coder
ensiform is offline   you may: quote & reply,
Old 06-20-2006, 02:53 PM   #8
Vruki Salet
Junior Member
 
Vruki Salet's Avatar
 
Join Date: Aug 2005
Location: Somewhere else entirely
Posts: 443
Quote:
Originally Posted by ensiform
you would send the variable over to the client somehow
So how would *you* do that if you were going to? I was going to take a guess but it makes more sense to just ask you since you seem to know what you're doing. I'm not a programmer so a lot of this is guesswork and voodoo even though I'm learning some things just by doing them. I think alexx860 would like a lesson too.
Vruki Salet is offline   you may: quote & reply,
Old 06-20-2006, 05:00 PM   #9
ensiform
The Stig
 
ensiform's Avatar
 
Join Date: Nov 2004
Location: Sawtooth Cauldron
Posts: 1,241
Current Game: Borderlands 2
using a servercommand and intercept it in cg_servercmds.c or you could send it in the clientinfo thing when it gets sent and checked.


iojamp project lead / coder
ensiform is offline   you may: quote & reply,
Old 07-10-2006, 08:49 PM   #10
razorace
Impressive, Terran!
 
razorace's Avatar
 
Join Date: May 2002
Posts: 9,172
mmm, since it's a simple piece of information that's critical to the pmove code, I'd look into squeezing it in as entity flag, which can be seen in the bg code. Look up any of the EF_ prefixed flags to see what I'm talking about.


---Jedi Guardian of the Newbie Questions
---Masters of the Force Team Leader / Creator
---Open Jedi Project Lead Moderator / Co-Founder
razorace is offline   you may: quote & reply,
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Go Back   LucasForums > Network > JediKnight Series > Editing Central > JA Coding > Persistant

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:01 AM.

LFNetwork, LLC ©2002-2011 - All rights reserved.
Powered by vBulletin®
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.