Page 1 of 1

Make various methods clearscope, and bump ZScript version

Posted: Sun Aug 12, 2018 12:54 am
by argv
I've sent two PRs.

PR #532 makes several ZScript methods clearscope and (where applicable) const. Please see the PR for rationale.

PR #533 sets the ZScript version on master to 3.5.0. It was set to that in the 3.5.0 release commit, but was left at 3.4.0 on master.

Re: Make various methods clearscope, and bump ZScript versio

Posted: Sun Aug 12, 2018 2:01 am
by Graf Zahl
For the clearscope thing I'll wait for feedback of someone working on the C/S branch. I cannot say if any of it may interfere with that.

Re: Make various methods clearscope, and bump ZScript versio

Posted: Sun Aug 12, 2018 3:45 am
by Rachael
I don't have a clear answer right now for that, so please bump this thread when the branch has matured a bit more. Right now we don't know exactly how client-side actors are going to be handled so without that it's difficult to say whether it's safe to move ahead with this or not.

(For reference the two clientside implementations being considered are static dummy actors that simply mimic their server counterparts in all available visual aspects, and the second idea was to spawn copies of the server representations and allow the client to execute these actors directly as a means of prediction)

Even if it is, it's a fairly certain bet that clearscoping these won't work as expected on the client side, but we'll have to climb that hill when we get there before we'll really know for sure.

Re: Make various methods clearscope, and bump ZScript versio

Posted: Sun Aug 12, 2018 3:49 am
by Graf Zahl
So we have to be very careful with clearscoping stuff.

Re: Make various methods clearscope, and bump ZScript versio

Posted: Sun Aug 12, 2018 7:48 pm
by argv
Okay.

Some of the methods I mentioned are, as far as I can tell, completely unaffected by playsim state (they're either pure or access static class information), namely deltaangle, absangle, AngleToVector, RotateVector, Normalize180, FindState, and GetDropItems. What if I send another PR that clearscopes only those? Would that be safe to merge now?

Good luck on the C/S branch, by the way. Modern, Zandronum-like networking with an up-to-date engine would be completely awesome. :biggrin:

Re: Make various methods clearscope, and bump ZScript versio

Posted: Mon Aug 13, 2018 12:31 am
by Graf Zahl
argv wrote:Okay.

Some of the methods I mentioned are, as far as I can tell, completely unaffected by playsim state (they're either pure or access static class information), namely deltaangle, absangle, AngleToVector, RotateVector, Normalize180, FindState, and GetDropItems. What if I send another PR that clearscopes only those? Would that be safe to merge now?

Good luck on the C/S branch, by the way. Modern, Zandronum-like networking with an up-to-date engine would be completely awesome. :biggrin:

If it is purely static, clearscope is safe. So yes, please do.

Re: Make various methods clearscope, and bump ZScript versio

Posted: Tue Aug 14, 2018 2:23 am
by argv
Done. #536 clearscopes only the static and meta methods.