pytabs.story
1# pyTABS - ETABS .NET API python wrapper 2# Story - cStory interface 3__all__ = ['Story'] 4 5# import ETABS namespace and pyTABS error handler 6from pytabs.etabs_config import * 7from pytabs.error_handle import * 8 9# import typing 10from typing import TypedDict, Union 11 12class StoryInfo(TypedDict): 13 """TypedDict class for Story information return""" 14 base_elevation : float 15 number_stories : int 16 story_names : list[str] 17 story_elevations : list[float] 18 story_heights : list[float] 19 is_master_story : list[bool] 20 similar_to_story : list[str] 21 splice_above : list[bool] 22 splice_height : list[float] 23 colour : list[int] 24 25 26class Story: 27 """Story interface""" 28 def __init__(self, sap_model : etabs.cSapModel) -> None: 29 # link of SapModel interface 30 self.sap_model = sap_model 31 # create PierLabel interface 32 self.story = etabs.cStory(self.sap_model.Story) 33 34 35 def get_elevation(self, story_name : str) -> float: 36 """Retrieves the elevation of a defined story. 37 38 :param story_name: name of a defined story 39 :type story_name: str 40 :return: elevation of the story 41 :rtype: float 42 """ 43 elevation = float() 44 [ret, elevation] = self.story.GetElevation(story_name, elevation) 45 handle(ret) 46 return elevation 47 48 49 def get_GUID(self, story_name : int) -> str: 50 """Retrieves the GUID of a defined story. 51 52 :param story_name: name of a defined story 53 :type story_name: int 54 :return: GUID of the story 55 :rtype: str 56 """ 57 guid = str() 58 [ret, guid] = self.story.GetGUID(story_name, guid) 59 handle(ret) 60 return guid 61 62 63 def get_height(self, story_name : str) -> float: 64 """Retrieves the height of a defined story. 65 66 :param story_name: name of a defined story 67 :type story_name: str 68 :return: height of the story 69 :rtype: float 70 """ 71 height = float() 72 [ret, height] = self.story.GetHeight(story_name, height) 73 handle(ret) 74 return height 75 76 77 def get_master_story(self, story_name : str) -> bool: 78 """Retrieves whether a defined story is a master story. 79 80 :param story_name: name of a defined story 81 :type story_name: str 82 :return: True if the story is a master story, False otherwise 83 :rtype: bool 84 """ 85 is_master_story = bool() 86 [ret, is_master_story] = self.story.GetMasterStory(story_name, is_master_story) 87 handle(ret) 88 return is_master_story 89 90 91 def get_name_list(self) -> list[str]: 92 """Retrieves the names of all defined stories. 93 94 :return: all story names 95 :rtype: list[str] 96 """ 97 number_names = int() 98 story_names = [''] 99 [ret, number_names, story_names] = self.story.GetNameList(number_names, story_names) 100 handle(ret) 101 return list(story_names) 102 103 104 def get_similar_to(self, story_name : str) -> Union[str, None]: 105 """Retrieves whether a defined story is a master story. 106 107 :param story_name: name of a defined story 108 :type story_name: str 109 :return: name of similar story, if story is master returns None 110 :rtype: Union[str, None] 111 """ 112 is_master = bool() 113 similar_story = str() 114 [ret, is_master, similar_story] = self.story.GetSimilarTo(story_name, is_master, similar_story) 115 handle(ret) 116 if not is_master: 117 return similar_story 118 119 120 def get_splice(self, story_name : str) -> Union[float, None]: 121 """Retrieves the story splice height, if applicable. 122 123 :param story_name: name of a defined story 124 :type story_name: str 125 :return: height of splice, if present otherwise None 126 :rtype: Union[float, None] 127 """ 128 splice_above = bool() 129 splice_height = float() 130 [ret, splice_above, splice_height] = self.story.GetSplice(story_name, splice_above, splice_height) 131 handle(ret) 132 if splice_above: 133 return splice_height 134 135 136 def get_stories(self) -> StoryInfo: 137 """Retrieves the story information for the current tower. 138 139 :return: story information for all stories 140 :rtype: StoryInfo 141 """ 142 base_elevation = float() 143 number_stories = int() 144 story_names = [str()] 145 story_elevations = [float()] 146 story_heights = [float()] 147 is_master_story = [bool()] 148 similar_to_story = [str()] 149 splice_above = [bool()] 150 splice_height = [float()] 151 colour = [int()] 152 153 [ret, base_elevation, number_stories, story_names, 154 story_elevations, story_heights, is_master_story, 155 similar_to_story, splice_above, splice_height, colour] = self.story.GetStories_2(base_elevation, number_stories, story_names, 156 story_elevations, story_heights, is_master_story, 157 similar_to_story, splice_above, splice_height, colour) 158 handle (ret) 159 return {'base_elevation' : base_elevation, 160 'number_stories' : number_stories, 161 'story_names' : story_names, 162 'story_elevations' : story_elevations, 163 'story_heights' : story_heights, 164 'is_master_story' : is_master_story, 165 'similar_to_story' : similar_to_story, 166 'splice_above' : splice_above, 167 'splice_height' : splice_height, 168 'colour': colour} 169 170 171 def set_elevation(self, story_name : int, elevation : float) -> None: 172 """Sets the elevation of a defined story. 173 174 :param story_name: name of a defined story 175 :type story_name: int 176 :param elevation: elevation of the story 177 :type elevation: float 178 """ 179 handle(self.story.SetElevation(story_name, elevation)) 180 181 182 def set_GUID (self, story_name : str, guid : str = '') -> None: 183 """Sets the GUID of a defined story. 184 185 :param story_name: name of a defined story 186 :type story_name: str 187 :param guid: GUID of the story, defaults to '' 188 :type guid: str, optional 189 """ 190 handle(self.story.SetGUID(story_name, guid)) 191 192 193 def set_height(self, story_name : int, height : float) -> None: 194 """Sets the height of a defined story. 195 196 param story_name: name of a defined story 197 :type story_name: int 198 :param height: height of the story 199 :type height: float 200 """ 201 handle(self.story.SetHeight(story_name, height)) 202 203 204 def set_master_story(self, story_name : str, is_master_story : bool) -> None: 205 """Sets whether a defined story is a master story. 206 207 param story_name: name of a defined story 208 :type story_name: str 209 :param is_master_story: `True` if the story is a master story, `False` otherwise 210 :type is_master_story: bool 211 """ 212 handle(self.story.SetMasterStory(story_name, is_master_story)) 213 214 215 def set_similar(self, story_name : str, similar_to_story : str) -> None: 216 """Sets the master story that a defined story should be similar to. 217 218 :param story_name: name of a defined story which is not a master story 219 :type story_name: str 220 :param similar_to_story: name of a defined master story that the requested story should be similar to 221 :type similar_to_story: str 222 """ 223 handle (self.story.SetSimilarTo(story_name, similar_to_story)) 224 225 226 def set_splice(self, story_name : str, splice_above : bool, splice_height : float) -> None: 227 """Sets the splice height of a defined story. 228 229 :param story_name: name of defined story 230 :type story_name: str 231 :param splice_above: `True` if the story has a splice height, and `False` otherwise 232 :type splice_above: bool 233 :param splice_height: story splice height 234 :type splice_height: float 235 """ 236 handle(self.story.SetSplice(story_name, splice_above, splice_height)) 237 238 239 def set_stories(self, base_elevation : float, number_stories : int, story_names : list[str], story_heights : list[float], 240 is_master_story : list[bool], similar_to_story : list[str], splice_above : list[bool], splice_height : list[float], 241 colour : list[int]) -> None: 242 """Sets the stories for the current tower. 243 244 :param base_elevation: elevation of the base 245 :type base_elevation: float 246 :param number_stories: number of stories 247 :type number_stories: int 248 :param story_names: names of the stories 249 :type story_names: list[str] 250 :param story_heights: story heights 251 :type story_heights: list[float] 252 :param is_master_story: `True` if the story is master story, and `False` otherwise 253 :type is_master_story: list[bool] 254 :param similar_to_story: if the story is not a master story, which master story the story is similar to 255 :type similar_to_story: list[str] 256 :param splice_above: `True` if the story has a splice height, and `False` otherwise 257 :type splice_above: list[bool] 258 :param splice_height: story splice height 259 :type splice_height: list[float] 260 :param colour: display color for the story specified 261 :type colour: list[int] 262 """ 263 [ret, ret_story_names, ret_story_heights, 264 ret_is_master_story, ret_similar_to_story, 265 ret_splice_above, ret_splice_height, ret_colour] = self.story.SetStories_2(base_elevation, number_stories, story_names, 266 story_heights, is_master_story, similar_to_story, 267 splice_above, splice_height, colour) 268 handle(ret)
27class Story: 28 """Story interface""" 29 def __init__(self, sap_model : etabs.cSapModel) -> None: 30 # link of SapModel interface 31 self.sap_model = sap_model 32 # create PierLabel interface 33 self.story = etabs.cStory(self.sap_model.Story) 34 35 36 def get_elevation(self, story_name : str) -> float: 37 """Retrieves the elevation of a defined story. 38 39 :param story_name: name of a defined story 40 :type story_name: str 41 :return: elevation of the story 42 :rtype: float 43 """ 44 elevation = float() 45 [ret, elevation] = self.story.GetElevation(story_name, elevation) 46 handle(ret) 47 return elevation 48 49 50 def get_GUID(self, story_name : int) -> str: 51 """Retrieves the GUID of a defined story. 52 53 :param story_name: name of a defined story 54 :type story_name: int 55 :return: GUID of the story 56 :rtype: str 57 """ 58 guid = str() 59 [ret, guid] = self.story.GetGUID(story_name, guid) 60 handle(ret) 61 return guid 62 63 64 def get_height(self, story_name : str) -> float: 65 """Retrieves the height of a defined story. 66 67 :param story_name: name of a defined story 68 :type story_name: str 69 :return: height of the story 70 :rtype: float 71 """ 72 height = float() 73 [ret, height] = self.story.GetHeight(story_name, height) 74 handle(ret) 75 return height 76 77 78 def get_master_story(self, story_name : str) -> bool: 79 """Retrieves whether a defined story is a master story. 80 81 :param story_name: name of a defined story 82 :type story_name: str 83 :return: True if the story is a master story, False otherwise 84 :rtype: bool 85 """ 86 is_master_story = bool() 87 [ret, is_master_story] = self.story.GetMasterStory(story_name, is_master_story) 88 handle(ret) 89 return is_master_story 90 91 92 def get_name_list(self) -> list[str]: 93 """Retrieves the names of all defined stories. 94 95 :return: all story names 96 :rtype: list[str] 97 """ 98 number_names = int() 99 story_names = [''] 100 [ret, number_names, story_names] = self.story.GetNameList(number_names, story_names) 101 handle(ret) 102 return list(story_names) 103 104 105 def get_similar_to(self, story_name : str) -> Union[str, None]: 106 """Retrieves whether a defined story is a master story. 107 108 :param story_name: name of a defined story 109 :type story_name: str 110 :return: name of similar story, if story is master returns None 111 :rtype: Union[str, None] 112 """ 113 is_master = bool() 114 similar_story = str() 115 [ret, is_master, similar_story] = self.story.GetSimilarTo(story_name, is_master, similar_story) 116 handle(ret) 117 if not is_master: 118 return similar_story 119 120 121 def get_splice(self, story_name : str) -> Union[float, None]: 122 """Retrieves the story splice height, if applicable. 123 124 :param story_name: name of a defined story 125 :type story_name: str 126 :return: height of splice, if present otherwise None 127 :rtype: Union[float, None] 128 """ 129 splice_above = bool() 130 splice_height = float() 131 [ret, splice_above, splice_height] = self.story.GetSplice(story_name, splice_above, splice_height) 132 handle(ret) 133 if splice_above: 134 return splice_height 135 136 137 def get_stories(self) -> StoryInfo: 138 """Retrieves the story information for the current tower. 139 140 :return: story information for all stories 141 :rtype: StoryInfo 142 """ 143 base_elevation = float() 144 number_stories = int() 145 story_names = [str()] 146 story_elevations = [float()] 147 story_heights = [float()] 148 is_master_story = [bool()] 149 similar_to_story = [str()] 150 splice_above = [bool()] 151 splice_height = [float()] 152 colour = [int()] 153 154 [ret, base_elevation, number_stories, story_names, 155 story_elevations, story_heights, is_master_story, 156 similar_to_story, splice_above, splice_height, colour] = self.story.GetStories_2(base_elevation, number_stories, story_names, 157 story_elevations, story_heights, is_master_story, 158 similar_to_story, splice_above, splice_height, colour) 159 handle (ret) 160 return {'base_elevation' : base_elevation, 161 'number_stories' : number_stories, 162 'story_names' : story_names, 163 'story_elevations' : story_elevations, 164 'story_heights' : story_heights, 165 'is_master_story' : is_master_story, 166 'similar_to_story' : similar_to_story, 167 'splice_above' : splice_above, 168 'splice_height' : splice_height, 169 'colour': colour} 170 171 172 def set_elevation(self, story_name : int, elevation : float) -> None: 173 """Sets the elevation of a defined story. 174 175 :param story_name: name of a defined story 176 :type story_name: int 177 :param elevation: elevation of the story 178 :type elevation: float 179 """ 180 handle(self.story.SetElevation(story_name, elevation)) 181 182 183 def set_GUID (self, story_name : str, guid : str = '') -> None: 184 """Sets the GUID of a defined story. 185 186 :param story_name: name of a defined story 187 :type story_name: str 188 :param guid: GUID of the story, defaults to '' 189 :type guid: str, optional 190 """ 191 handle(self.story.SetGUID(story_name, guid)) 192 193 194 def set_height(self, story_name : int, height : float) -> None: 195 """Sets the height of a defined story. 196 197 param story_name: name of a defined story 198 :type story_name: int 199 :param height: height of the story 200 :type height: float 201 """ 202 handle(self.story.SetHeight(story_name, height)) 203 204 205 def set_master_story(self, story_name : str, is_master_story : bool) -> None: 206 """Sets whether a defined story is a master story. 207 208 param story_name: name of a defined story 209 :type story_name: str 210 :param is_master_story: `True` if the story is a master story, `False` otherwise 211 :type is_master_story: bool 212 """ 213 handle(self.story.SetMasterStory(story_name, is_master_story)) 214 215 216 def set_similar(self, story_name : str, similar_to_story : str) -> None: 217 """Sets the master story that a defined story should be similar to. 218 219 :param story_name: name of a defined story which is not a master story 220 :type story_name: str 221 :param similar_to_story: name of a defined master story that the requested story should be similar to 222 :type similar_to_story: str 223 """ 224 handle (self.story.SetSimilarTo(story_name, similar_to_story)) 225 226 227 def set_splice(self, story_name : str, splice_above : bool, splice_height : float) -> None: 228 """Sets the splice height of a defined story. 229 230 :param story_name: name of defined story 231 :type story_name: str 232 :param splice_above: `True` if the story has a splice height, and `False` otherwise 233 :type splice_above: bool 234 :param splice_height: story splice height 235 :type splice_height: float 236 """ 237 handle(self.story.SetSplice(story_name, splice_above, splice_height)) 238 239 240 def set_stories(self, base_elevation : float, number_stories : int, story_names : list[str], story_heights : list[float], 241 is_master_story : list[bool], similar_to_story : list[str], splice_above : list[bool], splice_height : list[float], 242 colour : list[int]) -> None: 243 """Sets the stories for the current tower. 244 245 :param base_elevation: elevation of the base 246 :type base_elevation: float 247 :param number_stories: number of stories 248 :type number_stories: int 249 :param story_names: names of the stories 250 :type story_names: list[str] 251 :param story_heights: story heights 252 :type story_heights: list[float] 253 :param is_master_story: `True` if the story is master story, and `False` otherwise 254 :type is_master_story: list[bool] 255 :param similar_to_story: if the story is not a master story, which master story the story is similar to 256 :type similar_to_story: list[str] 257 :param splice_above: `True` if the story has a splice height, and `False` otherwise 258 :type splice_above: list[bool] 259 :param splice_height: story splice height 260 :type splice_height: list[float] 261 :param colour: display color for the story specified 262 :type colour: list[int] 263 """ 264 [ret, ret_story_names, ret_story_heights, 265 ret_is_master_story, ret_similar_to_story, 266 ret_splice_above, ret_splice_height, ret_colour] = self.story.SetStories_2(base_elevation, number_stories, story_names, 267 story_heights, is_master_story, similar_to_story, 268 splice_above, splice_height, colour) 269 handle(ret)
Story interface
36 def get_elevation(self, story_name : str) -> float: 37 """Retrieves the elevation of a defined story. 38 39 :param story_name: name of a defined story 40 :type story_name: str 41 :return: elevation of the story 42 :rtype: float 43 """ 44 elevation = float() 45 [ret, elevation] = self.story.GetElevation(story_name, elevation) 46 handle(ret) 47 return elevation
Retrieves the elevation of a defined story.
Parameters
- story_name: name of a defined story
Returns
elevation of the story
50 def get_GUID(self, story_name : int) -> str: 51 """Retrieves the GUID of a defined story. 52 53 :param story_name: name of a defined story 54 :type story_name: int 55 :return: GUID of the story 56 :rtype: str 57 """ 58 guid = str() 59 [ret, guid] = self.story.GetGUID(story_name, guid) 60 handle(ret) 61 return guid
Retrieves the GUID of a defined story.
Parameters
- story_name: name of a defined story
Returns
GUID of the story
64 def get_height(self, story_name : str) -> float: 65 """Retrieves the height of a defined story. 66 67 :param story_name: name of a defined story 68 :type story_name: str 69 :return: height of the story 70 :rtype: float 71 """ 72 height = float() 73 [ret, height] = self.story.GetHeight(story_name, height) 74 handle(ret) 75 return height
Retrieves the height of a defined story.
Parameters
- story_name: name of a defined story
Returns
height of the story
78 def get_master_story(self, story_name : str) -> bool: 79 """Retrieves whether a defined story is a master story. 80 81 :param story_name: name of a defined story 82 :type story_name: str 83 :return: True if the story is a master story, False otherwise 84 :rtype: bool 85 """ 86 is_master_story = bool() 87 [ret, is_master_story] = self.story.GetMasterStory(story_name, is_master_story) 88 handle(ret) 89 return is_master_story
Retrieves whether a defined story is a master story.
Parameters
- story_name: name of a defined story
Returns
True if the story is a master story, False otherwise
92 def get_name_list(self) -> list[str]: 93 """Retrieves the names of all defined stories. 94 95 :return: all story names 96 :rtype: list[str] 97 """ 98 number_names = int() 99 story_names = [''] 100 [ret, number_names, story_names] = self.story.GetNameList(number_names, story_names) 101 handle(ret) 102 return list(story_names)
Retrieves the names of all defined stories.
Returns
all story names
105 def get_similar_to(self, story_name : str) -> Union[str, None]: 106 """Retrieves whether a defined story is a master story. 107 108 :param story_name: name of a defined story 109 :type story_name: str 110 :return: name of similar story, if story is master returns None 111 :rtype: Union[str, None] 112 """ 113 is_master = bool() 114 similar_story = str() 115 [ret, is_master, similar_story] = self.story.GetSimilarTo(story_name, is_master, similar_story) 116 handle(ret) 117 if not is_master: 118 return similar_story
Retrieves whether a defined story is a master story.
Parameters
- story_name: name of a defined story
Returns
name of similar story, if story is master returns None
121 def get_splice(self, story_name : str) -> Union[float, None]: 122 """Retrieves the story splice height, if applicable. 123 124 :param story_name: name of a defined story 125 :type story_name: str 126 :return: height of splice, if present otherwise None 127 :rtype: Union[float, None] 128 """ 129 splice_above = bool() 130 splice_height = float() 131 [ret, splice_above, splice_height] = self.story.GetSplice(story_name, splice_above, splice_height) 132 handle(ret) 133 if splice_above: 134 return splice_height
Retrieves the story splice height, if applicable.
Parameters
- story_name: name of a defined story
Returns
height of splice, if present otherwise None
137 def get_stories(self) -> StoryInfo: 138 """Retrieves the story information for the current tower. 139 140 :return: story information for all stories 141 :rtype: StoryInfo 142 """ 143 base_elevation = float() 144 number_stories = int() 145 story_names = [str()] 146 story_elevations = [float()] 147 story_heights = [float()] 148 is_master_story = [bool()] 149 similar_to_story = [str()] 150 splice_above = [bool()] 151 splice_height = [float()] 152 colour = [int()] 153 154 [ret, base_elevation, number_stories, story_names, 155 story_elevations, story_heights, is_master_story, 156 similar_to_story, splice_above, splice_height, colour] = self.story.GetStories_2(base_elevation, number_stories, story_names, 157 story_elevations, story_heights, is_master_story, 158 similar_to_story, splice_above, splice_height, colour) 159 handle (ret) 160 return {'base_elevation' : base_elevation, 161 'number_stories' : number_stories, 162 'story_names' : story_names, 163 'story_elevations' : story_elevations, 164 'story_heights' : story_heights, 165 'is_master_story' : is_master_story, 166 'similar_to_story' : similar_to_story, 167 'splice_above' : splice_above, 168 'splice_height' : splice_height, 169 'colour': colour}
Retrieves the story information for the current tower.
Returns
story information for all stories
172 def set_elevation(self, story_name : int, elevation : float) -> None: 173 """Sets the elevation of a defined story. 174 175 :param story_name: name of a defined story 176 :type story_name: int 177 :param elevation: elevation of the story 178 :type elevation: float 179 """ 180 handle(self.story.SetElevation(story_name, elevation))
Sets the elevation of a defined story.
Parameters
- story_name: name of a defined story
- elevation: elevation of the story
183 def set_GUID (self, story_name : str, guid : str = '') -> None: 184 """Sets the GUID of a defined story. 185 186 :param story_name: name of a defined story 187 :type story_name: str 188 :param guid: GUID of the story, defaults to '' 189 :type guid: str, optional 190 """ 191 handle(self.story.SetGUID(story_name, guid))
Sets the GUID of a defined story.
Parameters
- story_name: name of a defined story
- guid: GUID of the story, defaults to ''
194 def set_height(self, story_name : int, height : float) -> None: 195 """Sets the height of a defined story. 196 197 param story_name: name of a defined story 198 :type story_name: int 199 :param height: height of the story 200 :type height: float 201 """ 202 handle(self.story.SetHeight(story_name, height))
Sets the height of a defined story.
param story_name: name of a defined story
Parameters
- height: height of the story
205 def set_master_story(self, story_name : str, is_master_story : bool) -> None: 206 """Sets whether a defined story is a master story. 207 208 param story_name: name of a defined story 209 :type story_name: str 210 :param is_master_story: `True` if the story is a master story, `False` otherwise 211 :type is_master_story: bool 212 """ 213 handle(self.story.SetMasterStory(story_name, is_master_story))
Sets whether a defined story is a master story.
param story_name: name of a defined story
Parameters
- is_master_story:
True
if the story is a master story,False
otherwise
216 def set_similar(self, story_name : str, similar_to_story : str) -> None: 217 """Sets the master story that a defined story should be similar to. 218 219 :param story_name: name of a defined story which is not a master story 220 :type story_name: str 221 :param similar_to_story: name of a defined master story that the requested story should be similar to 222 :type similar_to_story: str 223 """ 224 handle (self.story.SetSimilarTo(story_name, similar_to_story))
Sets the master story that a defined story should be similar to.
Parameters
- story_name: name of a defined story which is not a master story
- similar_to_story: name of a defined master story that the requested story should be similar to
227 def set_splice(self, story_name : str, splice_above : bool, splice_height : float) -> None: 228 """Sets the splice height of a defined story. 229 230 :param story_name: name of defined story 231 :type story_name: str 232 :param splice_above: `True` if the story has a splice height, and `False` otherwise 233 :type splice_above: bool 234 :param splice_height: story splice height 235 :type splice_height: float 236 """ 237 handle(self.story.SetSplice(story_name, splice_above, splice_height))
Sets the splice height of a defined story.
Parameters
- story_name: name of defined story
- splice_above:
True
if the story has a splice height, andFalse
otherwise - splice_height: story splice height
240 def set_stories(self, base_elevation : float, number_stories : int, story_names : list[str], story_heights : list[float], 241 is_master_story : list[bool], similar_to_story : list[str], splice_above : list[bool], splice_height : list[float], 242 colour : list[int]) -> None: 243 """Sets the stories for the current tower. 244 245 :param base_elevation: elevation of the base 246 :type base_elevation: float 247 :param number_stories: number of stories 248 :type number_stories: int 249 :param story_names: names of the stories 250 :type story_names: list[str] 251 :param story_heights: story heights 252 :type story_heights: list[float] 253 :param is_master_story: `True` if the story is master story, and `False` otherwise 254 :type is_master_story: list[bool] 255 :param similar_to_story: if the story is not a master story, which master story the story is similar to 256 :type similar_to_story: list[str] 257 :param splice_above: `True` if the story has a splice height, and `False` otherwise 258 :type splice_above: list[bool] 259 :param splice_height: story splice height 260 :type splice_height: list[float] 261 :param colour: display color for the story specified 262 :type colour: list[int] 263 """ 264 [ret, ret_story_names, ret_story_heights, 265 ret_is_master_story, ret_similar_to_story, 266 ret_splice_above, ret_splice_height, ret_colour] = self.story.SetStories_2(base_elevation, number_stories, story_names, 267 story_heights, is_master_story, similar_to_story, 268 splice_above, splice_height, colour) 269 handle(ret)
Sets the stories for the current tower.
Parameters
- base_elevation: elevation of the base
- number_stories: number of stories
- story_names: names of the stories
- story_heights: story heights
- is_master_story:
True
if the story is master story, andFalse
otherwise - similar_to_story: if the story is not a master story, which master story the story is similar to
- splice_above:
True
if the story has a splice height, andFalse
otherwise - splice_height: story splice height
- colour: display color for the story specified