refactor(packages): 0.R5 - a question no longer starts its state - 64 lazy starts ('if st.x == null { st.x = ... }' inside a getter) are the state's defaults, gear__ensure is gone, and ludic migrate state --tighten took mut off 208 package parameters: things_all, thing_find, gear_charge, gear_level, jobs_state and the rest read
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
54f5efb23f
commit
9862ec82e3
102 changed files with 320 additions and 351 deletions
|
|
@ -61,17 +61,15 @@ export port NetSocket {
|
|||
|
||||
export function net_config(net_st: mut NetState, c: NetConfig) -> void { net_st.net__cfg = c }
|
||||
|
||||
function net__conf(net_st: mut NetState) -> NetConfig {
|
||||
if net_st.net__cfg == null { net_st.net__cfg = new NetConfig }
|
||||
function net__conf(net_st: NetState) -> NetConfig {
|
||||
return net_st.net__cfg
|
||||
}
|
||||
|
||||
export function net_facts(net_st: mut NetState) -> Queue<NetFact> {
|
||||
if net_st.net__facts == null { net_st.net__facts = queue_new("net.facts") }
|
||||
export function net_facts(net_st: NetState) -> Queue<NetFact> {
|
||||
return net_st.net__facts
|
||||
}
|
||||
|
||||
function net__fact(net_st: mut NetState, what: int, slot: int, pid: int, why: int, text: string) -> void {
|
||||
function net__fact(net_st: NetState, what: int, slot: int, pid: int, why: int, text: string) -> void {
|
||||
let f = new NetFact
|
||||
f.what = what
|
||||
f.slot = slot
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue